diff options
| author | James Hilliard <james.hilliard1@gmail.com> | 2026-10-26 12:11:31 -0600 |
|---|---|---|
| committer | Jakub Kicinski <kuba@kernel.org> | 2026-10-30 16:15:58 -0700 |
| commit | 63787dfd1b5ae720cc30dab5e66c8e4d81ff7391 (patch) | |
| tree | 0c56baa092fc6626518856bc318f214be84bba68 /rust/kernel/alloc/kvec/errors.rs | |
| parent | d3fcce5afe3bb62e8f7a2efb29e43da4fe4ae1f3 (diff) | |
ptp: vclock: preserve missing hardware timestamps
Socket timestamp delivery converts hardware timestamps to a bound
virtual clock before checking whether a hardware timestamp is present.
A zero timestamp means that the packet has no hardware timestamp, but
timecounter_cyc2time() can turn that zero into a nonzero virtual time.
The socket then reports a hardware timestamp which was never supplied.
Return zero without conversion when the input timestamp is absent.
This also covers skb_get_tx_timestamp(), which checks for an absent
timestamp after the same conversion.
This was identified during review of virtual clock sampling changes.
Fixes: d7c088265588 ("net: socket: support hardware timestamp conversion to PHC bound")
Reviewed-by: Vadim Fedorenko <vadim.fedorenko@linux.dev>
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Link: https://patch.msgid.link/20261026-ptp-vclock-sampling-v6-5-e705612541f1@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'rust/kernel/alloc/kvec/errors.rs')
0 files changed, 0 insertions, 0 deletions
