RFC ethdev: add Tx timestamp slot APIs
Status from this message: Applied to main 49bb9a5 (release_26_11.rst conflict only). Each
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v5 RFC Latest5 patches 3 repliesApplied
- v4 RFC3 patches 2 repliesSuperseded
- v3 RFC posting 2/21 patch 1 replySuperseded
Earlier versions · 4
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v3 RFC posting 1/2 | 1 patch | 0 replies | Superseded | |
| v2 RFC posting 2/2 | 0 of 1 patch | 0 replies | Superseded | |
| v2 RFC posting 1/2 | 1 patch | 1 reply | Superseded | |
| v1 RFC | 1 patch | 4 replies | Superseded |
Changes in v5 from the cover letter
* Fixed review comments and AI observation.
* Consolidated the Tx timestamp slot API naming onto a single rte_eth_timesync_tx_slot_{caps,alloc,read,release,stamp} prefix, replacing the previous mix of tx_timestamp_slot_*, tx_ts_*, and tx_slot_* spellings across the public API, PMD ops, and the ice implementation.
* Dropped the per-port cached slot-info array in favor of a single process-local dynfield offset/dynflag pair.
* Split the programming guide documentation out of the ethdev patch into two dedicated patches: one documenting the pre-existing clock/Rx timesync API, and one documenting the new Tx timestamp slot feature, so review of the new functionality is not mixed with review of already-existing behavior.
* Fixed inconsistent TX/Tx casing in comments, log messages, and documentation to consistently use "Tx".
Patches in v5 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/5 | ethdev: add Tx timestamp slot management APIsdoc/ doc/ lib/ +2 more | +415 | 0 replies | |
| 2/5 | doc: describe ethdev timesync clock and Rx timestamp APIdoc/ doc/ | +73 | 0 replies | |
| 3/5 | doc: describe ethdev Tx timestamp slot APIdoc/ | +147 | 0 replies | |
| 4/5 | net/ice: support per-packet Tx timestamp slotsdrivers/ drivers/ drivers/ | +219 | 0 replies | |
| 5/5 | app/testpmd: add Tx timestamp capabilities commandapp/ | +79 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v5 yet.
Cover letter [RFC PATCH v5 0/5] ethdev: add Tx timestamp slot APIs
The ethdev timesync API currently exposes Tx timestamps through a shared hardware register. This requires applications to serialize timestamped packets and does not allow correlation when multiple packets are in flight.
This RFC proposes an ethdev interface for hardware with independent Tx timestamp slots. The interface reports the supported timestamping mechanism, provides a port-global slot lifecycle, and lets applications poll each slot asynchronously after transmission.
The proposal includes the following components:
* Capability reporting for shared-register and per-packet timestamping.
* Slot allocation, asynchronous timestamp retrieval, and slot release.
* A dual-domain timestamp structure for adjusted PHC and raw hardware time.
* Mbuf dynamic field and dynflag support for passing slot handles to Tx, with a helper that stamps a slot handle onto an mbuf.
* Registration and process-local reset of the cached dynfield state.
* An ice PMD implementation using the 64 per-port PHY timestamp slots.
* A testpmd command to report the slot capabilities of a port.
* Programming guide documentation, split into a patch describing the pre-existing clock/Rx timesync API and a patch describing the new Tx timestamp slot feature.
The legacy rte_eth_timesync_read_tx_timestamp() API remains available on devices using a shared timestamp register.
Changes since v4:
* Fixed review comments and AI observation.
* Consolidated the Tx timestamp slot API naming onto a single rte_eth_timesync_tx_slot_{caps,alloc,read,release,stamp} prefix, replacing the previous mix of tx_timestamp_slot_*, tx_ts_*, and tx_slot_* spellings across the public API, PMD ops, and the ice implementation.
* Dropped the per-port cached slot-info array in favor of a single process-local dynfield offset/dynflag pair.
* Split the programming guide documentation out of the ethdev patch into two dedicated patches: one documenting the pre-existing clock/Rx timesync API, and one documenting the new Tx timestamp slot feature, so review of the new functionality is not mixed with review of already-existing behavior.
* Fixed inconsistent TX/Tx casing in comments, log messages, and documentation to consistently use "Tx".
Comments and suggestions on the interface and the ice implementation are welcome.
Rajesh Kumar (5):
ethdev: add Tx timestamp slot management APIs
doc: describe ethdev timesync clock and Rx timestamp API
doc: describe ethdev Tx timestamp slot API net/ice: support per-packet Tx timestamp slots app/testpmd: add Tx timestamp capabilities command
app/test-pmd/cmdline.c | 79 ++++++++ doc/guides/nics/features.rst | 15 +- doc/guides/prog_guide/ethdev/index.rst | 1 + doc/guides/prog_guide/ethdev/timesync.rst | 219 +++++++++++++++++++++ doc/guides/rel_notes/release_26_11.rst | 7 + drivers/net/intel/ice/ice_ethdev.c | 211 ++++++++++++++++++++- drivers/net/intel/ice/ice_ethdev.h | 2 + drivers/net/intel/ice/ice_rxtx.c | 9 +- lib/ethdev/ethdev_driver.h | 28 +++ lib/ethdev/rte_ethdev.c | 151 ++++++++++++++- lib/ethdev/rte_ethdev.h | 220 ++++++++++++++++++++++ 11 files changed, 933 insertions(+), 9 deletions(-) create mode 100644 doc/guides/prog_guide/ethdev/timesync.rst
Signature · 1 line
2.55.0