Skip to content

Commit 5c47cde

Browse files
jf-li00nbd168
authored andcommitted
wifi: mt76: mt7921: fix missing unwind goto in mt7921u_probe
`mt7921u_dma_init` can only return zero or negative number according to its definition. When it returns non-zero number, there exists an error and this function should handle this error rather than return directly. Fixes: 0d2afe0 ("mt76: mt7921: add mt7921u driver") Signed-off-by: Jiefeng Li <jiefeng_li@hust.edu.cn> Reviewed-by: Dongliang Mu <dzm91@hust.edu.cn> Reviewed-by: Sridhar Samudrala <sridhar.samudrala@intel.com> Signed-off-by: Felix Fietkau <nbd@nbd.name>
1 parent 12db28c commit 5c47cde

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • drivers/net/wireless/mediatek/mt76/mt7921

drivers/net/wireless/mediatek/mt76/mt7921/usb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ static int mt7921u_probe(struct usb_interface *usb_intf,
259259

260260
ret = mt7921u_dma_init(dev, false);
261261
if (ret)
262-
return ret;
262+
goto error;
263263

264264
hw = mt76_hw(dev);
265265
/* check hw sg support in order to enable AMSDU */

0 commit comments

Comments
 (0)