Skip to content

Commit ffc9c3e

Browse files
petkomanolovdavem330
authored andcommitted
net: usb: pegasus: fixes of set_register(s) return value evaluation;
- restore the behavior in enable_net_traffic() to avoid regressions - Jakub Kicinski; - hurried up and removed redundant assignment in pegasus_open() before yet another checker complains; Fixes: 8a160e2 ("net: usb: pegasus: Check the return value of get_geristers() and friends;") Reported-by: Jakub Kicinski <[email protected]> Signed-off-by: Petko Manolov <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 7e78c59 commit ffc9c3e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

drivers/net/usb/pegasus.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -446,7 +446,7 @@ static int enable_net_traffic(struct net_device *dev, struct usb_device *usb)
446446
write_mii_word(pegasus, 0, 0x1b, &auxmode);
447447
}
448448

449-
return 0;
449+
return ret;
450450
fail:
451451
netif_dbg(pegasus, drv, pegasus->net, "%s failed\n", __func__);
452452
return ret;
@@ -835,7 +835,7 @@ static int pegasus_open(struct net_device *net)
835835
if (!pegasus->rx_skb)
836836
goto exit;
837837

838-
res = set_registers(pegasus, EthID, 6, net->dev_addr);
838+
set_registers(pegasus, EthID, 6, net->dev_addr);
839839

840840
usb_fill_bulk_urb(pegasus->rx_urb, pegasus->usb,
841841
usb_rcvbulkpipe(pegasus->usb, 1),

0 commit comments

Comments
 (0)