Skip to content
Commit a6686f2f authored by Shirley Ma's avatar Shirley Ma Committed by David S. Miller
Browse files

skbuff: skb supports zero-copy buffers



This patch adds userspace buffers support in skb shared info. A new
struct skb_ubuf_info is needed to maintain the userspace buffers
argument and index, a callback is used to notify userspace to release
the buffers once lower device has done DMA (Last reference to that skb
has gone).

If there is any userspace apps to reference these userspace buffers,
then these userspaces buffers will be copied into kernel. This way we
can prevent userspace apps from holding these userspace buffers too long.

Use destructor_arg to point to the userspace buffer info; a new tx flags
SKBTX_DEV_ZEROCOPY is added for zero-copy buffer check.

Signed-off-by: default avatarShirley Ma <xma@...ibm.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1cdebb42
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment