summaryrefslogtreecommitdiffstats
path: root/sys/kern/uipc_socket.c
diff options
context:
space:
mode:
authorandre <andre@FreeBSD.org>2009-09-15 22:23:45 +0000
committerandre <andre@FreeBSD.org>2009-09-15 22:23:45 +0000
commit3e3fe69f6bc0430a9bb2153acb0c9dccbddd686c (patch)
treea0a67ad92041c159cc6501220de4b0f504b45fe3 /sys/kern/uipc_socket.c
parente1b6b165896ea3f06870ce31cc9b63fbad5e1d39 (diff)
downloadFreeBSD-src-3e3fe69f6bc0430a9bb2153acb0c9dccbddd686c.zip
FreeBSD-src-3e3fe69f6bc0430a9bb2153acb0c9dccbddd686c.tar.gz
-Put the optimized soreceive_stream() under a compile time option called
TCP_SORECEIVE_STREAM for the time being. Requested by: brooks Once compiled in make it easily switchable for testers by using a tuneable net.inet.tcp.soreceive_stream and a corresponding read-only sysctl to report the current state. Suggested by: rwatson MFC after: 2 days -This line, and those below, will be ignored-- > Description of fields to fill in above: 76 columns --| > PR: If a GNATS PR is affected by the change. > Submitted by: If someone else sent in the change. > Reviewed by: If someone else reviewed your modification. > Approved by: If you needed approval for this commit. > Obtained from: If the change is from a third party. > MFC after: N [day[s]|week[s]|month[s]]. Request a reminder email. > Security: Vulnerability reference (one per line) or description. > Empty fields above will be automatically removed. M sys/conf/options M sys/kern/uipc_socket.c M sys/netinet/tcp_subr.c M sys/netinet/tcp_usrreq.c
Diffstat (limited to 'sys/kern/uipc_socket.c')
-rw-r--r--sys/kern/uipc_socket.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/uipc_socket.c b/sys/kern/uipc_socket.c
index d11af34..34d5edc 100644
--- a/sys/kern/uipc_socket.c
+++ b/sys/kern/uipc_socket.c
@@ -1870,6 +1870,7 @@ release:
/*
* Optimized version of soreceive() for stream (TCP) sockets.
*/
+#ifdef TCP_SORECEIVE_STREAM
int
soreceive_stream(struct socket *so, struct sockaddr **psa, struct uio *uio,
struct mbuf **mp0, struct mbuf **controlp, int *flagsp)
@@ -2062,6 +2063,7 @@ out:
sbunlock(sb);
return (error);
}
+#endif /* TCP_SORECEIVE_STREAM */
/*
* Optimized version of soreceive() for simple datagram cases from userspace.
OpenPOWER on IntegriCloud