net: shrink struct ubuf_info
We can benefit from a smaller struct ubuf_info, so leave only mandatory fields and let users to decide how they want to extend it. Convert MSG_ZEROCOPY to struct ubuf_info_msgzc and remove duplicated fields. This reduces the size from 48 bytes to just 16. Signed-off-by: Pavel Begunkov <asml.silence@gmail.com> Acked-by: Paolo Abeni <pabeni@redhat.com> Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
committed by
Jakub Kicinski
parent
dfff202be5
commit
e7d2b51016
@@ -1043,7 +1043,7 @@ static int __ip_append_data(struct sock *sk,
|
||||
paged = true;
|
||||
zc = true;
|
||||
} else {
|
||||
uarg->zerocopy = 0;
|
||||
uarg_to_msgzc(uarg)->zerocopy = 0;
|
||||
skb_zcopy_set(skb, uarg, &extra_uref);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user