]> git.karo-electronics.de Git - karo-tx-linux.git/commit
USB: kaweth.c: use GFP_ATOMIC under spin_lock
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 27 Jul 2012 01:46:51 +0000 (01:46 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Aug 2012 15:23:13 +0000 (08:23 -0700)
commit78b13444e02adaff85200e40103afdc851e88479
treef0f208e4556170df1409ad0225f9ea83e3b4b9d6
parentae8effff91107fec667a7240d25978fe994da30b
USB: kaweth.c: use GFP_ATOMIC under spin_lock

[ Upstream commit e4c7f259c5be99dcfc3d98f913590663b0305bf8 ]

The problem is that we call this with a spin lock held.  The call tree
is:
kaweth_start_xmit() holds kaweth->device_lock.
-> kaweth_async_set_rx_mode()
   -> kaweth_control()
      -> kaweth_internal_control_msg()

The kaweth_internal_control_msg() function is only called from
kaweth_control() which used GFP_ATOMIC for its allocations.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/usb/kaweth.c