diff mbox series

[6/6] net: ethernet: ti: cpsw: deprecate cpsw-phy-sel driver

Message ID 1550676319-6440-7-git-send-email-grygorii.strashko@ti.com
State RFC
Delegated to: David Miller
Headers show
Series ARM: dts: ti: cpsw: switch to phy-gmii-sel phy driver | expand

Commit Message

Grygorii Strashko Feb. 20, 2019, 3:25 p.m. UTC
Deprecate cpsw-phy-sel driver as it's been replaced with new
TI phy-gmii-sel PHY driver.

Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
---
 drivers/net/ethernet/ti/Kconfig | 6 +++---
 drivers/net/ethernet/ti/cpsw.h  | 6 ++++++
 2 files changed, 9 insertions(+), 3 deletions(-)

Comments

Tony Lindgren Feb. 20, 2019, 4:18 p.m. UTC | #1
Hi,

* Grygorii Strashko <grygorii.strashko@ti.com> [190220 15:26]:
> Deprecate cpsw-phy-sel driver as it's been replaced with new
> TI phy-gmii-sel PHY driver.

I'm not going to pick up this one, seems that Dave can merge
this later on? That is unless Dave wants to ack this one.

Regards,

Tony

> Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
> ---
>  drivers/net/ethernet/ti/Kconfig | 6 +++---
>  drivers/net/ethernet/ti/cpsw.h  | 6 ++++++
>  2 files changed, 9 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/net/ethernet/ti/Kconfig b/drivers/net/ethernet/ti/Kconfig
> index bb126be1eb72..8b21b40a9fe5 100644
> --- a/drivers/net/ethernet/ti/Kconfig
> +++ b/drivers/net/ethernet/ti/Kconfig
> @@ -49,10 +49,11 @@ config TI_DAVINCI_CPDMA
>  	  will be called davinci_cpdma.  This is recommended.
>  
>  config TI_CPSW_PHY_SEL
> -	bool
> +	bool "TI CPSW Phy mode Selection (DEPRECATED)"
> +	default n
>  	---help---
>  	  This driver supports configuring of the phy mode connected to
> -	  the CPSW.
> +	  the CPSW. DEPRECATED: use PHY_TI_GMII_SEL.
>  
>  config TI_CPSW_ALE
>  	tristate "TI CPSW ALE Support"
> @@ -64,7 +65,6 @@ config TI_CPSW
>  	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS || COMPILE_TEST
>  	select TI_DAVINCI_CPDMA
>  	select TI_DAVINCI_MDIO
> -	select TI_CPSW_PHY_SEL
>  	select TI_CPSW_ALE
>  	select MFD_SYSCON
>  	select REGMAP
> diff --git a/drivers/net/ethernet/ti/cpsw.h b/drivers/net/ethernet/ti/cpsw.h
> index cf111db3dc27..907e05fc22e4 100644
> --- a/drivers/net/ethernet/ti/cpsw.h
> +++ b/drivers/net/ethernet/ti/cpsw.h
> @@ -21,7 +21,13 @@
>  			 ((mac)[2] << 16) | ((mac)[3] << 24))
>  #define mac_lo(mac)	(((mac)[4] << 0) | ((mac)[5] << 8))
>  
> +#if IS_ENABLED(CONFIG_TI_CPSW_PHY_SEL)
>  void cpsw_phy_sel(struct device *dev, phy_interface_t phy_mode, int slave);
> +#else
> +static inline
> +void cpsw_phy_sel(struct device *dev, phy_interface_t phy_mode, int slave)
> +{}
> +#endif
>  int ti_cm_get_macid(struct device *dev, int slave, u8 *mac_addr);
>  
>  #endif /* __CPSW_H__ */
> -- 
> 2.17.1
>
David Miller Feb. 20, 2019, 7:22 p.m. UTC | #2
From: Grygorii Strashko <grygorii.strashko@ti.com>
Date: Wed, 20 Feb 2019 17:25:19 +0200

> Deprecate cpsw-phy-sel driver as it's been replaced with new
> TI phy-gmii-sel PHY driver.
> 
> Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>

Acked-by: David S. Miller <davem@davemloft.net>
Tony Lindgren Feb. 20, 2019, 8:33 p.m. UTC | #3
* David Miller <davem@davemloft.net> [190220 19:23]:
> From: Grygorii Strashko <grygorii.strashko@ti.com>
> Date: Wed, 20 Feb 2019 17:25:19 +0200
> 
> > Deprecate cpsw-phy-sel driver as it's been replaced with new
> > TI phy-gmii-sel PHY driver.
> > 
> > Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
> 
> Acked-by: David S. Miller <davem@davemloft.net>

Thanks for the ack, but actually I'd prefer you to pick
this patch at some future date. I suggest Grygorii just
repost this one after v5.1-rc1.

This way I can keep my last pending v5.1 branch limited
to dts changes to make the arm-soc life easier.

Regards,

Tony
David Miller Feb. 20, 2019, 8:41 p.m. UTC | #4
From: Tony Lindgren <tony@atomide.com>
Date: Wed, 20 Feb 2019 12:33:26 -0800

> * David Miller <davem@davemloft.net> [190220 19:23]:
>> From: Grygorii Strashko <grygorii.strashko@ti.com>
>> Date: Wed, 20 Feb 2019 17:25:19 +0200
>> 
>> > Deprecate cpsw-phy-sel driver as it's been replaced with new
>> > TI phy-gmii-sel PHY driver.
>> > 
>> > Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
>> 
>> Acked-by: David S. Miller <davem@davemloft.net>
> 
> Thanks for the ack, but actually I'd prefer you to pick
> this patch at some future date. I suggest Grygorii just
> repost this one after v5.1-rc1.

It's so much easier if you group this with those DT changes, they
logically belong together as well and it helps someone reading
the changes in the tree also if they are side by side.

Why don't you want to integrate this with them?
Tony Lindgren Feb. 20, 2019, 9:01 p.m. UTC | #5
* David Miller <davem@davemloft.net> [190220 20:42]:
> From: Tony Lindgren <tony@atomide.com>
> Date: Wed, 20 Feb 2019 12:33:26 -0800
> 
> > * David Miller <davem@davemloft.net> [190220 19:23]:
> >> From: Grygorii Strashko <grygorii.strashko@ti.com>
> >> Date: Wed, 20 Feb 2019 17:25:19 +0200
> >> 
> >> > Deprecate cpsw-phy-sel driver as it's been replaced with new
> >> > TI phy-gmii-sel PHY driver.
> >> > 
> >> > Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com>
> >> 
> >> Acked-by: David S. Miller <davem@davemloft.net>
> > 
> > Thanks for the ack, but actually I'd prefer you to pick
> > this patch at some future date. I suggest Grygorii just
> > repost this one after v5.1-rc1.
> 
> It's so much easier if you group this with those DT changes, they
> logically belong together as well and it helps someone reading
> the changes in the tree also if they are side by side.

I agree that a group of patches should go together in
most cases.

> Why don't you want to integrate this with them?

Because the arm-soc tree wants dts changes separately in
general. The dts changes are considered firmware describing
hardware. And it makes it possible to split the arm-soc pile
of patches into multiple pull requests. In theory there
should be no dependency between dts changes and driver
changes, but in reality that's not always the case :)

What I can do is set up a separate branch with just this
patch on top of the dts changes that the arm-soc guys can
then merge towards the end of the merge cycle. If that
works for you, let me know and I'll do it.

Regards,

Tony
David Miller Feb. 21, 2019, 12:18 a.m. UTC | #6
From: Tony Lindgren <tony@atomide.com>
Date: Wed, 20 Feb 2019 13:01:27 -0800

> What I can do is set up a separate branch with just this
> patch on top of the dts changes that the arm-soc guys can
> then merge towards the end of the merge cycle. If that
> works for you, let me know and I'll do it.

Yes, it does work for me.

Thanks.
Tony Lindgren Feb. 21, 2019, 4:36 p.m. UTC | #7
* David Miller <davem@davemloft.net> [190221 00:18]:
> From: Tony Lindgren <tony@atomide.com>
> Date: Wed, 20 Feb 2019 13:01:27 -0800
> 
> > What I can do is set up a separate branch with just this
> > patch on top of the dts changes that the arm-soc guys can
> > then merge towards the end of the merge cycle. If that
> > works for you, let me know and I'll do it.
> 
> Yes, it does work for me.

OK I've applied this patch into omap-for-v5.1/cpsw.

Thanks,

Tony
diff mbox series

Patch

diff --git a/drivers/net/ethernet/ti/Kconfig b/drivers/net/ethernet/ti/Kconfig
index bb126be1eb72..8b21b40a9fe5 100644
--- a/drivers/net/ethernet/ti/Kconfig
+++ b/drivers/net/ethernet/ti/Kconfig
@@ -49,10 +49,11 @@  config TI_DAVINCI_CPDMA
 	  will be called davinci_cpdma.  This is recommended.
 
 config TI_CPSW_PHY_SEL
-	bool
+	bool "TI CPSW Phy mode Selection (DEPRECATED)"
+	default n
 	---help---
 	  This driver supports configuring of the phy mode connected to
-	  the CPSW.
+	  the CPSW. DEPRECATED: use PHY_TI_GMII_SEL.
 
 config TI_CPSW_ALE
 	tristate "TI CPSW ALE Support"
@@ -64,7 +65,6 @@  config TI_CPSW
 	depends on ARCH_DAVINCI || ARCH_OMAP2PLUS || COMPILE_TEST
 	select TI_DAVINCI_CPDMA
 	select TI_DAVINCI_MDIO
-	select TI_CPSW_PHY_SEL
 	select TI_CPSW_ALE
 	select MFD_SYSCON
 	select REGMAP
diff --git a/drivers/net/ethernet/ti/cpsw.h b/drivers/net/ethernet/ti/cpsw.h
index cf111db3dc27..907e05fc22e4 100644
--- a/drivers/net/ethernet/ti/cpsw.h
+++ b/drivers/net/ethernet/ti/cpsw.h
@@ -21,7 +21,13 @@ 
 			 ((mac)[2] << 16) | ((mac)[3] << 24))
 #define mac_lo(mac)	(((mac)[4] << 0) | ((mac)[5] << 8))
 
+#if IS_ENABLED(CONFIG_TI_CPSW_PHY_SEL)
 void cpsw_phy_sel(struct device *dev, phy_interface_t phy_mode, int slave);
+#else
+static inline
+void cpsw_phy_sel(struct device *dev, phy_interface_t phy_mode, int slave)
+{}
+#endif
 int ti_cm_get_macid(struct device *dev, int slave, u8 *mac_addr);
 
 #endif /* __CPSW_H__ */