git: 171d62055532 - stable/15 - ixl: Reset VSI statistics after initial sampling

From: Kevin Bowling <kbowling_at_FreeBSD.org>
Date: Fri, 18 Sep 2026 00:11:27 UTC
The branch stable/15 has been updated by kbowling:

URL: https://cgit.FreeBSD.org/src/commit/?id=171d620555321de10e0b463ecf9bc9370b9c0faa

commit 171d620555321de10e0b463ecf9bc9370b9c0faa
Author:     Kevin Bowling <kbowling@FreeBSD.org>
AuthorDate: 2026-09-03 10:55:36 +0000
Commit:     Kevin Bowling <kbowling@FreeBSD.org>
CommitDate: 2026-09-18 00:11:18 +0000

    ixl: Reset VSI statistics after initial sampling
    
    The initial statistics update runs before the PF VSI has obtained its
    firmware-assigned statistics counter index.  Discard that provisional
    VSI baseline so the first update after initialization records the
    correct hardware counter.
    
    Without this reset, subtracting a larger provisional value from a newly
    selected counter can be mistaken for a 32-bit wrap and report nearly
    UINT32_MAX receive drops immediately after boot.
    
    Reported by:    Daniel Braniss <danny@cs.huji.ac.il>
    Tested by:      Daniel Braniss <danny@cs.huji.ac.il>
    Obtained from:  Intel ixl 1.14.2
    Sponsored by:   BBOX.io
    Differential Revision:  https://reviews.freebsd.org/D59336
    
    (cherry picked from commit 429cb537015ea11808de23dac8c1cc7ade3a4552)
---
 sys/dev/ixl/if_ixl.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sys/dev/ixl/if_ixl.c b/sys/dev/ixl/if_ixl.c
index 241c2f509af0..e1d666d15d47 100644
--- a/sys/dev/ixl/if_ixl.c
+++ b/sys/dev/ixl/if_ixl.c
@@ -797,6 +797,7 @@ ixl_if_attach_post(if_ctx_t ctx)
 	ixl_pf_reset_stats(pf);
 	ixl_update_stats_counters(pf);
 	ixl_add_hw_stats(pf);
+	ixl_vsi_reset_stats(vsi);
 
 	/*
 	 * Driver may have been reloaded. Ensure that the link state