Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934232AbYBGU7S (ORCPT ); Thu, 7 Feb 2008 15:59:18 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1762373AbYBGUvg (ORCPT ); Thu, 7 Feb 2008 15:51:36 -0500 Received: from ns.suse.de ([195.135.220.2]:45439 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754948AbYBGUvd (ORCPT ); Thu, 7 Feb 2008 15:51:33 -0500 Date: Thu, 7 Feb 2008 12:47:17 -0800 From: Greg KH To: linux-kernel@vger.kernel.org, stable@kernel.org, linux-usb@vger.kernel.org Cc: Justin Forbes , Zwane Mwaikambo , "Theodore Ts'o" , Randy Dunlap , Dave Jones , Chuck Wolber , Chris Wedgwood , Michael Krufky , Chuck Ebbert , Domenico Andreoli , torvalds@linux-foundation.org, akpm@linux-foundation.org, alan@lxorguk.ukuu.org.uk, Oliver Neukum Subject: [patch 17/45] USB: use GFP_NOIO in reset path Message-ID: <20080207204717.GR16389@suse.de> References: <20080207204118.202098927@mini.kroah.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline; filename="usb-use-gfp_noio-in-reset-path.patch" In-Reply-To: <20080207204549.GA16389@suse.de> User-Agent: Mutt/1.5.16 (2007-06-09) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1155 Lines: 35 2.6.24-stable review patch. If anyone has any objections, please let us know. ------------------ From: Oliver Neukum 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. Signed-off-by: Oliver Neukum Signed-off-by: Greg Kroah-Hartman --- drivers/usb/core/hub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c @@ -2946,7 +2946,7 @@ static int config_descriptors_changed(st if (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) { dev_err(&udev->dev, "no mem to re-read configs after reset\n"); /* assume the worst */ -- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/