diff options
| author | David S. Miller <[email protected]> | 2021-07-05 10:16:18 -0700 |
|---|---|---|
| committer | David S. Miller <[email protected]> | 2021-07-05 10:16:18 -0700 |
| commit | c6c205ed442e4609a2bb3e369acc5f1007f782a2 (patch) | |
| tree | 0cf6de55843143b4cec266d801c988cd998063fa /include/linux | |
| parent | f6a175cfcc8df578adfdf06b05c82b3b8c8b5cfd (diff) | |
| parent | e9e3720002f61cd637a49ecafae77cac230eefae (diff) | |
Merge branch 'stmmac-ptp'
Xiaoliang Yang says:
====================
net: stmmac: re-configure tas basetime after ptp time adjust
If the DWMAC Ethernet device has already set the Qbv EST configuration
before using ptp to synchronize the time adjustment, the Qbv base time
may change to be the past time of the new current time. This is not
allowed by hardware.
This patch calculates and re-configures the Qbv basetime after ptp time
adjustment.
v1->v2:
Update est mutex lock to protect btr/ctr r/w to be atomic.
Add btr_reserve to store basetime from qopt and used as origin base
time in Qbv re-configuration.
====================
Signed-off-by: David S. Miller <[email protected]>
Diffstat (limited to 'include/linux')
| -rw-r--r-- | include/linux/stmmac.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/stmmac.h b/include/linux/stmmac.h index d5ae621d66ba..a6f03b36fc4f 100644 --- a/include/linux/stmmac.h +++ b/include/linux/stmmac.h @@ -115,7 +115,9 @@ struct stmmac_axi { #define EST_GCL 1024 struct stmmac_est { + struct mutex lock; int enable; + u32 btr_reserve[2]; u32 btr_offset[2]; u32 btr[2]; u32 ctr[2]; |