diff options
| author | Wei Fang <wei.fang@nxp.com> | 2025-08-29 13:06:06 +0800 |
|---|---|---|
| committer | Paolo Abeni <pabeni@redhat.com> | 2025-09-02 13:13:33 +0200 |
| commit | 91596332ff5de572576f0f93d5079b2bfc5aeae0 (patch) | |
| tree | 27998e6a179d67eaa33cbd99579134b2b858d907 /scripts/gdb/linux/vmalloc.py | |
| parent | 87a201d59963ebf7185dd3c8b59907f329caa28f (diff) | |
ptp: netc: add PTP_CLK_REQ_PPS support
The NETC Timer is capable of generating a PPS interrupt to the host. To
support this feature, a 64-bit alarm time (which is a integral second
of PHC in the future) is set to TMR_ALARM, and the period is set to
TMR_FIPER. The alarm time is compared to the current time on each update,
then the alarm trigger is used as an indication to the TMR_FIPER starts
down counting. After the period has passed, the PPS event is generated.
According to the NETC block guide, the Timer has three FIPERs, any of
which can be used to generate the PPS events, but in the current
implementation, we only need one of them to implement the PPS feature,
so FIPER 0 is used as the default PPS generator. Also, the Timer has
2 ALARMs, currently, ALARM 0 is used as the default time comparator.
However, if the time is adjusted or the integer of period is changed when
PPS is enabled, the PPS event will not be generated at an integral second
of PHC. The suggested steps from IP team if time drift happens:
1. Disable FIPER before adjusting the hardware time
2. Rearm ALARM after the time adjustment to make the next PPS event be
generated at an integral second of PHC.
3. Re-enable FIPER.
Signed-off-by: Wei Fang <wei.fang@nxp.com>
Reviewed-by: Frank Li <Frank.Li@nxp.com>
Link: https://patch.msgid.link/20250829050615.1247468-6-wei.fang@nxp.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Diffstat (limited to 'scripts/gdb/linux/vmalloc.py')
0 files changed, 0 insertions, 0 deletions
