diff options
author | Yang Wei <yang.wei9@zte.com.cn> | 2019-01-29 23:32:22 +0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-01-29 10:09:28 -0800 |
commit | e339f8631eb70fb48b2801e9e66a267c9a730a6a (patch) | |
tree | 8b42e09e746ebb55784da8be31cb8a9264a5a677 /drivers/net/caif | |
parent | 896cebc0e261a29a6f0b20ab21d1bfc06959e91d (diff) |
net: caif: call dev_consume_skb_any when skb xmit done
The skb shouled be consumed when xmit done, it makes drop profiles
(dropwatch, perf) more friendly.
dev_kfree_skb_irq()/kfree_skb() shouled be replaced by
dev_consume_skb_any(), it makes code cleaner.
Signed-off-by: Yang Wei <yang.wei9@zte.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/caif')
-rw-r--r-- | drivers/net/caif/caif_serial.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/net/caif/caif_serial.c b/drivers/net/caif/caif_serial.c index a0f954f36c09..44e6c7b1b222 100644 --- a/drivers/net/caif/caif_serial.c +++ b/drivers/net/caif/caif_serial.c @@ -257,10 +257,7 @@ static int handle_tx(struct ser_device *ser) if (skb->len == 0) { struct sk_buff *tmp = skb_dequeue(&ser->head); WARN_ON(tmp != skb); - if (in_interrupt()) - dev_kfree_skb_irq(skb); - else - kfree_skb(skb); + dev_consume_skb_any(skb); } } /* Send flow off if queue is empty */ |