net: dsa: sja1105: Switch to hardware operations for PTP
authorVladimir Oltean <olteanv@gmail.com>
Wed, 16 Oct 2019 18:41:02 +0000 (21:41 +0300)
committerDavid S. Miller <davem@davemloft.net>
Fri, 18 Oct 2019 16:55:30 +0000 (12:55 -0400)
commit2fb079a28ae856145e8977d08b77403a3a5d6a70
treee5b7f51f2a6b207f6d2f4355e35c6b7b7e78ae4b
parentd9496f3ecfe4823c1e12aecbcc29220147fa012c
net: dsa: sja1105: Switch to hardware operations for PTP

Adjusting the hardware clock (PTPCLKVAL, PTPCLKADD, PTPCLKRATE) is a
requirement for the auxiliary PTP functionality of the switch
(TTEthernet, PPS input, PPS output).

Therefore we need to switch to using these registers to keep a
synchronized time in hardware, instead of the timecounter/cyclecounter
implementation, which is reliant on the free-running PTPTSCLK.

Signed-off-by: Vladimir Oltean <olteanv@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/dsa/sja1105/sja1105.h
drivers/net/dsa/sja1105/sja1105_ptp.c
drivers/net/dsa/sja1105/sja1105_ptp.h
drivers/net/dsa/sja1105/sja1105_spi.c