nuttx/net
Claude 6e14c8cfe5 net/netdev: add NETDEV_TX_STAMP and handle SIOCETHTOOL ETHTOOL_GET_TS_INFO
Add the NETDEV_TX_STAMP capability flag to d_features, next to the
existing NETDEV_RX_STAMP, so a driver can declare that it delivers
hardware TX timestamps.

SIOCETHTOOL and ETHTOOL_GET_TS_INFO were already defined but not
implemented.  Add struct ethtool_ts_info, with the same layout as
Linux, and handle SIOCETHTOOL in netdev_ioctl.c so that userspace (such
as ptpd) can query the timestamping capabilities of an interface the
same way linuxptp/ptp4l does on Linux:

- ETHTOOL_GET_TS_INFO fills so_timestamping from d_features:
  RX_HARDWARE | RAW_HARDWARE with NETDEV_RX_STAMP, otherwise
  RX_SOFTWARE | SOFTWARE (the stack stamps received packets with
  CLOCK_REALTIME), and TX_HARDWARE | RAW_HARDWARE with NETDEV_TX_STAMP.
  phc_index is -1, tx_types and rx_filters are zero.
- Any other ethtool command is passed to the driver's d_ioctl when
  CONFIG_NETDEV_IOCTL is enabled, otherwise -ENOTTY is returned.

Assisted-by: Claude:claude-sonnet-5
Signed-off-by: Daniel P. Carvalho <danieloak@gmail.com>
2026-09-28 12:53:24 -03:00
..
arp net/arp: do not resolve an address to another interface's MAC 2026-08-17 11:28:45 +08:00
bluetooth net/bluetooth: fix BTPROTO_HCI socket device lookup 2026-05-06 14:45:46 +08:00
can net: fix pre-existing coding style issues in timestamp-related files 2026-09-18 20:00:49 +08:00
devif net: fix pre-existing coding style issues in timestamp-related files 2026-09-18 20:00:49 +08:00
icmp !sys/types.h: change time_t and clock_t to int64_t to align with other OSes 2026-05-19 16:21:28 +08:00
icmpv6 !sys/types.h: change time_t and clock_t to int64_t to align with other OSes 2026-05-19 16:21:28 +08:00
ieee802154
igmp net/igmp: fix checksum validation that always dropped valid IGMP packets 2026-08-07 16:36:42 +08:00
inet net: fix pre-existing coding style issues in timestamp-related files 2026-09-18 20:00:49 +08:00
ipfilter
ipforward net/ipv4: Forward fragments before local reassembly 2026-08-01 17:40:07 -03:00
ipfrag net/ipv4: Forward fragments before local reassembly 2026-08-01 17:40:07 -03:00
local net/local: fix SCM_RIGHTS pointer and memory corruption 2026-08-21 02:19:10 +08:00
mld !sys/types.h: change time_t and clock_t to int64_t to align with other OSes 2026-05-19 16:21:28 +08:00
nat net/nat: Reassemble IPv6 fragments before NAT66 2026-08-01 17:40:07 -03:00
neighbor
netdev net/netdev: add NETDEV_TX_STAMP and handle SIOCETHTOOL ETHTOOL_GET_TS_INFO 2026-09-28 12:53:24 -03:00
netfilter
netlink net/netlink: fix memory leak in netlink_get_neighbor 2026-04-13 08:46:57 -03:00
pkt net/pkt: remove unused variable conn in append_timestamping 2026-09-19 18:32:45 -03:00
procfs !include/fcntl.h: align open flags with Linux values 2026-06-30 13:43:44 +08:00
route net/route: fix return value of net_writeroute_ipv6 2026-04-13 08:46:57 -03:00
rpmsg
sixlowpan net/sixlowpan: Fix protosize to 16-bit 2026-07-28 10:19:05 +08:00
socket net: fix pre-existing coding style issues in timestamp-related files 2026-09-18 20:00:49 +08:00
tcp net/tcp: add configurable delayed ACK threshold 2026-09-08 09:00:19 +08:00
udp net: fix pre-existing coding style issues in timestamp-related files 2026-09-18 20:00:49 +08:00
usrsock arch/sim: Add AF_LOCAL support to host usrsock 2026-07-23 15:34:02 +08:00
utils net: fix pre-existing coding style issues in timestamp-related files 2026-09-18 20:00:49 +08:00
CMakeLists.txt
Kconfig net: add NETDEV_RX_STAMP flag in d_features 2026-09-18 20:00:49 +08:00
Makefile tools: fix stale archive members surviving a Kconfig-driven CSRCS change 2026-07-28 21:26:03 -03:00
net_initialize.c