Skip to content

Commit

Permalink
net: renesas: rswitch: Fix return value in error path of xmit
Browse files Browse the repository at this point in the history
Fix return value in the error path of rswitch_start_xmit(). If TX
queues are full, this function should return NETDEV_TX_BUSY.

Fixes: 3590918 ("net: ethernet: renesas: Add support for "Ethernet Switch"")
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Link: https://lore.kernel.org/r/20230529073817.1145208-1-yoshihiro.shimoda.uh@renesas.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  • Loading branch information
Yoshihiro Shimoda authored and Jakub Kicinski committed Jun 1, 2023
1 parent 3c27f3d commit a60caf0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/ethernet/renesas/rswitch.c
Original file line number Diff line number Diff line change
Expand Up @@ -1485,7 +1485,7 @@ static netdev_tx_t rswitch_start_xmit(struct sk_buff *skb, struct net_device *nd

if (rswitch_get_num_cur_queues(gq) >= gq->ring_size - 1) {
netif_stop_subqueue(ndev, 0);
return ret;
return NETDEV_TX_BUSY;
}

if (skb_put_padto(skb, ETH_ZLEN))
Expand Down

0 comments on commit a60caf0

Please sign in to comment.