Re: [PATCH net-next 3/7] net: ethernet: ti: am65-cpsw-nuss: enable packet timestamping support

From: Grygorii Strashko
Date: Tue May 05 2020 - 08:55:50 EST




On 05/05/2020 14:59, Anders Roxell wrote:
On Tue, 5 May 2020 at 13:16, Anders Roxell <anders.roxell@xxxxxxxxxx> wrote:

On Tue, 5 May 2020 at 13:05, Grygorii Strashko <grygorii.strashko@xxxxxx> wrote:

hi Anders,

Hi Grygorii,

Hi again,



On 05/05/2020 13:17, Anders Roxell wrote:
On Fri, 1 May 2020 at 22:50, Grygorii Strashko <grygorii.strashko@xxxxxx> wrote:

The MCU CPSW Common Platform Time Sync (CPTS) provides possibility to
timestamp TX PTP packets and all RX packets.

This enables corresponding support in TI AM65x/J721E MCU CPSW driver.

Signed-off-by: Grygorii Strashko <grygorii.strashko@xxxxxx>
---
drivers/net/ethernet/ti/Kconfig | 1 +
drivers/net/ethernet/ti/am65-cpsw-ethtool.c | 24 ++-
drivers/net/ethernet/ti/am65-cpsw-nuss.c | 172 ++++++++++++++++++++
drivers/net/ethernet/ti/am65-cpsw-nuss.h | 6 +-
4 files changed, 201 insertions(+), 2 deletions(-)

diff --git a/drivers/net/ethernet/ti/Kconfig b/drivers/net/ethernet/ti/Kconfig
index 1f4e5b6dc686..2c7bd1ccaaec 100644
--- a/drivers/net/ethernet/ti/Kconfig
+++ b/drivers/net/ethernet/ti/Kconfig
@@ -100,6 +100,7 @@ config TI_K3_AM65_CPSW_NUSS
depends on ARCH_K3 && OF && TI_K3_UDMA_GLUE_LAYER
select TI_DAVINCI_MDIO
imply PHY_TI_GMII_SEL
+ imply TI_AM65_CPTS

Should this be TI_K3_AM65_CPTS ?

instead of 'imply TI_K3_AM65_CPTS' don't you want to do this:
'depends on TI_K3_AM65_CPTS || !TI_K3_AM65_CPTS'



this seems will do the trick.
Dependencies:
PTP_1588_CLOCK -> TI_K3_AM65_CPTS -> TI_K3_AM65_CPSW_NUSS

I'll send patch.

--
Best regards,
grygorii