OSDN Git Service

s390/qeth: be drop monitor friendly
authorJulian Wiedmann <jwi@linux.ibm.com>
Mon, 18 Mar 2019 15:40:56 +0000 (16:40 +0100)
committerDavid S. Miller <davem@davemloft.net>
Tue, 19 Mar 2019 01:34:45 +0000 (18:34 -0700)
commit104b48592b5441c722dcd95c38ab9300f2d94856
tree3473dc041ea1a079657e48800aacaf630209b7f9
parent7221b727f0079a32aca91f657141e1de564d4b97
s390/qeth: be drop monitor friendly

As part of the TX completion path, qeth_release_skbs() frees the completed
skbs with __skb_queue_purge(). This ends in kfree_skb(), reporting every
completed skb as dropped.
On the other hand when dropping an skb in .ndo_start_xmit, we end up
calling consume_skb()... where we should be using kfree_skb() so that
drop monitors get notified.

Switch the drop/consume logic around, and also don't accumulate dropped
packets in the tx_errors statistics.

Fixes: dc149e3764d8 ("s390/qeth: replace open-coded skb_queue_walk()")
Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/s390/net/qeth_core_main.c
drivers/s390/net/qeth_l2_main.c
drivers/s390/net/qeth_l3_main.c