mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
USB: use GFP_NOIO in reset path
this function will run in the context of the scsi error handler thread. It must use GFP_NOIO instead of GFP_KERNEL to avoid a possible deadlock. Cc: stable <stable@kernel.org> Signed-off-by: Oliver Neukum <oneukum@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
4bb0ef193b
commit
0cc1a51ff3
@ -2946,7 +2946,7 @@ static int config_descriptors_changed(struct usb_device *udev)
|
|||||||
if (len < le16_to_cpu(udev->config[index].desc.wTotalLength))
|
if (len < le16_to_cpu(udev->config[index].desc.wTotalLength))
|
||||||
len = le16_to_cpu(udev->config[index].desc.wTotalLength);
|
len = le16_to_cpu(udev->config[index].desc.wTotalLength);
|
||||||
}
|
}
|
||||||
buf = kmalloc (len, GFP_KERNEL);
|
buf = kmalloc(len, GFP_NOIO);
|
||||||
if (buf == NULL) {
|
if (buf == NULL) {
|
||||||
dev_err(&udev->dev, "no mem to re-read configs after reset\n");
|
dev_err(&udev->dev, "no mem to re-read configs after reset\n");
|
||||||
/* assume the worst */
|
/* assume the worst */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user