diff options
author | Grygorii Strashko <grygorii.strashko@ti.com> | 2021-08-05 17:55:53 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-08-06 10:26:46 +0100 |
commit | 1f88d5d566b8be60ce8f8b53132a706fe3184e9e (patch) | |
tree | 1d95fae2a0c04cfb321baa59b990386070792351 /drivers/net/ethernet/ti/cpsw.c | |
parent | 0ca8d3ca4561535f97b31e7b8de569c69bc3b27b (diff) | |
download | linux-1f88d5d566b8be60ce8f8b53132a706fe3184e9e.tar.bz2 |
net: ethernet: ti: cpsw: switch to use skb_put_padto()
Use skb_put_padto() instead of skb_padto() so skb->len also got updated, as
preparation for further removing frame padding from cpdma.
It also makes xmit path more clear and linear.
Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/ti/cpsw.c')
-rw-r--r-- | drivers/net/ethernet/ti/cpsw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c index abf9a2a6f7eb..8e1e582a10c8 100644 --- a/drivers/net/ethernet/ti/cpsw.c +++ b/drivers/net/ethernet/ti/cpsw.c @@ -905,7 +905,7 @@ static netdev_tx_t cpsw_ndo_start_xmit(struct sk_buff *skb, struct cpdma_chan *txch; int ret, q_idx; - if (skb_padto(skb, CPSW_MIN_PACKET_SIZE)) { + if (skb_put_padto(skb, CPSW_MIN_PACKET_SIZE)) { cpsw_err(priv, tx_err, "packet pad failed\n"); ndev->stats.tx_dropped++; return NET_XMIT_DROP; |