net: Add support for providing the PTP hardware source in tsinfo
authorKory Maincent <kory.maincent@bootlin.com>
Mon, 19 May 2025 08:45:05 +0000 (10:45 +0200)
committerPaolo Abeni <pabeni@redhat.com>
Thu, 22 May 2025 13:32:00 +0000 (15:32 +0200)
commit4ff4d86f6cceb6bea583bdb230e5439655778cce
treedc8483f66a649f9ec2c64e5da1315f9556f54a09
parent3da895b23901964fcf23450f10b529d45069f333
net: Add support for providing the PTP hardware source in tsinfo

Multi-PTP source support within a network topology has been merged,
but the hardware timestamp source is not yet exposed to users.
Currently, users only see the PTP index, which does not indicate
whether the timestamp comes from a PHY or a MAC.

Add support for reporting the hwtstamp source using a
hwtstamp-source field, alongside hwtstamp-phyindex, to describe
the origin of the hardware timestamp.

Remove HWTSTAMP_SOURCE_UNSPEC enum value as it is not used at all.

Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
Link: https://patch.msgid.link/20250519-feature_ptp_source-v4-1-5d10e19a0265@bootlin.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Documentation/netlink/specs/ethtool.yaml
include/linux/ethtool.h
include/linux/net_tstamp.h
include/uapi/linux/ethtool_netlink_generated.h
net/ethtool/common.c
net/ethtool/tsinfo.c