mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-02 16:44:10 +08:00
080bb352fa
We maintain global statistics for an entire MDIO bus, as well as broken down, per MDIO bus address statistics. Given that it is possible for MDIO devices such as switches to access MDIO bus addresses for which there is not a mdio_device instance created (therefore not a a corresponding device directory in sysfs either), we also maintain per-address statistics under the statistics folder. The layout looks like this: /sys/class/mdio_bus/../statistics/ transfers errrors writes reads transfers_<addr> errors_<addr> writes_<addr> reads_<addr> When a mdio_device instance is registered, a statistics/ folder is created with the tranfers, errors, writes and reads attributes which point to the appropriate MDIO bus statistics structure. Statistics are 64-bit unsigned quantities and maintained through the u64_stats_sync.h helper functions. Signed-off-by: Florian Fainelli <f.fainelli@gmail.com> Tested-by: Andrew Lunn <andrew@lunn.ch> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Signed-off-by: David S. Miller <davem@davemloft.net>
64 lines
2.0 KiB
Plaintext
64 lines
2.0 KiB
Plaintext
What: /sys/bus/mdio_bus/devices/.../statistics/
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
This folder contains statistics about global and per
|
|
MDIO bus address statistics.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/transfers
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of transfers for this MDIO bus.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/errors
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of transfer errors for this MDIO bus.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/writes
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of write transactions for this MDIO bus.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/reads
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of read transactions for this MDIO bus.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/transfers_<addr>
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of transfers for this MDIO bus address.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/errors_<addr>
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of transfer errors for this MDIO bus address.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/writes_<addr>
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of write transactions for this MDIO bus address.
|
|
|
|
What: /sys/bus/mdio_bus/devices/.../statistics/reads_<addr>
|
|
Date: January 2020
|
|
KernelVersion: 5.6
|
|
Contact: netdev@vger.kernel.org
|
|
Description:
|
|
Total number of read transactions for this MDIO bus address.
|