From: Matthew Wilcox Date: Wed, 15 Dec 2010 20:44:06 +0000 (-0500) Subject: USB: uas: Use GFP_NOIO instead of GFP_KERNEL in I/O submission path X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=0b83ae960cd7d4a5ee02786ecf41ab45688999bf;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git USB: uas: Use GFP_NOIO instead of GFP_KERNEL in I/O submission path If swap is on a UAS device, we could recurse into the driver by using GFP_KERNEL. Using GFP_NOIO ensures we won't. Reported-by: James Bottomley Signed-off-by: Matthew Wilcox Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/storage/uas.c b/drivers/usb/storage/uas.c index 52e5ec1b2e8a..8d58c6316111 100644 --- a/drivers/usb/storage/uas.c +++ b/drivers/usb/storage/uas.c @@ -141,7 +141,7 @@ static void uas_do_work(struct work_struct *work) struct scsi_pointer *scp = (void *)cmdinfo; struct scsi_cmnd *cmnd = container_of(scp, struct scsi_cmnd, SCp); - uas_submit_urbs(cmnd, cmnd->device->hostdata, GFP_KERNEL); + uas_submit_urbs(cmnd, cmnd->device->hostdata, GFP_NOIO); } }