aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/sockbuf.h
diff options
context:
space:
mode:
authorGleb Smirnoff <glebius@FreeBSD.org>2016-01-08 19:03:20 +0000
committerGleb Smirnoff <glebius@FreeBSD.org>2016-01-08 19:03:20 +0000
commit829fae9063685b393b1fc5670abd9c0d2c3686a1 (patch)
tree7e34220d682ecdb8ec0c873042ddf508bd1c612c /sys/sys/sockbuf.h
parent638b3cc8ce1f229dd1b71e0fdc7e4a5b940b6f2d (diff)
downloadsrc-829fae9063685b393b1fc5670abd9c0d2c3686a1.tar.gz
src-829fae9063685b393b1fc5670abd9c0d2c3686a1.zip
Make it possible for sbappend() to preserve M_NOTREADY on mbufs, just like
sbappendstream() does. Although, M_NOTREADY may appear only on SOCK_STREAM sockets, due to sendfile(2) supporting only the latter, there is a corner case of AF_UNIX/SOCK_STREAM socket, that still uses records for the sake of control data, albeit being stream socket. Provide private version of m_clrprotoflags(), which understands PRUS_NOTREADY, similar to m_demote().
Notes
Notes: svn path=/head/; revision=293432
Diffstat (limited to 'sys/sys/sockbuf.h')
-rw-r--r--sys/sys/sockbuf.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/sys/sockbuf.h b/sys/sys/sockbuf.h
index 0e3e172d63f7..c6904f65952d 100644
--- a/sys/sys/sockbuf.h
+++ b/sys/sys/sockbuf.h
@@ -129,8 +129,8 @@ struct sockbuf {
#define M_BLOCKED M_PROTO2 /* M_NOTREADY in front of m */
#define M_NOTAVAIL (M_NOTREADY | M_BLOCKED)
-void sbappend(struct sockbuf *sb, struct mbuf *m);
-void sbappend_locked(struct sockbuf *sb, struct mbuf *m);
+void sbappend(struct sockbuf *sb, struct mbuf *m, int flags);
+void sbappend_locked(struct sockbuf *sb, struct mbuf *m, int flags);
void sbappendstream(struct sockbuf *sb, struct mbuf *m, int flags);
void sbappendstream_locked(struct sockbuf *sb, struct mbuf *m, int flags);
int sbappendaddr(struct sockbuf *sb, const struct sockaddr *asa,