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>
This commit is contained in:
parent
0ca8d3ca45
commit
1f88d5d566
|
@ -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;
|
||||
|
|
Loading…
Reference in New Issue