From: Timo Teräs Date: Fri, 17 Dec 2010 09:40:24 +0000 (+0200) Subject: staging: hv: fix netvsc sleeping while atomic X-Git-Tag: v2.6.36.4~138 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=12347414227879cb9d1b31d3ad0efd78329bc983;p=karo-tx-linux.git staging: hv: fix netvsc sleeping while atomic commit d70c673153d42e8aefd5ac296c8159ef222d076b upstream. The channel callbacks are called directly from vmbus_event_dpc which runs in tasklet context. These callbacks need to use GFP_ATOMIC. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=16701 Cc: Hank Janssen Cc: Haiyang Zhang Signed-off-by: Timo Teräs Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/hv/netvsc.c b/drivers/staging/hv/netvsc.c index 1d2ebbe17e2c..95dee473d81d 100644 --- a/drivers/staging/hv/netvsc.c +++ b/drivers/staging/hv/netvsc.c @@ -1250,7 +1250,7 @@ static void NetVscOnChannelCallback(void *Context) /* ASSERT(device); */ packet = kzalloc(NETVSC_PACKET_SIZE * sizeof(unsigned char), - GFP_KERNEL); + GFP_ATOMIC); if (!packet) return; buffer = packet;