aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/net/qeth_core.h
diff options
context:
space:
mode:
authorKittipon Meesompop <kmeesomp@linux.vnet.ibm.com>2018-04-26 09:42:19 +0200
committerDavid S. Miller <davem@davemloft.net>2018-04-27 13:38:48 -0400
commit3aade31b2f2dce54d988a42d2e1974c82b25fccf (patch)
treef59985d2e70f460ff954dcbfb918b5e923b844b1 /drivers/s390/net/qeth_core.h
parents390/qeth: disregard IPv4 header for RX csum offload (diff)
downloadlinux-dev-3aade31b2f2dce54d988a42d2e1974c82b25fccf.tar.xz
linux-dev-3aade31b2f2dce54d988a42d2e1974c82b25fccf.zip
s390/qeth: add stats counter for RX csum offload
This matches the statistics we gather for the TX offload path. Signed-off-by: Kittipon Meesompop <kmeesomp@linux.vnet.ibm.com> Signed-off-by: Julian Wiedmann <jwi@linux.vnet.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/s390/net/qeth_core.h')
-rw-r--r--drivers/s390/net/qeth_core.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/s390/net/qeth_core.h b/drivers/s390/net/qeth_core.h
index 2cfeae485a08..e8108f6891b2 100644
--- a/drivers/s390/net/qeth_core.h
+++ b/drivers/s390/net/qeth_core.h
@@ -148,6 +148,7 @@ struct qeth_perf_stats {
unsigned int tx_csum;
unsigned int tx_lin;
unsigned int tx_linfail;
+ unsigned int rx_csum;
};
/* Routing stuff */
@@ -868,10 +869,13 @@ static inline void qeth_rx_csum(struct qeth_card *card, struct sk_buff *skb,
u8 flags)
{
if ((card->dev->features & NETIF_F_RXCSUM) &&
- (flags & QETH_HDR_EXT_CSUM_TRANSP_REQ))
+ (flags & QETH_HDR_EXT_CSUM_TRANSP_REQ)) {
skb->ip_summed = CHECKSUM_UNNECESSARY;
- else
+ if (card->options.performance_stats)
+ card->perf_stats.rx_csum++;
+ } else {
skb->ip_summed = CHECKSUM_NONE;
+ }
}
static inline void qeth_tx_csum(struct sk_buff *skb, u8 *flags)