diff options
author | Eliezer Tamir <eliezer.tamir@linux.intel.com> | 2013-06-24 03:28:03 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-06-25 19:35:52 -0400 |
commit | 2d48d67fa8cd129ea85ea02d91b4a793286866f8 (patch) | |
tree | be47e2406605760d949b08d29d988d46c4a20799 /Documentation/sysctl | |
parent | e4f2379db6c6823c5d4a4c2c912df00c65de51d7 (diff) |
net: poll/select low latency socket support
select/poll busy-poll support.
Split sysctl value into two separate ones, one for read and one for poll.
updated Documentation/sysctl/net.txt
Add a new poll flag POLL_LL. When this flag is set, sock_poll will call
sk_poll_ll if possible. sock_poll sets this flag in its return value
to indicate to select/poll when a socket that can busy poll is found.
When poll/select have nothing to report, call the low-level
sock_poll again until we are out of time or we find something.
Once the system call finds something, it stops setting POLL_LL, so it can
return the result to the user ASAP.
Signed-off-by: Eliezer Tamir <eliezer.tamir@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'Documentation/sysctl')
-rw-r--r-- | Documentation/sysctl/net.txt | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/Documentation/sysctl/net.txt b/Documentation/sysctl/net.txt index 5369879eafe2..e658bbfb641f 100644 --- a/Documentation/sysctl/net.txt +++ b/Documentation/sysctl/net.txt | |||
@@ -50,13 +50,27 @@ The maximum number of packets that kernel can handle on a NAPI interrupt, | |||
50 | it's a Per-CPU variable. | 50 | it's a Per-CPU variable. |
51 | Default: 64 | 51 | Default: 64 |
52 | 52 | ||
53 | low_latency_poll | 53 | low_latency_read |
54 | ---------------- | 54 | ---------------- |
55 | Low latency busy poll timeout. (needs CONFIG_NET_LL_RX_POLL) | 55 | Low latency busy poll timeout for socket reads. (needs CONFIG_NET_LL_RX_POLL) |
56 | Approximate time in us to spin waiting for packets on the device queue. | 56 | Approximate time in us to spin waiting for packets on the device queue. |
57 | This sets the default value of the SO_LL socket option. | ||
58 | Can be set or overridden per socket by setting socket option SO_LL. | ||
57 | Recommended value is 50. May increase power usage. | 59 | Recommended value is 50. May increase power usage. |
58 | Default: 0 (off) | 60 | Default: 0 (off) |
59 | 61 | ||
62 | low_latency_poll | ||
63 | ---------------- | ||
64 | Low latency busy poll timeout for poll and select. (needs CONFIG_NET_LL_RX_POLL) | ||
65 | Approximate time in us to spin waiting for packets on the device queue. | ||
66 | Recommended value depends on the number of sockets you poll on. | ||
67 | For several sockets 50, for several hundreds 100. | ||
68 | For more than that you probably want to use epoll. | ||
69 | Note that only sockets with SO_LL set will be busy polled, so you want to either | ||
70 | selectively set SO_LL on those sockets or set sysctl.net.low_latency_read globally. | ||
71 | May increase power usage. | ||
72 | Default: 0 (off) | ||
73 | |||
60 | rmem_default | 74 | rmem_default |
61 | ------------ | 75 | ------------ |
62 | 76 | ||