]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
cxgbe(4): More fixes for the T6 FCS error counter.
authorNavdeep Parhar <np@FreeBSD.org>
Fri, 9 Oct 2020 22:23:39 +0000 (22:23 +0000)
committerNavdeep Parhar <np@FreeBSD.org>
Fri, 9 Oct 2020 22:23:39 +0000 (22:23 +0000)
commit31deb3cc76ab0c46aea968c375d90da117a5bfae
tree2eb9466abcfa0744ab9e321ce393f506b5accfad
parentdeb1339f3f8c9325fffc551e622bf835a08dcd8c
cxgbe(4): More fixes for the T6 FCS error counter.

r365732 was the first attempt to get an accurate count but it was
writing to some read-only registers to clear them and that obviously
didn't work.  Instead, note the counter's value when it is supposed to
be cleared and subtract it from future readings.

dev.<port>.stats.rx_fcs_error should not be serviced from the MPS
register for T6.

The stats.* sysctls should all use T5_PORT_REG for T5 and above.  This
must have been missed in the initial T5 support years ago.  Fix it while
here.

MFC after: 3 days
Sponsored by: Chelsio Communications
sys/dev/cxgbe/adapter.h
sys/dev/cxgbe/common/t4_hw.c
sys/dev/cxgbe/t4_main.c