During initialization, zero is returned if an unexpected device ID is
read because the returned variable is not written to after a previous
non-zero check. Return -EIO instead to indicate an error occurred.
Detected with the following Coccinelle script:
@@
identifier I;
@@
*if (I) {
...
return ...;
}
if (...) {
... when != I
when any
* return I;
}
Signed-off-by: Jared Kangas <kangas.jd@gmail.com>
|
||
|---|---|---|
| .. | ||
| wsen_hids | ||
| wsen_itds | ||
| wsen_pads | ||
| wsen_pdus | ||
| wsen_tids | ||
| CMakeLists.txt | ||
| Kconfig | ||