summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Zhao <john.zhao@intel.com>2020-08-04 09:36:16 -0700
committerPatrick Georgi <pgeorgi@google.com>2020-08-17 06:21:10 +0000
commit83aac1359006046e3d7259083ce31510b3b4cc31 (patch)
tree700b9ad30f08f05cb129aad747aa0ad9eceabe90
parent07674db240f94114cea6f7f6f8982101494bfd25 (diff)
downloadcoreboot-83aac1359006046e3d7259083ce31510b3b4cc31.tar.xz
drivers/usb: Replace return value -10 with variable
Coverity detects that value assigned to variable "ret" is overwritten before it is used. Fix the issue by returning right value. Found-by: Coverity CID 1255942, 1241836 TEST=None Signed-off-by: John Zhao <john.zhao@intel.com> Change-Id: I2e1fb5400ff64c6178bb30601896780f8d67b5c6 Reviewed-on: https://review.coreboot.org/c/coreboot/+/44185 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
-rw-r--r--src/drivers/usb/ehci_debug.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/drivers/usb/ehci_debug.c b/src/drivers/usb/ehci_debug.c
index 5998172b87..ab76f3bb3a 100644
--- a/src/drivers/usb/ehci_debug.c
+++ b/src/drivers/usb/ehci_debug.c
@@ -600,7 +600,7 @@ next_debug_port:
goto try_next_time;
}
- return -10;
+ return ret;
}
static int dbgp_enabled(void)