]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
MFC r365732 and r366589.
authorNavdeep Parhar <np@FreeBSD.org>
Mon, 23 Nov 2020 23:46:07 +0000 (23:46 +0000)
committerNavdeep Parhar <np@FreeBSD.org>
Mon, 23 Nov 2020 23:46:07 +0000 (23:46 +0000)
commitb4cfce000a9a28239d2d256babf07245e9fc8ac6
tree5070e6bc6ad1bbc24c131160266dac3c3e9bbea4
parenta524fa00367324864715dfe586bee4f2b1170d98
MFC r365732 and r366589.

r365732:
cxgbe(4): Get the count of FCS errors from the MAC and not MPS for T6 ports.

The MPS register on the T6 counts something other than FCS errors despite its
name.

r366589:
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.

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