Skip to content

Commit cf4cf0b

Browse files
Oliver Neukumgregkh
authored andcommitted
USB: missing error check in emi26
this drivers lacks an error check. Signed-off-by: Oliver Neukum <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 8abaee2 commit cf4cf0b

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

drivers/usb/misc/emi26.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,10 @@ static int emi26_load_firmware (struct usb_device *dev)
114114

115115
/* De-assert reset (let the CPU run) */
116116
err = emi26_set_reset(dev,0);
117+
if (err < 0) {
118+
err("%s - error loading firmware: error = %d", __FUNCTION__, err);
119+
goto wraperr;
120+
}
117121
msleep(250); /* let device settle */
118122

119123
/* 2. We upload the FPGA firmware into the EMI

0 commit comments

Comments
 (0)