Merge branch 'Raw-PHY-TDR-data'
authorDavid S. Miller <davem@davemloft.net>
Wed, 27 May 2020 06:22:28 +0000 (23:22 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 27 May 2020 06:22:28 +0000 (23:22 -0700)
commit943bbe1de5fcdec06765de182f30b1b2d05f9c43
treee4625ef1517d3706e3cec3e7f12f5aad32c258ca
parent53c0ec4f4db19d430570bbbfc80ce899419d29f4
parentdb8668a1951954156c039b9f8fe2881d428a522c
Merge branch 'Raw-PHY-TDR-data'

Andrew Lunn says:

====================
Raw PHY TDR data

Some ethernet PHYs allow access to raw TDR data in addition to summary
diagnostics information. Add support for retrieving this data via
netlink ethtool. The basic structure in the core is the same as for
normal phy diagnostics, the PHY driver simply uses different helpers
to fill the netlink message with different data.

There is a graphical tool under development, as well a ethtool(1)
which can dump the data as text and JSON.

A patched ethtool(1) can be found in
https://github.com/lunn/ethtool.git feature/cable-test-v5

Thanks for Chris Healy for lots of testing.

v2:
See the individual patches but:

Pass distances in centimeters, not meters

Allow the PHY to round distances to what it supports and report what
it actually used along with the results.

Make the Marvell PHY use steps a multiple of 0.805 meters, its native
step size.

v3:
Move the TDR configuration into a structure
Add a range check on step
Use NL_SET_ERR_MSG_ATTR() when appropriate
Move TDR configuration into a nest
Document attributes in the request
Unsquash the last two patches
====================

Signed-off-by: David S. Miller <davem@davemloft.net>