diff options
| author | Eric Dumazet <edumazet@google.com> | 2013-08-08 14:37:32 -0700 |
|---|---|---|
| committer | Mister Oyster <oysterized@gmail.com> | 2017-04-13 12:32:08 +0200 |
| commit | 5d3005a1584cd506cdc9e6a914d83e4484dc71d8 (patch) | |
| tree | 04373e5a7fd15964546c24c1e00ea687ee73fa16 /include/linux | |
| parent | 6d4717c01face6564c99ec65de983c3ae2aa234c (diff) | |
af_unix: improve STREAM behavior with fragmented memory
unix_stream_sendmsg() currently uses order-2 allocations,
and we had numerous reports this can fail.
The __GFP_REPEAT flag present in sock_alloc_send_pskb() is
not helping.
This patch extends the work done in commit eb6a24816b247c
("af_unix: reduce high order page allocations) for
datagram sockets.
This opens the possibility of zero copy IO (splice() and
friends)
The trick is to not use skb_pull() anymore in recvmsg() path,
and instead add a @consumed field in UNIXCB() to track amount
of already read payload in the skb.
There is a performance regression for large sends
because of extra page allocations that will be addressed
in a follow-up patch, allowing sock_alloc_send_pskb()
to attempt high order page allocations.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: David Rientjes <rientjes@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Francisco Franco <franciscofranco.1990@gmail.com>
Diffstat (limited to 'include/linux')
0 files changed, 0 insertions, 0 deletions
