Commit 81fe5d6
Mamatha Inamdar
ibmvnic: Use ndo_get_stats64 to fix inaccurate SAR reporting
JIRA: https://issues.redhat.com/browse/RHEL-104319
commit efe2803
Author: Mingming Cao <mmc@linux.ibm.com>
Date: Wed Jul 16 11:21:15 2025 -0400
ibmvnic: Use ndo_get_stats64 to fix inaccurate SAR reporting
VNIC testing on multi-core Power systems showed SAR stats drift
and packet rate inconsistencies under load.
Implements ndo_get_stats64 to provide safe aggregation of queue-level
atomic64 counters into rtnl_link_stats64 for use by tools like 'ip -s',
'ifconfig', and 'sar'. Switch to ndo_get_stats64 to align SAR reporting
with the standard kernel interface for retrieving netdev stats.
This removes redundant per-adapter stat updates, reduces overhead,
eliminates cacheline bouncing from hot path updates, and improves
the accuracy of reported packet rates.
Signed-off-by: Mingming Cao <mmc@linux.ibm.com>
Reviewed-by: Brian King <bjking1@linux.ibm.com>
Reviewed-by: Dave Marquardt <davemarq@linux.ibm.com>
Reviewed-by: Simon Horman <horms@kernel.org>
----
Changes since v3:
link to v3: https://www.spinics.net/lists/netdev/msg1107999.html
-- keep per queue counters as u64 (this patch) and drop off patch 1 in v3
Link: https://patch.msgid.link/20250716152115.61143-1-mmc@linux.ibm.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Mamatha Inamdar <minamdar@redhat.com>1 parent ede83c7 commit 81fe5d6
1 file changed
+20
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2308 | 2308 | | |
2309 | 2309 | | |
2310 | 2310 | | |
2311 | | - | |
2312 | | - | |
2313 | 2311 | | |
2314 | 2312 | | |
2315 | 2313 | | |
| |||
2642 | 2640 | | |
2643 | 2641 | | |
2644 | 2642 | | |
2645 | | - | |
2646 | | - | |
2647 | | - | |
2648 | 2643 | | |
2649 | 2644 | | |
2650 | 2645 | | |
| |||
3447 | 3442 | | |
3448 | 3443 | | |
3449 | 3444 | | |
| 3445 | + | |
| 3446 | + | |
| 3447 | + | |
| 3448 | + | |
| 3449 | + | |
| 3450 | + | |
| 3451 | + | |
| 3452 | + | |
| 3453 | + | |
| 3454 | + | |
| 3455 | + | |
| 3456 | + | |
| 3457 | + | |
| 3458 | + | |
| 3459 | + | |
| 3460 | + | |
| 3461 | + | |
| 3462 | + | |
| 3463 | + | |
3450 | 3464 | | |
3451 | 3465 | | |
3452 | 3466 | | |
| |||
3562 | 3576 | | |
3563 | 3577 | | |
3564 | 3578 | | |
3565 | | - | |
3566 | | - | |
3567 | 3579 | | |
3568 | 3580 | | |
3569 | 3581 | | |
| |||
3673 | 3685 | | |
3674 | 3686 | | |
3675 | 3687 | | |
| 3688 | + | |
3676 | 3689 | | |
3677 | 3690 | | |
3678 | 3691 | | |
| |||
0 commit comments