All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kishon Vijay Abraham I <kishon@ti.com>
To: balbi@ti.com, Arun Ramamurthy <arun.ramamurthy@broadcom.com>
Cc: Jonathan Corbet <corbet@lwn.net>, Tejun Heo <tj@kernel.org>,
	Kyungmin Park <kyungmin.park@samsung.com>,
	Sylwester Nawrocki <s.nawrocki@samsung.com>,
	Mauro Carvalho Chehab <mchehab@osg.samsung.com>,
	Kukjin Kim <kgene@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Alan Stern <stern@rowland.harvard.edu>,
	Tony Prisk <linux@prisktech.co.nz>,
	Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	Arnd Bergmann <arnd@arndb.de>,
	Mathias Nyman <mathias.nyman@linux.intel.com>,
	Paul Bolle <pebolle@tiscali.nl>,
	Thomas Pugliese <thomas.pugliese@gmail.com>,
	Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
	Masanari Iida <standby24x7@gmail.com>,
	David Mosberger <davidm@egauge.net>,
	Peter Griffin <peter.griffin@linaro.org>,
	Gregory CLEMENT <gregory.clement@free-electrons.com>,
	Laurent Pinchart <laurent.pinchart@ideasonb>
Subject: Re: [PATCHv3 1/4] phy: phy-core: Make GENERIC_PHY an invisible option
Date: Fri, 29 May 2015 17:04:38 +0530	[thread overview]
Message-ID: <55684ECE.9060003@ti.com> (raw)
In-Reply-To: <20150526183955.GW26599@saruman.tx.rr.com>

Hi Felipe,

On Wednesday 27 May 2015 12:09 AM, Felipe Balbi wrote:
> On Tue, May 26, 2015 at 11:37:17AM -0700, Arun Ramamurthy wrote:
>> Hi
>>
>> On 15-05-26 07:19 AM, Felipe Balbi wrote:
>>> HI,
>>>
>>> On Mon, May 25, 2015 at 02:19:58PM -0700, Arun Ramamurthy wrote:
>>>>
>>>>
>>>> On 15-05-14 05:52 PM, Felipe Balbi wrote:
>>>>> Hi,
>>>>>
>>>>> On Wed, Apr 22, 2015 at 04:04:10PM -0700, Arun Ramamurthy wrote:
>>>>>> Most of the phy providers use "select" to enable GENERIC_PHY. Since select
>>>>>> is only recommended when the config is not visible, GENERIC_PHY is changed
>>>>>> an invisible option. To maintain consistency, all phy providers are changed
>>>>>> to "select" GENERIC_PHY and all non-phy drivers use "depends on" when the
>>>>>> phy framework is explicity required. USB_MUSB_OMAP2PLUS has a cyclic
>>>>>> dependency, so it is left as "select".
>>>>>>
>>>>>> Signed-off-by: Arun Ramamurthy <arun.ramamurthy@broadcom.com>
>>>>>> ---
>>>>>>   drivers/ata/Kconfig                       | 1 -
>>>>>>   drivers/media/platform/exynos4-is/Kconfig | 2 +-
>>>>>>   drivers/phy/Kconfig                       | 4 ++--
>>>>>>   drivers/usb/host/Kconfig                  | 4 ++--
>>>>>>   drivers/video/fbdev/exynos/Kconfig        | 2 +-
>>>>>>   5 files changed, 6 insertions(+), 7 deletions(-)
>>>>>>
>>>>>> diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig
>>>>>> index 5f60155..6d2e881 100644
>>>>>> --- a/drivers/ata/Kconfig
>>>>>> +++ b/drivers/ata/Kconfig
>>>>>> @@ -301,7 +301,6 @@ config SATA_MV
>>>>>>   	tristate "Marvell SATA support"
>>>>>>   	depends on PCI || ARCH_DOVE || ARCH_MV78XX0 || \
>>>>>>   		   ARCH_MVEBU || ARCH_ORION5X || COMPILE_TEST
>>>>>> -	select GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This option enables support for the Marvell Serial ATA family.
>>>>>>   	  Currently supports 88SX[56]0[48][01] PCI(-X) chips,
>>>>>> diff --git a/drivers/media/platform/exynos4-is/Kconfig b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> index b7b2e47..b6f3eaa 100644
>>>>>> --- a/drivers/media/platform/exynos4-is/Kconfig
>>>>>> +++ b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> @@ -31,7 +31,7 @@ config VIDEO_S5P_FIMC
>>>>>>   config VIDEO_S5P_MIPI_CSIS
>>>>>>   	tristate "S5P/EXYNOS MIPI-CSI2 receiver (MIPI-CSIS) driver"
>>>>>>   	depends on REGULATOR
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This is a V4L2 driver for Samsung S5P and EXYNOS4 SoC MIPI-CSI2
>>>>>>   	  receiver (MIPI-CSIS) devices.
>>>>>> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
>>>>>> index 2962de2..edecdb1 100644
>>>>>> --- a/drivers/phy/Kconfig
>>>>>> +++ b/drivers/phy/Kconfig
>>>>>> @@ -5,7 +5,7 @@
>>>>>>   menu "PHY Subsystem"
>>>>>>
>>>>>>   config GENERIC_PHY
>>>>>> -	bool "PHY Core"
>>>>>> +	bool
>>>>>>   	help
>>>>>>   	  Generic PHY support.
>>>>>>
>>>>>> @@ -72,7 +72,7 @@ config PHY_MIPHY365X
>>>>>>   config PHY_RCAR_GEN2
>>>>>>   	tristate "Renesas R-Car generation 2 USB PHY driver"
>>>>>>   	depends on ARCH_SHMOBILE
>>>>>> -	depends on GENERIC_PHY
>>>>>> +	select GENERIC_PHY
>>>>>
>>>>> so some you changed from depends to select...
>>>>>
>>>>>>   	help
>>>>>>   	  Support for USB PHY found on Renesas R-Car generation 2 SoCs.
>>>>>>
>>>>>> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
>>>>>> index 5ad60e4..e2197e2 100644
>>>>>> --- a/drivers/usb/host/Kconfig
>>>>>> +++ b/drivers/usb/host/Kconfig
>>>>>> @@ -182,7 +182,7 @@ config USB_EHCI_HCD_SPEAR
>>>>>>   config USB_EHCI_HCD_STI
>>>>>>   	tristate "Support for ST STiHxxx on-chip EHCI USB controller"
>>>>>>   	depends on ARCH_STI && OF
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>
>>>>> while others you changed from select to depends.
>>>>>
>>>>> NAK.
>>>>>
>>>> Felipe, I dont understand your concern, could you please explain it more
>>>> detail?  The logic behind the changes is that in cases where there was an
>>>> explicit dependency, I changed it to "depends on" and in other cases I
>>>> changed it to "selects". Thanks
>>>
>>> Since GENERIC_PHY is visible from Kconfig, it would be much nicer to
>>> avoid select altogether.
>>>
>> Felipe, after discussion with the maintainers, I have made GENERIC_PHY an
>> invisible option as part of this change. Thanks
>
> Then, if the option is invisible, how can you "depend" on it ? It can
> never be selected by poking around in Kconfig. IMO, it's
> counterintuitive that you need to enable a PHY driver before you can see
> your EHCI/OHCI/whatever controller listed in Kconfig.

If the controller requires PHY for it to be functional, it is okay to make the 
controller depend on PHY IMHO. We want to try and minimize the usage of 
'select' wherever possible or else 'select' is the most intuitive way. The 
other option is just to leave the 'depends on' and let the user select PHY.

Thanks
Kishon

WARNING: multiple messages have this Message-ID (diff)
From: Kishon Vijay Abraham I <kishon@ti.com>
To: <balbi@ti.com>, Arun Ramamurthy <arun.ramamurthy@broadcom.com>
Cc: Jonathan Corbet <corbet@lwn.net>, Tejun Heo <tj@kernel.org>,
	Kyungmin Park <kyungmin.park@samsung.com>,
	Sylwester Nawrocki <s.nawrocki@samsung.com>,
	Mauro Carvalho Chehab <mchehab@osg.samsung.com>,
	Kukjin Kim <kgene@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Alan Stern <stern@rowland.harvard.edu>,
	Tony Prisk <linux@prisktech.co.nz>,
	Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com>,
	Tomi Valkeinen <tomi.valkeinen@ti.com>,
	Arnd Bergmann <arnd@arndb.de>,
	Mathias Nyman <mathias.nyman@linux.intel.com>,
	Paul Bolle <pebolle@tiscali.nl>,
	Thomas Pugliese <thomas.pugliese@gmail.com>,
	Srinivas Kandagatla <srinivas.kandagatla@linaro.org>,
	Masanari Iida <standby24x7@gmail.com>,
	David Mosberger <davidm@egauge.net>,
	Peter Griffin <peter.griffin@linaro.org>,
	Gregory CLEMENT <gregory.clement@free-electrons.com>,
	Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
	Kevin Hao <haokexin@gmail.com>, Jean Delvare <jdelvare@suse.de>,
	<linux-doc@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<linux-ide@vger.kernel.org>, <linux-media@vger.kernel.org>,
	<linux-arm-kernel@lists.infradead.org>,
	<linux-samsung-soc@vger.kernel.org>, <linux-usb@vger.kernel.org>,
	<linux-fbdev@vger.kernel.org>, Dmitry Torokhov <dtor@google.com>,
	Anatol Pomazau <anatol@google.com>,
	Jonathan Richardson <jonathar@broadcom.com>,
	Scott Branden <sbranden@broadcom.com>,
	Ray Jui <rjui@broadcom.com>,
	<bcm-kernel-feedback-list@broadcom.com>
Subject: Re: [PATCHv3 1/4] phy: phy-core: Make GENERIC_PHY an invisible option
Date: Fri, 29 May 2015 17:04:38 +0530	[thread overview]
Message-ID: <55684ECE.9060003@ti.com> (raw)
In-Reply-To: <20150526183955.GW26599@saruman.tx.rr.com>

Hi Felipe,

On Wednesday 27 May 2015 12:09 AM, Felipe Balbi wrote:
> On Tue, May 26, 2015 at 11:37:17AM -0700, Arun Ramamurthy wrote:
>> Hi
>>
>> On 15-05-26 07:19 AM, Felipe Balbi wrote:
>>> HI,
>>>
>>> On Mon, May 25, 2015 at 02:19:58PM -0700, Arun Ramamurthy wrote:
>>>>
>>>>
>>>> On 15-05-14 05:52 PM, Felipe Balbi wrote:
>>>>> Hi,
>>>>>
>>>>> On Wed, Apr 22, 2015 at 04:04:10PM -0700, Arun Ramamurthy wrote:
>>>>>> Most of the phy providers use "select" to enable GENERIC_PHY. Since select
>>>>>> is only recommended when the config is not visible, GENERIC_PHY is changed
>>>>>> an invisible option. To maintain consistency, all phy providers are changed
>>>>>> to "select" GENERIC_PHY and all non-phy drivers use "depends on" when the
>>>>>> phy framework is explicity required. USB_MUSB_OMAP2PLUS has a cyclic
>>>>>> dependency, so it is left as "select".
>>>>>>
>>>>>> Signed-off-by: Arun Ramamurthy <arun.ramamurthy@broadcom.com>
>>>>>> ---
>>>>>>   drivers/ata/Kconfig                       | 1 -
>>>>>>   drivers/media/platform/exynos4-is/Kconfig | 2 +-
>>>>>>   drivers/phy/Kconfig                       | 4 ++--
>>>>>>   drivers/usb/host/Kconfig                  | 4 ++--
>>>>>>   drivers/video/fbdev/exynos/Kconfig        | 2 +-
>>>>>>   5 files changed, 6 insertions(+), 7 deletions(-)
>>>>>>
>>>>>> diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig
>>>>>> index 5f60155..6d2e881 100644
>>>>>> --- a/drivers/ata/Kconfig
>>>>>> +++ b/drivers/ata/Kconfig
>>>>>> @@ -301,7 +301,6 @@ config SATA_MV
>>>>>>   	tristate "Marvell SATA support"
>>>>>>   	depends on PCI || ARCH_DOVE || ARCH_MV78XX0 || \
>>>>>>   		   ARCH_MVEBU || ARCH_ORION5X || COMPILE_TEST
>>>>>> -	select GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This option enables support for the Marvell Serial ATA family.
>>>>>>   	  Currently supports 88SX[56]0[48][01] PCI(-X) chips,
>>>>>> diff --git a/drivers/media/platform/exynos4-is/Kconfig b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> index b7b2e47..b6f3eaa 100644
>>>>>> --- a/drivers/media/platform/exynos4-is/Kconfig
>>>>>> +++ b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> @@ -31,7 +31,7 @@ config VIDEO_S5P_FIMC
>>>>>>   config VIDEO_S5P_MIPI_CSIS
>>>>>>   	tristate "S5P/EXYNOS MIPI-CSI2 receiver (MIPI-CSIS) driver"
>>>>>>   	depends on REGULATOR
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This is a V4L2 driver for Samsung S5P and EXYNOS4 SoC MIPI-CSI2
>>>>>>   	  receiver (MIPI-CSIS) devices.
>>>>>> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
>>>>>> index 2962de2..edecdb1 100644
>>>>>> --- a/drivers/phy/Kconfig
>>>>>> +++ b/drivers/phy/Kconfig
>>>>>> @@ -5,7 +5,7 @@
>>>>>>   menu "PHY Subsystem"
>>>>>>
>>>>>>   config GENERIC_PHY
>>>>>> -	bool "PHY Core"
>>>>>> +	bool
>>>>>>   	help
>>>>>>   	  Generic PHY support.
>>>>>>
>>>>>> @@ -72,7 +72,7 @@ config PHY_MIPHY365X
>>>>>>   config PHY_RCAR_GEN2
>>>>>>   	tristate "Renesas R-Car generation 2 USB PHY driver"
>>>>>>   	depends on ARCH_SHMOBILE
>>>>>> -	depends on GENERIC_PHY
>>>>>> +	select GENERIC_PHY
>>>>>
>>>>> so some you changed from depends to select...
>>>>>
>>>>>>   	help
>>>>>>   	  Support for USB PHY found on Renesas R-Car generation 2 SoCs.
>>>>>>
>>>>>> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
>>>>>> index 5ad60e4..e2197e2 100644
>>>>>> --- a/drivers/usb/host/Kconfig
>>>>>> +++ b/drivers/usb/host/Kconfig
>>>>>> @@ -182,7 +182,7 @@ config USB_EHCI_HCD_SPEAR
>>>>>>   config USB_EHCI_HCD_STI
>>>>>>   	tristate "Support for ST STiHxxx on-chip EHCI USB controller"
>>>>>>   	depends on ARCH_STI && OF
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>
>>>>> while others you changed from select to depends.
>>>>>
>>>>> NAK.
>>>>>
>>>> Felipe, I dont understand your concern, could you please explain it more
>>>> detail?  The logic behind the changes is that in cases where there was an
>>>> explicit dependency, I changed it to "depends on" and in other cases I
>>>> changed it to "selects". Thanks
>>>
>>> Since GENERIC_PHY is visible from Kconfig, it would be much nicer to
>>> avoid select altogether.
>>>
>> Felipe, after discussion with the maintainers, I have made GENERIC_PHY an
>> invisible option as part of this change. Thanks
>
> Then, if the option is invisible, how can you "depend" on it ? It can
> never be selected by poking around in Kconfig. IMO, it's
> counterintuitive that you need to enable a PHY driver before you can see
> your EHCI/OHCI/whatever controller listed in Kconfig.

If the controller requires PHY for it to be functional, it is okay to make the 
controller depend on PHY IMHO. We want to try and minimize the usage of 
'select' wherever possible or else 'select' is the most intuitive way. The 
other option is just to leave the 'depends on' and let the user select PHY.

Thanks
Kishon

WARNING: multiple messages have this Message-ID (diff)
From: Kishon Vijay Abraham I <kishon@ti.com>
To: linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCHv3 1/4] phy: phy-core: Make GENERIC_PHY an invisible option
Date: Fri, 29 May 2015 11:46:38 +0000	[thread overview]
Message-ID: <55684ECE.9060003@ti.com> (raw)
In-Reply-To: <20150526183955.GW26599@saruman.tx.rr.com>

Hi Felipe,

On Wednesday 27 May 2015 12:09 AM, Felipe Balbi wrote:
> On Tue, May 26, 2015 at 11:37:17AM -0700, Arun Ramamurthy wrote:
>> Hi
>>
>> On 15-05-26 07:19 AM, Felipe Balbi wrote:
>>> HI,
>>>
>>> On Mon, May 25, 2015 at 02:19:58PM -0700, Arun Ramamurthy wrote:
>>>>
>>>>
>>>> On 15-05-14 05:52 PM, Felipe Balbi wrote:
>>>>> Hi,
>>>>>
>>>>> On Wed, Apr 22, 2015 at 04:04:10PM -0700, Arun Ramamurthy wrote:
>>>>>> Most of the phy providers use "select" to enable GENERIC_PHY. Since select
>>>>>> is only recommended when the config is not visible, GENERIC_PHY is changed
>>>>>> an invisible option. To maintain consistency, all phy providers are changed
>>>>>> to "select" GENERIC_PHY and all non-phy drivers use "depends on" when the
>>>>>> phy framework is explicity required. USB_MUSB_OMAP2PLUS has a cyclic
>>>>>> dependency, so it is left as "select".
>>>>>>
>>>>>> Signed-off-by: Arun Ramamurthy <arun.ramamurthy@broadcom.com>
>>>>>> ---
>>>>>>   drivers/ata/Kconfig                       | 1 -
>>>>>>   drivers/media/platform/exynos4-is/Kconfig | 2 +-
>>>>>>   drivers/phy/Kconfig                       | 4 ++--
>>>>>>   drivers/usb/host/Kconfig                  | 4 ++--
>>>>>>   drivers/video/fbdev/exynos/Kconfig        | 2 +-
>>>>>>   5 files changed, 6 insertions(+), 7 deletions(-)
>>>>>>
>>>>>> diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig
>>>>>> index 5f60155..6d2e881 100644
>>>>>> --- a/drivers/ata/Kconfig
>>>>>> +++ b/drivers/ata/Kconfig
>>>>>> @@ -301,7 +301,6 @@ config SATA_MV
>>>>>>   	tristate "Marvell SATA support"
>>>>>>   	depends on PCI || ARCH_DOVE || ARCH_MV78XX0 || \
>>>>>>   		   ARCH_MVEBU || ARCH_ORION5X || COMPILE_TEST
>>>>>> -	select GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This option enables support for the Marvell Serial ATA family.
>>>>>>   	  Currently supports 88SX[56]0[48][01] PCI(-X) chips,
>>>>>> diff --git a/drivers/media/platform/exynos4-is/Kconfig b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> index b7b2e47..b6f3eaa 100644
>>>>>> --- a/drivers/media/platform/exynos4-is/Kconfig
>>>>>> +++ b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> @@ -31,7 +31,7 @@ config VIDEO_S5P_FIMC
>>>>>>   config VIDEO_S5P_MIPI_CSIS
>>>>>>   	tristate "S5P/EXYNOS MIPI-CSI2 receiver (MIPI-CSIS) driver"
>>>>>>   	depends on REGULATOR
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This is a V4L2 driver for Samsung S5P and EXYNOS4 SoC MIPI-CSI2
>>>>>>   	  receiver (MIPI-CSIS) devices.
>>>>>> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
>>>>>> index 2962de2..edecdb1 100644
>>>>>> --- a/drivers/phy/Kconfig
>>>>>> +++ b/drivers/phy/Kconfig
>>>>>> @@ -5,7 +5,7 @@
>>>>>>   menu "PHY Subsystem"
>>>>>>
>>>>>>   config GENERIC_PHY
>>>>>> -	bool "PHY Core"
>>>>>> +	bool
>>>>>>   	help
>>>>>>   	  Generic PHY support.
>>>>>>
>>>>>> @@ -72,7 +72,7 @@ config PHY_MIPHY365X
>>>>>>   config PHY_RCAR_GEN2
>>>>>>   	tristate "Renesas R-Car generation 2 USB PHY driver"
>>>>>>   	depends on ARCH_SHMOBILE
>>>>>> -	depends on GENERIC_PHY
>>>>>> +	select GENERIC_PHY
>>>>>
>>>>> so some you changed from depends to select...
>>>>>
>>>>>>   	help
>>>>>>   	  Support for USB PHY found on Renesas R-Car generation 2 SoCs.
>>>>>>
>>>>>> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
>>>>>> index 5ad60e4..e2197e2 100644
>>>>>> --- a/drivers/usb/host/Kconfig
>>>>>> +++ b/drivers/usb/host/Kconfig
>>>>>> @@ -182,7 +182,7 @@ config USB_EHCI_HCD_SPEAR
>>>>>>   config USB_EHCI_HCD_STI
>>>>>>   	tristate "Support for ST STiHxxx on-chip EHCI USB controller"
>>>>>>   	depends on ARCH_STI && OF
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>
>>>>> while others you changed from select to depends.
>>>>>
>>>>> NAK.
>>>>>
>>>> Felipe, I dont understand your concern, could you please explain it more
>>>> detail?  The logic behind the changes is that in cases where there was an
>>>> explicit dependency, I changed it to "depends on" and in other cases I
>>>> changed it to "selects". Thanks
>>>
>>> Since GENERIC_PHY is visible from Kconfig, it would be much nicer to
>>> avoid select altogether.
>>>
>> Felipe, after discussion with the maintainers, I have made GENERIC_PHY an
>> invisible option as part of this change. Thanks
>
> Then, if the option is invisible, how can you "depend" on it ? It can
> never be selected by poking around in Kconfig. IMO, it's
> counterintuitive that you need to enable a PHY driver before you can see
> your EHCI/OHCI/whatever controller listed in Kconfig.

If the controller requires PHY for it to be functional, it is okay to make the 
controller depend on PHY IMHO. We want to try and minimize the usage of 
'select' wherever possible or else 'select' is the most intuitive way. The 
other option is just to leave the 'depends on' and let the user select PHY.

Thanks
Kishon

WARNING: multiple messages have this Message-ID (diff)
From: kishon@ti.com (Kishon Vijay Abraham I)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv3 1/4] phy: phy-core: Make GENERIC_PHY an invisible option
Date: Fri, 29 May 2015 17:04:38 +0530	[thread overview]
Message-ID: <55684ECE.9060003@ti.com> (raw)
In-Reply-To: <20150526183955.GW26599@saruman.tx.rr.com>

Hi Felipe,

On Wednesday 27 May 2015 12:09 AM, Felipe Balbi wrote:
> On Tue, May 26, 2015 at 11:37:17AM -0700, Arun Ramamurthy wrote:
>> Hi
>>
>> On 15-05-26 07:19 AM, Felipe Balbi wrote:
>>> HI,
>>>
>>> On Mon, May 25, 2015 at 02:19:58PM -0700, Arun Ramamurthy wrote:
>>>>
>>>>
>>>> On 15-05-14 05:52 PM, Felipe Balbi wrote:
>>>>> Hi,
>>>>>
>>>>> On Wed, Apr 22, 2015 at 04:04:10PM -0700, Arun Ramamurthy wrote:
>>>>>> Most of the phy providers use "select" to enable GENERIC_PHY. Since select
>>>>>> is only recommended when the config is not visible, GENERIC_PHY is changed
>>>>>> an invisible option. To maintain consistency, all phy providers are changed
>>>>>> to "select" GENERIC_PHY and all non-phy drivers use "depends on" when the
>>>>>> phy framework is explicity required. USB_MUSB_OMAP2PLUS has a cyclic
>>>>>> dependency, so it is left as "select".
>>>>>>
>>>>>> Signed-off-by: Arun Ramamurthy <arun.ramamurthy@broadcom.com>
>>>>>> ---
>>>>>>   drivers/ata/Kconfig                       | 1 -
>>>>>>   drivers/media/platform/exynos4-is/Kconfig | 2 +-
>>>>>>   drivers/phy/Kconfig                       | 4 ++--
>>>>>>   drivers/usb/host/Kconfig                  | 4 ++--
>>>>>>   drivers/video/fbdev/exynos/Kconfig        | 2 +-
>>>>>>   5 files changed, 6 insertions(+), 7 deletions(-)
>>>>>>
>>>>>> diff --git a/drivers/ata/Kconfig b/drivers/ata/Kconfig
>>>>>> index 5f60155..6d2e881 100644
>>>>>> --- a/drivers/ata/Kconfig
>>>>>> +++ b/drivers/ata/Kconfig
>>>>>> @@ -301,7 +301,6 @@ config SATA_MV
>>>>>>   	tristate "Marvell SATA support"
>>>>>>   	depends on PCI || ARCH_DOVE || ARCH_MV78XX0 || \
>>>>>>   		   ARCH_MVEBU || ARCH_ORION5X || COMPILE_TEST
>>>>>> -	select GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This option enables support for the Marvell Serial ATA family.
>>>>>>   	  Currently supports 88SX[56]0[48][01] PCI(-X) chips,
>>>>>> diff --git a/drivers/media/platform/exynos4-is/Kconfig b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> index b7b2e47..b6f3eaa 100644
>>>>>> --- a/drivers/media/platform/exynos4-is/Kconfig
>>>>>> +++ b/drivers/media/platform/exynos4-is/Kconfig
>>>>>> @@ -31,7 +31,7 @@ config VIDEO_S5P_FIMC
>>>>>>   config VIDEO_S5P_MIPI_CSIS
>>>>>>   	tristate "S5P/EXYNOS MIPI-CSI2 receiver (MIPI-CSIS) driver"
>>>>>>   	depends on REGULATOR
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>>   	help
>>>>>>   	  This is a V4L2 driver for Samsung S5P and EXYNOS4 SoC MIPI-CSI2
>>>>>>   	  receiver (MIPI-CSIS) devices.
>>>>>> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
>>>>>> index 2962de2..edecdb1 100644
>>>>>> --- a/drivers/phy/Kconfig
>>>>>> +++ b/drivers/phy/Kconfig
>>>>>> @@ -5,7 +5,7 @@
>>>>>>   menu "PHY Subsystem"
>>>>>>
>>>>>>   config GENERIC_PHY
>>>>>> -	bool "PHY Core"
>>>>>> +	bool
>>>>>>   	help
>>>>>>   	  Generic PHY support.
>>>>>>
>>>>>> @@ -72,7 +72,7 @@ config PHY_MIPHY365X
>>>>>>   config PHY_RCAR_GEN2
>>>>>>   	tristate "Renesas R-Car generation 2 USB PHY driver"
>>>>>>   	depends on ARCH_SHMOBILE
>>>>>> -	depends on GENERIC_PHY
>>>>>> +	select GENERIC_PHY
>>>>>
>>>>> so some you changed from depends to select...
>>>>>
>>>>>>   	help
>>>>>>   	  Support for USB PHY found on Renesas R-Car generation 2 SoCs.
>>>>>>
>>>>>> diff --git a/drivers/usb/host/Kconfig b/drivers/usb/host/Kconfig
>>>>>> index 5ad60e4..e2197e2 100644
>>>>>> --- a/drivers/usb/host/Kconfig
>>>>>> +++ b/drivers/usb/host/Kconfig
>>>>>> @@ -182,7 +182,7 @@ config USB_EHCI_HCD_SPEAR
>>>>>>   config USB_EHCI_HCD_STI
>>>>>>   	tristate "Support for ST STiHxxx on-chip EHCI USB controller"
>>>>>>   	depends on ARCH_STI && OF
>>>>>> -	select GENERIC_PHY
>>>>>> +	depends on GENERIC_PHY
>>>>>
>>>>> while others you changed from select to depends.
>>>>>
>>>>> NAK.
>>>>>
>>>> Felipe, I dont understand your concern, could you please explain it more
>>>> detail?  The logic behind the changes is that in cases where there was an
>>>> explicit dependency, I changed it to "depends on" and in other cases I
>>>> changed it to "selects". Thanks
>>>
>>> Since GENERIC_PHY is visible from Kconfig, it would be much nicer to
>>> avoid select altogether.
>>>
>> Felipe, after discussion with the maintainers, I have made GENERIC_PHY an
>> invisible option as part of this change. Thanks
>
> Then, if the option is invisible, how can you "depend" on it ? It can
> never be selected by poking around in Kconfig. IMO, it's
> counterintuitive that you need to enable a PHY driver before you can see
> your EHCI/OHCI/whatever controller listed in Kconfig.

If the controller requires PHY for it to be functional, it is okay to make the 
controller depend on PHY IMHO. We want to try and minimize the usage of 
'select' wherever possible or else 'select' is the most intuitive way. The 
other option is just to leave the 'depends on' and let the user select PHY.

Thanks
Kishon

  reply	other threads:[~2015-05-29 11:34 UTC|newest]

Thread overview: 92+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-22 23:04 [PATCHv3 0/4] add devm_of_phy_get_by_index and update platform drivers Arun Ramamurthy
2015-04-22 23:04 ` Arun Ramamurthy
2015-04-22 23:04 ` Arun Ramamurthy
2015-04-22 23:04 ` Arun Ramamurthy
2015-04-22 23:04 ` [PATCHv3 1/4] phy: phy-core: Make GENERIC_PHY an invisible option Arun Ramamurthy
2015-04-22 23:04   ` Arun Ramamurthy
2015-04-22 23:04   ` Arun Ramamurthy
2015-04-22 23:04   ` Arun Ramamurthy
2015-05-14 21:57   ` Mauro Carvalho Chehab
2015-05-14 21:57     ` Mauro Carvalho Chehab
2015-05-14 21:57     ` Mauro Carvalho Chehab
2015-05-14 21:57     ` Mauro Carvalho Chehab
2015-05-15  0:52   ` Felipe Balbi
2015-05-15  0:52     ` Felipe Balbi
2015-05-15  0:52     ` Felipe Balbi
2015-05-15  0:52     ` Felipe Balbi
2015-05-25 21:19     ` Arun Ramamurthy
2015-05-25 21:19       ` Arun Ramamurthy
2015-05-25 21:19       ` Arun Ramamurthy
2015-05-25 21:19       ` Arun Ramamurthy
2015-05-26 14:19       ` Felipe Balbi
2015-05-26 14:19         ` Felipe Balbi
2015-05-26 14:19         ` Felipe Balbi
2015-05-26 14:19         ` Felipe Balbi
2015-05-26 18:37         ` Arun Ramamurthy
2015-05-26 18:37           ` Arun Ramamurthy
2015-05-26 18:37           ` Arun Ramamurthy
2015-05-26 18:37           ` Arun Ramamurthy
2015-05-26 18:39           ` Felipe Balbi
2015-05-26 18:39             ` Felipe Balbi
2015-05-26 18:39             ` Felipe Balbi
2015-05-26 18:39             ` Felipe Balbi
2015-05-29 11:34             ` Kishon Vijay Abraham I [this message]
2015-05-29 11:46               ` Kishon Vijay Abraham I
2015-05-29 11:34               ` Kishon Vijay Abraham I
2015-05-29 11:34               ` Kishon Vijay Abraham I
2015-05-29 15:04               ` Felipe Balbi
2015-05-29 15:04                 ` Felipe Balbi
2015-05-29 15:04                 ` Felipe Balbi
2015-05-29 15:04                 ` Felipe Balbi
2015-06-01 12:52                 ` Kishon Vijay Abraham I
2015-06-01 12:54                   ` Kishon Vijay Abraham I
2015-06-01 12:52                   ` Kishon Vijay Abraham I
2015-06-01 12:52                   ` Kishon Vijay Abraham I
2015-06-01 18:39                   ` Felipe Balbi
2015-06-01 18:39                     ` Felipe Balbi
2015-06-01 18:39                     ` Felipe Balbi
2015-06-01 18:39                     ` Felipe Balbi
2015-05-29 12:37   ` Kishon Vijay Abraham I
2015-05-29 12:49     ` Kishon Vijay Abraham I
2015-05-29 12:37     ` Kishon Vijay Abraham I
2015-05-29 12:37     ` Kishon Vijay Abraham I
2015-05-29 12:59     ` Maxime Coquelin
2015-05-29 12:59       ` Maxime Coquelin
2015-05-29 12:59       ` Maxime Coquelin
2015-05-29 12:59       ` Maxime Coquelin
     [not found]     ` <55685D7E.9000700-l0cyMroinI0@public.gmane.org>
2015-05-29 13:09       ` Tejun Heo
2015-05-29 13:09         ` Tejun Heo
2015-05-29 13:09         ` Tejun Heo
2015-05-29 13:09         ` Tejun Heo
2015-05-29 13:13     ` Sylwester Nawrocki
2015-05-29 13:13       ` Sylwester Nawrocki
2015-05-29 13:13       ` Sylwester Nawrocki
2015-05-29 13:13       ` Sylwester Nawrocki
2015-04-22 23:04 ` [PATCHv3 4/4] usb: ohci-platform: Use devm_of_phy_get_by_index Arun Ramamurthy
2015-04-22 23:04   ` Arun Ramamurthy
2015-04-22 23:04   ` Arun Ramamurthy
2015-04-22 23:04   ` Arun Ramamurthy
2015-04-23  7:42 ` [PATCHv3 0/4] add devm_of_phy_get_by_index and update platform drivers Hans de Goede
2015-04-23  7:42   ` Hans de Goede
2015-04-23  7:42   ` Hans de Goede
2015-04-23  7:42   ` Hans de Goede
     [not found] ` <1429743853-10254-1-git-send-email-arun.ramamurthy-dY08KVG/lbpWk0Htik3J/w@public.gmane.org>
2015-04-22 23:04   ` [PATCHv3 2/4] phy: core: Add devm_of_phy_get_by_index to phy-core Arun Ramamurthy
2015-04-22 23:04     ` Arun Ramamurthy
2015-04-22 23:04     ` Arun Ramamurthy
2015-04-22 23:04     ` Arun Ramamurthy
2015-05-11 15:09     ` Kishon Vijay Abraham I
2015-05-11 15:21       ` Kishon Vijay Abraham I
2015-05-11 15:09       ` Kishon Vijay Abraham I
2015-05-11 15:09       ` Kishon Vijay Abraham I
2015-04-22 23:04   ` [PATCHv3 3/4] usb: ehci-platform: Use devm_of_phy_get_by_index Arun Ramamurthy
2015-04-22 23:04     ` Arun Ramamurthy
2015-04-22 23:04     ` Arun Ramamurthy
2015-04-22 23:04     ` Arun Ramamurthy
2015-04-23 14:31   ` [PATCHv3 0/4] add devm_of_phy_get_by_index and update platform drivers Alan Stern
2015-04-23 14:31     ` Alan Stern
2015-04-23 14:31     ` Alan Stern
2015-04-23 14:31     ` Alan Stern
2015-05-11 13:44     ` Kishon Vijay Abraham I
2015-05-11 13:56       ` Kishon Vijay Abraham I
2015-05-11 13:44       ` Kishon Vijay Abraham I
2015-05-11 13:44       ` Kishon Vijay Abraham I

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55684ECE.9060003@ti.com \
    --to=kishon@ti.com \
    --cc=arnd@arndb.de \
    --cc=arun.ramamurthy@broadcom.com \
    --cc=balbi@ti.com \
    --cc=corbet@lwn.net \
    --cc=davidm@egauge.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=gregory.clement@free-electrons.com \
    --cc=kgene@kernel.org \
    --cc=kyungmin.park@samsung.com \
    --cc=laurent.pinchart@ideasonb \
    --cc=linux@prisktech.co.nz \
    --cc=mathias.nyman@linux.intel.com \
    --cc=mchehab@osg.samsung.com \
    --cc=pebolle@tiscali.nl \
    --cc=peter.griffin@linaro.org \
    --cc=plagnioj@jcrosoft.com \
    --cc=s.nawrocki@samsung.com \
    --cc=srinivas.kandagatla@linaro.org \
    --cc=standby24x7@gmail.com \
    --cc=stern@rowland.harvard.edu \
    --cc=thomas.pugliese@gmail.com \
    --cc=tj@kernel.org \
    --cc=tomi.valkeinen@ti.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.