]> git.baikalelectronics.ru Git - kernel.git/commit
usb-storage: alauda: fix initFunction error return
authorLin Ma <linma@zju.edu.cn>
Thu, 7 Apr 2022 02:20:58 +0000 (10:20 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 21 Apr 2022 17:02:37 +0000 (19:02 +0200)
commitee886ed0ad241b48d70637f7ba2ce048fa65c8d3
tree42fc4d8c401dc3e53ffce078b2c416962699e316
parent7af9def14a8338b9919be9cb56cc7300d176c3c5
usb-storage: alauda: fix initFunction error return

The initFunction is called when probing a new device, its call relation
is like:

USB core: probe() -> usb_stor_probe2() -> usb_stor_acquire_resources()
-> init_alauda()

That is, the error return of the initFunction should tell USB core what
happened instead of using error code like USB_STOR_TRANSPORT_ERROR.

Signed-off-by: Lin Ma <linma@zju.edu.cn>
Link: https://lore.kernel.org/r/20220407022058.3741-1-linma@zju.edu.cn
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/storage/alauda.c