lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <056e03a1-ed13-40b0-b66d-755dd2760988@lunn.ch>
Date: Thu, 29 Aug 2024 20:47:04 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Jakub Kicinski <kuba@...nel.org>
Cc: davem@...emloft.net, netdev@...r.kernel.org, edumazet@...gle.com,
	pabeni@...hat.com, corbet@....net, hkallweit1@...il.com,
	linux@...linux.org.uk, ecree.xilinx@...il.com,
	przemyslaw.kitszel@...el.com, kory.maincent@...tlin.com,
	maxime.chevallier@...tlin.com, linux-doc@...r.kernel.org
Subject: Re: [RFC net-next 2/2] net: ethtool: add phy(dev) specific stats
 over netlink

> +/* Additional PHY statistics, not defined by IEEE */
> +struct ethtool_phy_stats {
> +	/* Basic packet / byte counters are meant for PHY drivers */
> +	u64 rx_packets;
> +	u64 rx_bytes;
> +	u64 rx_error; /* TODO: we need to define here whether packet
> +		       * counted here is also counted as rx_packets,
> +		       * and whether it's passed to the MAC with some
> +		       * error indication or MAC never sees it.
> +		       */
> +	u64 tx_packets;
> +	u64 tx_bytes;
> +	u64 tx_error; /* TODO: same as for rx */
> +};

I'm not sure these are actually useful.

adin.c:
        { "total_frames_checked_count",         0x940A, 0x940B }, /* hi + lo */
        { "length_error_frames_count",          0x940C },
        { "alignment_error_frames_count",       0x940D },
        { "symbol_error_count",                 0x940E },
        { "oversized_frames_count",             0x940F },
        { "undersized_frames_count",            0x9410 },
        { "odd_nibble_frames_count",            0x9411 },
        { "odd_preamble_packet_count",          0x9412 },
        { "dribble_bits_frames_count",          0x9413 },
        { "false_carrier_events_count",         0x9414 },

bcm-phy-lib.c:
        { "phy_receive_errors", -1, MII_BRCM_CORE_BASE12, 0, 16 },
        { "phy_serdes_ber_errors", -1, MII_BRCM_CORE_BASE13, 8, 8 },
        { "phy_false_carrier_sense_errors", -1, MII_BRCM_CORE_BASE13, 0, 8 },
        { "phy_local_rcvr_nok", -1, MII_BRCM_CORE_BASE14, 8, 8 },
        { "phy_remote_rcv_nok", -1, MII_BRCM_CORE_BASE14, 0, 8 },
        { "phy_lpi_count", MDIO_MMD_AN, BRCM_CL45VEN_EEE_LPI_CNT, 0, 16 },

icplus.c:
        { "phy_crc_errors", 1 },
        { "phy_symbol_errors", 11, },

marvell.c:
        { "phy_receive_errors_copper", 0, 21, 16},
        { "phy_idle_errors", 0, 10, 8 },
        { "phy_receive_errors_fiber", 1, 21, 16},

micrel.c:
        { "phy_receive_errors", 21, 16},
        { "phy_idle_errors", 10, 8 },

nxp-c45-tja11xx.c:
        { "phy_link_status_drop_cnt",
        { "phy_link_availability_drop_cnt",
        { "phy_link_loss_cnt",
        { "phy_link_failure_cnt",
        { "phy_symbol_error_cnt",
        { "rx_preamble_count",
        { "tx_preamble_count",
        { "rx_ipg_length",
        { "tx_ipg_length",
        { "phy_symbol_error_cnt_ext",
        { "tx_frames_xtd",
        { "tx_frames",
        { "rx_frames_xtd",
        { "rx_frames",
        { "tx_lost_frames_xtd",
        { "tx_lost_frames",
        { "rx_lost_frames_xtd",
        { "rx_lost_frames",

smsc.c:
        { "phy_symbol_errors", 26, 16},

802.3 does not define in PHY statistics, the same as it does not
define any MAC statistics. As a result it is a wild west, vendors
doing whatever they want.

The exception is the Open Alliance, which have defined a number of
different standards defining statistics which Automotive vendors can
optionally follow.

https://opensig.org/automotive-ethernet-specifications/

These could be defined as either one or three groups, with the
expectation more will be added later.

	Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ