提交 12571fe9 编写于 作者: D Dan Carpenter 提交者: Zheng Zengkai

rsi: fix an error code in rsi_probe()

stable inclusion
from stable-5.10.65
commit 56d976f45000f0b8fec0611baf9e3af6c58fc177
bugzilla: 182361 https://gitee.com/openeuler/kernel/issues/I4EH3U

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=56d976f45000f0b8fec0611baf9e3af6c58fc177

--------------------------------

[ Upstream commit 9adcdf67 ]

Return -ENODEV instead of success for unsupported devices.

Fixes: 54fdb318 ("rsi: add new device model for 9116")
Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: NKalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/20210816183947.GA2119@kiliSigned-off-by: NSasha Levin <sashal@kernel.org>
Signed-off-by: NChen Jun <chenjun102@huawei.com>
Acked-by: NWeilong Chen <chenweilong@huawei.com>
Signed-off-by: NChen Jun <chenjun102@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 2a062aa8
......@@ -814,6 +814,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;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册