net: phy: micrel: Add support for PTP_PF_EXTTS for lan8841
authorHoratiu Vultur <horatiu.vultur@microchip.com>
Thu, 23 Mar 2023 10:55:57 +0000 (11:55 +0100)
committerDavid S. Miller <davem@davemloft.net>
Fri, 24 Mar 2023 09:12:33 +0000 (09:12 +0000)
commitfac63186f11682fc5ffd0472d1a990256bd61348
treea20db3796cfd24b8cfeccd117f1626a28eb6708c
parent3228150ba688b8cddc7459e5ae9a09bc2d2e47be
net: phy: micrel: Add support for PTP_PF_EXTTS for lan8841

Extend the PTP programmable gpios to implement also PTP_PF_EXTTS
function. The pins can be configured to capture both of rising
and falling edge. Once the event is seen, then an interrupt is
generated and the LTC is saved in the registers.

This was tested using:
ts2phc -m -l 7 -s generic -f ts2phc.cfg

Where the configuration was the following:
[global]
ts2phc.pin_index  6

[eth2]

Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/micrel.c