linux-stable/drivers/net/ipvlan
Eric Dumazet ff672b9ffe ipvlan: properly track tx_errors
Both ipvlan_process_v4_outbound() and ipvlan_process_v6_outbound()
increment dev->stats.tx_errors in case of errors.

Unfortunately there are two issues :

1) ipvlan_get_stats64() does not propagate dev->stats.tx_errors to user.

2) Increments are not atomic. KCSAN would complain eventually.

Use DEV_STATS_INC() to not miss an update, and change ipvlan_get_stats64()
to copy the value back to user.

Fixes: 2ad7bf3638 ("ipvlan: Initial check-in of the IPVLAN driver.")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Mahesh Bandewar <maheshb@google.com>
Link: https://lore.kernel.org/r/20231026131446.3933175-1-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
2023-10-27 14:49:09 -07:00
..
ipvlan.h ipvlan: hold lower dev to avoid possible use-after-free 2022-11-18 10:39:22 +00:00
ipvlan_core.c ipvlan: properly track tx_errors 2023-10-27 14:49:09 -07:00
ipvlan_l3s.c ipvlan: fix bound dev checking for IPv6 l3s mode 2023-06-12 09:34:01 +01:00
ipvlan_main.c ipvlan: properly track tx_errors 2023-10-27 14:49:09 -07:00
ipvtap.c drivers: remove struct module * setting from struct class 2023-03-17 15:16:27 +01:00
Makefile treewide: Add SPDX license identifier - Makefile/Kconfig 2019-05-21 10:50:46 +02:00