https://github.com/torvalds/linux
Revision ba9b40810bb43e6bf73b395012b98633c03f7f59 authored by Colin Ian King on 07 January 2020, 12:39:01 UTC, committed by Greg Kroah-Hartman on 08 January 2020, 16:34:18 UTC
Currently when an error occurs when calling devm_gpiod_get_optional or
calling gpiod_to_irq it causes an uninitialized error return in variable
'error' to be returned.  Fix this by ensuring the error variable is set
from da8xx_ohci->oc_gpio and oc_irq.

Thanks to Dan Carpenter for spotting the uninitialized error in the
gpiod_to_irq failure case.

Addresses-Coverity: ("Uninitialized scalar variable")
Fixes: d193abf1c913 ("usb: ohci-da8xx: add vbus and overcurrent gpios")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Cc: stable <stable@vger.kernel.org>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Link: https://lore.kernel.org/r/20200107123901.101190-1-colin.king@canonical.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 96a0c12
History
Tip revision: ba9b40810bb43e6bf73b395012b98633c03f7f59 authored by Colin Ian King on 07 January 2020, 12:39:01 UTC
usb: ohci-da8xx: ensure error return on variable error is set
Tip revision: ba9b408
File Mode Size
api-aead.rst -rw-r--r-- 1.0 KB
api-akcipher.rst -rw-r--r-- 789 bytes
api-digest.rst -rw-r--r-- 1.4 KB
api-intro.txt -rw-r--r-- 6.5 KB
api-kpp.rst -rw-r--r-- 1.3 KB
api-rng.rst -rw-r--r-- 446 bytes
api-samples.rst -rw-r--r-- 5.7 KB
api-skcipher.rst -rw-r--r-- 1.3 KB
api.rst -rw-r--r-- 200 bytes
architecture.rst -rw-r--r-- 14.5 KB
asymmetric-keys.txt -rw-r--r-- 16.0 KB
async-tx-api.txt -rw-r--r-- 9.1 KB
crypto_engine.rst -rw-r--r-- 2.5 KB
descore-readme.txt -rw-r--r-- 16.8 KB
devel-algos.rst -rw-r--r-- 9.3 KB
index.rst -rw-r--r-- 499 bytes
intro.rst -rw-r--r-- 3.1 KB
userspace-if.rst -rw-r--r-- 14.1 KB

back to top