]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commit
net: add a truesize parameter to skb_add_rx_frag()
authorEric Dumazet <eric.dumazet@gmail.com>
Fri, 23 Mar 2012 23:59:33 +0000 (23:59 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 25 Mar 2012 17:29:58 +0000 (13:29 -0400)
commit50269e19ad990e79eeda101fc6df80cffd5d4831
tree903d80ba1b1fc0eb15e122a8c12a72f72e7ed2de
parent0015e551edb1d28191567d8a7d1ce5edda404ced
net: add a truesize parameter to skb_add_rx_frag()

skb_add_rx_frag() API is misleading.

Network skbs built with this helper can use uncharged kernel memory and
eventually stress/crash machine in OOM.

Add a 'truesize' parameter and then fix drivers in followup patches.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Cc: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/cdc-phonet.c
drivers/net/wireless/iwlegacy/3945.c
drivers/net/wireless/iwlegacy/4965-mac.c
drivers/net/wireless/iwlwifi/iwl-agn-rx.c
drivers/usb/gadget/f_phonet.c
include/linux/skbuff.h
net/core/skbuff.c