Thread (2 messages) flat view 2 messages, 2 authors, 2017-07-24

Re: [PATCH net-next] skbuff: re-add check for NULL skb->head in kfree_skb path

From: David Miller <davem@davemloft.net>
Date: 2017-07-24 23:28:05

From: Florian Westphal <fw@strlen.de>
Date: Sun, 23 Jul 2017 19:54:47 +0200
A null check is needed after all.  netlink skbs can have skb->head be
backed by vmalloc.  The netlink destructor vfree()s head, then sets it to
NULL.  We then panic in skb_release_data with a NULL dereference.

Re-add such a test.

Alternative would be to switch to kvfree to free skb->head memory
and remove the special handling in netlink destructor.

Reported-by: kernel test robot <redacted>
Fixes: 06dc75ab06943 ("net: Revert "net: add function to allocate sk_buff head without data area")
Signed-off-by: Florian Westphal <fw@strlen.de>
Ok, back it goes.

Applied, thanks.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help