]> git.baikalelectronics.ru Git - kernel.git/commit
Bluetooth: bfusb: Fix error path on firmware load
authorDavid Herrmann <dh.herrmann@googlemail.com>
Wed, 26 Oct 2011 09:22:46 +0000 (11:22 +0200)
committerGustavo F. Padovan <padovan@profusion.mobi>
Mon, 7 Nov 2011 19:24:54 +0000 (17:24 -0200)
commit6264c18bf0e4c66009f80001df5fc07e20f3f2bd
treec8319c639e4bef02ab88bdf35ff080a3b3850040
parent22ed8893def78c556bca9807a03c9d24339b2f09
Bluetooth: bfusb: Fix error path on firmware load

When loading the usb-configuration we do not signal the end of configuration on
memory allocation error. This patch moves the memory allocation to the top so
every error path uses "goto error" now to correctly send the usb-ctrl message
when detecting some error.

This also replaces GFP_ATOMIC with GFP_KERNEL as we are allowed to sleep here.

Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
drivers/bluetooth/bfusb.c