From: David Herrmann Date: Tue, 25 Oct 2011 10:09:52 +0000 (+0200) Subject: Bluetooth: ath3k: Use GFP_KERNEL instead of GFP_ATOMIC X-Git-Tag: v3.3-rc1~182^2~44^2~536^2~40 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=52a1020e80beece986002f673eca24dae6255b55;p=platform%2Fkernel%2Flinux-exynos.git Bluetooth: ath3k: Use GFP_KERNEL instead of GFP_ATOMIC We are allowed to sleep here so no need to use GFP_ATOMIC. The caller (ath3k_probe) calls request_firmware() which definitely sleeps. Hence, we should avoid using GFP_ATOMIC. Signed-off-by: David Herrmann Signed-off-by: Gustavo F. Padovan --- diff --git a/drivers/bluetooth/ath3k.c b/drivers/bluetooth/ath3k.c index 39b25ac..1622772 100644 --- a/drivers/bluetooth/ath3k.c +++ b/drivers/bluetooth/ath3k.c @@ -106,7 +106,7 @@ static int ath3k_load_firmware(struct usb_device *udev, pipe = usb_sndctrlpipe(udev, 0); - send_buf = kmalloc(BULK_SIZE, GFP_ATOMIC); + send_buf = kmalloc(BULK_SIZE, GFP_KERNEL); if (!send_buf) { BT_ERR("Can't allocate memory chunk for firmware"); return -ENOMEM; @@ -177,7 +177,7 @@ static int ath3k_load_fwfile(struct usb_device *udev, count = firmware->size; - send_buf = kmalloc(BULK_SIZE, GFP_ATOMIC); + send_buf = kmalloc(BULK_SIZE, GFP_KERNEL); if (!send_buf) { BT_ERR("Can't allocate memory chunk for firmware"); return -ENOMEM;