Files
linux/drivers/net/ethernet
Yannick Vignon 80d4609008 net: stmmac: ensure PTP time register reads are consistent
Even if protected from preemption and interrupts, a small time window
remains when the 2 register reads could return inconsistent values,
each time the "seconds" register changes. This could lead to an about
1-second error in the reported time.

Add logic to ensure the "seconds" and "nanoseconds" values are consistent.

Fixes: 92ba688851 ("stmmac: add the support for PTP hw clock driver")
Signed-off-by: Yannick Vignon <[email protected]>
Reviewed-by: Russell King (Oracle) <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Jakub Kicinski <[email protected]>
2022-02-03 13:54:19 -08:00
..
2022-01-09 16:52:18 -08:00
…
…
…
2022-01-09 16:52:18 -08:00
…
…
2022-01-09 16:52:18 -08:00
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…
…