macvtap: convert to SKB paged frag API.
Subsystems (2)
Hi Ian,
There is a problem in d1b08284ade "macvtap: convert to SKB paged frag API." It removes the initialization of "f" in zerocopy_sg_from_iovec() which breaks it and causes a compile warning:drivers/net/macvtap.c:509:5: warning: ‘f’ may be used uninitialized
in this function [-Wuninitialized]
regards,
dan carpenter
Quoted 7 lines · Dan Carpenter
Hi Ian,
There is a problem in
d1b08284ade"macvtap: convert to SKB paged frag API." It removes the initialization of "f" inzerocopy_sg_from_iovec()which breaks it and causes a compile warning:drivers/net/macvtap.c:509:5: warning: ‘f’ may be used uninitialized
in this function [-Wuninitialized]
Not just a warning but an actual bug -- I'll post a patch.
Thanks for the heads up!
Ian.
PATCH 1/1 macvtap: fix warning due to use of uninitialised var
In reply to Dan Carpenterd1b08284ade "macvtap: convert to SKB paged frag API." accidentally dropped the initialisation of a variable leading to:
drivers/net/macvtap.c:509:5: warning: ‘f’ may be used uninitialized
in this function [-Wuninitialized]
--- drivers/net/macvtap.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/net/macvtap.c +1 -0
@@ -503,6 +503,7 @@ static int zerocopy_sg_from_iovec(struct sk_buff *skb, const struct iovec *from, skb->truesize += len;atomic_add (len, &skb->sk->sk_wmem_alloc);while (len) { + f = &skb_shinfo (skb)->frags[i]; __skb_fill_page_desc( skb, i, page[i], base & ~PAGE_MASK,
Signature · 1 line
1.7.2.5