Skip to contentSkip to conversation

rsi: fix an error code in rsi_probe()

PATCH In review Dan Carpenter 2 participants 2 messages Aug 16, 2021 – Aug 21, 2021

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rsi: fix an error code in rsi_probe()

Return -ENODEV instead of success for unsupported devices.

Fixes 54fdb318c111 ("rsi: add new device model for 9116")
---
 drivers/net/wireless/rsi/rsi_91x_usb.c | 1 +
 1 file changed, 1 insertion(+)
drivers/net/wireless/rsi/rsi_91x_usb.c +1 -0
index 3fbe2a3c1455..416976f09888 100644
@@ -816,6 +816,7 @@ static int rsi_probe(struct usb_interface *pfunction,
 	} else {
 		rsi_dbg(ERR_ZONE, "%s: Unsupported RSI device id 0x%x\n",
 			__func__, id->idProduct);
+		status = -ENODEV;
 		goto err1;
 	}
 
Signature · 1 line
2.20.1
#1 lore raw
Quoted 4 lines · Dan Carpenter

Return -ENODEV instead of success for unsupported devices.

Fixes 54fdb318c111 ("rsi: add new device model for 9116")

Patch applied to wireless-drivers-next.git, thanks.

9adcdf6758d7 rsi: fix an error code in rsi_probe()

Signature · 3 lines
https://patchwork.kernel.org/project/linux-wireless/patch/20210816183947.GA2119@kili/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches