Skip to content

Commit 228fb08

Browse files
Wei Yongjundavem330
authored andcommitted
net/spider_net: fix error return code in spider_net_open()
Fix to return a negative error code from the error handling case instead of 0, as done elsewhere in this function. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 59b626e commit 228fb08

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

drivers/net/ethernet/toshiba/spider_net.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1990,7 +1990,8 @@ spider_net_open(struct net_device *netdev)
19901990
goto alloc_rx_failed;
19911991

19921992
/* Allocate rx skbs */
1993-
if (spider_net_alloc_rx_skbs(card))
1993+
result = spider_net_alloc_rx_skbs(card);
1994+
if (result)
19941995
goto alloc_skbs_failed;
19951996

19961997
spider_net_set_multi(netdev);

0 commit comments

Comments
 (0)