* [PATCH] ice/ptp: fix crosstimestamp reporting
@ 2025-07-25 20:33 Markus Blöchl
2025-07-26 1:37 ` Sasha Levin
2025-08-24 7:52 ` Greg KH
0 siblings, 2 replies; 5+ messages in thread
From: Markus Blöchl @ 2025-07-25 20:33 UTC (permalink / raw)
To: stable; +Cc: linux-kernel, Anton Nadezhdin, markus.bloechl
From: Anton Nadezhdin <anton.nadezhdin@intel.com>
commit a5a441ae283d upstream.
Set use_nsecs=true as timestamp is reported in ns. Lack of this result
in smaller timestamp error window which cause error during phc2sys
execution on E825 NICs:
phc2sys[1768.256]: ioctl PTP_SYS_OFFSET_PRECISE: Invalid argument
This problem was introduced in the cited commit which omitted setting
use_nsecs to true when converting the ice driver to use
convert_base_to_cs().
Testing hints (ethX is PF netdev):
phc2sys -s ethX -c CLOCK_REALTIME -O 37 -m
phc2sys[1769.256]: CLOCK_REALTIME phc offset -5 s0 freq -0 delay 0
Fixes: d4bea547ebb57 ("ice/ptp: Remove convert_art_to_tsc()")
Signed-off-by: Anton Nadezhdin <anton.nadezhdin@intel.com>
Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
Reviewed-by: Arkadiusz Kubalewski <arkadiusz.kubalewski@intel.com>
Tested-by: Rinitha S <sx.rinitha@intel.com>
Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
Signed-off-by: Markus Blöchl <markus@blochl.de>
---
Hi Greg,
please consider this backport for linux-6.12.y
It fixes a regression from the series around
d4bea547ebb57 ("ice/ptp: Remove convert_art_to_tsc()")
which affected multiple drivers and occasionally
caused phc2sys to fail on ioctl(fd, PTP_SYS_OFFSET_PRECISE, ...).
This was the initial fix for ice but apparently tagging it
for stable was forgotten during submission.
The hunk was moved around slightly in the upstream commit
92456e795ac6 ("ice: Add unified ice_capture_crosststamp")
from ice_ptp_get_syncdevicetime() into another helper function
ice_capture_crosststamp() so its indentation and context have changed.
I adapted it to apply cleanly.
---
drivers/net/ethernet/intel/ice/ice_ptp.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/net/ethernet/intel/ice/ice_ptp.c b/drivers/net/ethernet/intel/ice/ice_ptp.c
index 7c6f81beaee4602050b4cf366441a2584507d949..369c968a0117d0f7012241fd3e2c0a45a059bfa4 100644
--- a/drivers/net/ethernet/intel/ice/ice_ptp.c
+++ b/drivers/net/ethernet/intel/ice/ice_ptp.c
@@ -2226,6 +2226,7 @@ ice_ptp_get_syncdevicetime(ktime_t *device,
hh_ts = ((u64)hh_ts_hi << 32) | hh_ts_lo;
system->cycles = hh_ts;
system->cs_id = CSID_X86_ART;
+ system->use_nsecs = true;
/* Read Device source clock time */
hh_ts_lo = rd32(hw, GLTSYN_HHTIME_L(tmr_idx));
hh_ts_hi = rd32(hw, GLTSYN_HHTIME_H(tmr_idx));
---
base-commit: d90ecb2b1308b3e362ec4c21ff7cf0a051b445df
change-id: 20250716-ice_crosstimestamp_reporting-b6236a246c48
Best regards,
--
Markus Blöchl <markus@blochl.de>
--
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] ice/ptp: fix crosstimestamp reporting
2025-07-25 20:33 [PATCH] ice/ptp: fix crosstimestamp reporting Markus Blöchl
@ 2025-07-26 1:37 ` Sasha Levin
2025-08-07 12:34 ` Markus Blöchl
2025-08-24 7:52 ` Greg KH
1 sibling, 1 reply; 5+ messages in thread
From: Sasha Levin @ 2025-07-26 1:37 UTC (permalink / raw)
To: stable, markus; +Cc: Sasha Levin
[ Sasha's backport helper bot ]
Hi,
Summary of potential issues:
❌ Patch application failures detected
⚠️ Found matching upstream commit but patch is missing proper reference to it
Found matching upstream commit: a5a441ae283d54ec329aadc7426991dc32786d52
WARNING: Author mismatch between patch and found commit:
Backport author: Markus Blöchl <markus@blochl.de>
Commit author: Anton Nadezhdin <anton.nadezhdin@intel.com>
Note: Could not generate a diff with upstream commit:
---
Note: Could not generate diff - patch failed to apply for comparison
---
Results of testing on various branches:
| Branch | Patch Apply | Build Test |
|---------------------------|-------------|------------|
| origin/linux-6.15.y | Failed | N/A |
| origin/linux-6.12.y | Success | Success |
| origin/linux-6.6.y | Failed | N/A |
| origin/linux-6.1.y | Failed | N/A |
| origin/linux-5.15.y | Failed | N/A |
| origin/linux-5.10.y | Failed | N/A |
| origin/linux-5.4.y | Failed | N/A |
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ice/ptp: fix crosstimestamp reporting
2025-07-26 1:37 ` Sasha Levin
@ 2025-08-07 12:34 ` Markus Blöchl
2025-08-07 13:54 ` Sasha Levin
0 siblings, 1 reply; 5+ messages in thread
From: Markus Blöchl @ 2025-08-07 12:34 UTC (permalink / raw)
To: Sasha Levin; +Cc: stable, markus
Hi Sasha,
Sorry, I don't really know how to handle this response from your bot:
On Fri, Jul 25, 2025 at 09:37:11PM -0400, Sasha Levin wrote:
> [ Sasha's backport helper bot ]
>
> Hi,
>
> Summary of potential issues:
> ❌ Patch application failures detected
> ⚠️ Found matching upstream commit but patch is missing proper reference to it
The patch clearly mentions `commit a5a441ae283d upstream.` to me.
Am I too blind to spot a typo or similar?
>
> Found matching upstream commit: a5a441ae283d54ec329aadc7426991dc32786d52
>
> WARNING: Author mismatch between patch and found commit:
> Backport author: Markus Blöchl <markus@blochl.de>
> Commit author: Anton Nadezhdin <anton.nadezhdin@intel.com>
This mismatch is intentional.
I did not author the original fix. I merely backported it to 6.12.y.
So I kept the original author when cherry-picking.
>
> Note: Could not generate a diff with upstream commit:
> ---
> Note: Could not generate diff - patch failed to apply for comparison
> ---
>
> Results of testing on various branches:
>
> | Branch | Patch Apply | Build Test |
> |---------------------------|-------------|------------|
> | origin/linux-6.15.y | Failed | N/A |
> | origin/linux-6.12.y | Success | Success |
> | origin/linux-6.6.y | Failed | N/A |
> | origin/linux-6.1.y | Failed | N/A |
> | origin/linux-5.15.y | Failed | N/A |
> | origin/linux-5.10.y | Failed | N/A |
> | origin/linux-5.4.y | Failed | N/A |
As written, the backport is for 6.12.y only.
If there is anything I should do or change, please let me know.
Thanks,
Markus
--
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ice/ptp: fix crosstimestamp reporting
2025-08-07 12:34 ` Markus Blöchl
@ 2025-08-07 13:54 ` Sasha Levin
0 siblings, 0 replies; 5+ messages in thread
From: Sasha Levin @ 2025-08-07 13:54 UTC (permalink / raw)
To: Markus Blöchl; +Cc: stable
On Thu, Aug 07, 2025 at 02:34:10PM +0200, Markus Blöchl wrote:
>Hi Sasha,
>
>Sorry, I don't really know how to handle this response from your bot:
>
>On Fri, Jul 25, 2025 at 09:37:11PM -0400, Sasha Levin wrote:
>> [ Sasha's backport helper bot ]
>>
>> Hi,
>>
>> Summary of potential issues:
>> ❌ Patch application failures detected
>> ⚠️ Found matching upstream commit but patch is missing proper reference to it
>
>The patch clearly mentions `commit a5a441ae283d upstream.` to me.
>Am I too blind to spot a typo or similar?
It should be the fully 40 char sha1, not a shortened version.
>>
>> Found matching upstream commit: a5a441ae283d54ec329aadc7426991dc32786d52
>>
>> WARNING: Author mismatch between patch and found commit:
>> Backport author: Markus Blöchl <markus@blochl.de>
>> Commit author: Anton Nadezhdin <anton.nadezhdin@intel.com>
>
>This mismatch is intentional.
>I did not author the original fix. I merely backported it to 6.12.y.
>So I kept the original author when cherry-picking.
That ok, it's mostly just a warning for us to see if we need to get
additional acks or do a more careful review.
>>
>> Note: Could not generate a diff with upstream commit:
>> ---
>> Note: Could not generate diff - patch failed to apply for comparison
>> ---
>>
>> Results of testing on various branches:
>>
>> | Branch | Patch Apply | Build Test |
>> |---------------------------|-------------|------------|
>> | origin/linux-6.15.y | Failed | N/A |
>> | origin/linux-6.12.y | Success | Success |
>> | origin/linux-6.6.y | Failed | N/A |
>> | origin/linux-6.1.y | Failed | N/A |
>> | origin/linux-5.15.y | Failed | N/A |
>> | origin/linux-5.10.y | Failed | N/A |
>> | origin/linux-5.4.y | Failed | N/A |
>
>As written, the backport is for 6.12.y only.
Normally you'd indicate which trees you want the patch to be applied to
in the subject line. In this case it would be something like:
[PATCH 6.12] ice/ptp: fix crosstimestamp reporting
--
Thanks,
Sasha
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] ice/ptp: fix crosstimestamp reporting
2025-07-25 20:33 [PATCH] ice/ptp: fix crosstimestamp reporting Markus Blöchl
2025-07-26 1:37 ` Sasha Levin
@ 2025-08-24 7:52 ` Greg KH
1 sibling, 0 replies; 5+ messages in thread
From: Greg KH @ 2025-08-24 7:52 UTC (permalink / raw)
To: Markus Blöchl; +Cc: stable, linux-kernel, Anton Nadezhdin, markus.bloechl
On Fri, Jul 25, 2025 at 10:33:31PM +0200, Markus Blöchl wrote:
> From: Anton Nadezhdin <anton.nadezhdin@intel.com>
>
> commit a5a441ae283d upstream.
>
> Set use_nsecs=true as timestamp is reported in ns. Lack of this result
> in smaller timestamp error window which cause error during phc2sys
> execution on E825 NICs:
> phc2sys[1768.256]: ioctl PTP_SYS_OFFSET_PRECISE: Invalid argument
>
> This problem was introduced in the cited commit which omitted setting
> use_nsecs to true when converting the ice driver to use
> convert_base_to_cs().
>
> Testing hints (ethX is PF netdev):
> phc2sys -s ethX -c CLOCK_REALTIME -O 37 -m
> phc2sys[1769.256]: CLOCK_REALTIME phc offset -5 s0 freq -0 delay 0
>
> Fixes: d4bea547ebb57 ("ice/ptp: Remove convert_art_to_tsc()")
> Signed-off-by: Anton Nadezhdin <anton.nadezhdin@intel.com>
> Reviewed-by: Aleksandr Loktionov <aleksandr.loktionov@intel.com>
> Reviewed-by: Arkadiusz Kubalewski <arkadiusz.kubalewski@intel.com>
> Tested-by: Rinitha S <sx.rinitha@intel.com>
> Signed-off-by: Tony Nguyen <anthony.l.nguyen@intel.com>
> Signed-off-by: Markus Blöchl <markus@blochl.de>
> ---
> Hi Greg,
>
> please consider this backport for linux-6.12.y
>
> It fixes a regression from the series around
> d4bea547ebb57 ("ice/ptp: Remove convert_art_to_tsc()")
> which affected multiple drivers and occasionally
> caused phc2sys to fail on ioctl(fd, PTP_SYS_OFFSET_PRECISE, ...).
>
> This was the initial fix for ice but apparently tagging it
> for stable was forgotten during submission.
>
> The hunk was moved around slightly in the upstream commit
> 92456e795ac6 ("ice: Add unified ice_capture_crosststamp")
> from ice_ptp_get_syncdevicetime() into another helper function
> ice_capture_crosststamp() so its indentation and context have changed.
> I adapted it to apply cleanly.
> ---
> drivers/net/ethernet/intel/ice/ice_ptp.c | 1 +
> 1 file changed, 1 insertion(+)
This is already in the 6.12.42 release, so we don't need to apply it
again, right?
thanks,
greg k-h
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-08-24 7:52 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-25 20:33 [PATCH] ice/ptp: fix crosstimestamp reporting Markus Blöchl
2025-07-26 1:37 ` Sasha Levin
2025-08-07 12:34 ` Markus Blöchl
2025-08-07 13:54 ` Sasha Levin
2025-08-24 7:52 ` Greg KH
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox