2014-07-09 11:54:09

by Sachin Kamat

[permalink] [raw]
Subject: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs

Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
USB gadget controller supported by the DWC2 gadget driver, make it
depend on them and default to ARCH_EXYNOS as they are meant for
Exynos platforms. Also, make the sub-drivers silent options enabling
them based on the SoC platforms that they are meant to work with. This
will make life easier for end users who do not have any way knowing the
dependencies.

Signed-off-by: Sachin Kamat <[email protected]>
---
Changes since v1:
* Added dependency on DWC2 gadget driver as suggested by Tomasz Figa.
---
drivers/phy/Kconfig | 35 +++++++++++------------------------
1 file changed, 11 insertions(+), 24 deletions(-)

diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
index fcdfe7c0e4a7..128f8b92b55c 100644
--- a/drivers/phy/Kconfig
+++ b/drivers/phy/Kconfig
@@ -123,43 +123,30 @@ config PHY_SUN4I_USB
config PHY_SAMSUNG_USB2
tristate "Samsung USB 2.0 PHY driver"
depends on HAS_IOMEM
+ depends on USB_EHCI_EXYNOS || USB_OHCI_EXYNOS || USB_DWC2
select GENERIC_PHY
select MFD_SYSCON
+ default ARCH_EXYNOS
help
Enable this to support the Samsung USB 2.0 PHY driver for Samsung
- SoCs. This driver provides the interface for USB 2.0 PHY. Support for
- particular SoCs has to be enabled in addition to this driver. Number
- and type of supported phys depends on the SoC.
+ SoCs. This driver provides the interface for USB 2.0 PHY. Support
+ for particular PHYs will be enabled based on the SoC type in addition
+ to this driver.

config PHY_EXYNOS4210_USB2
- bool "Support for Exynos 4210"
+ bool
depends on PHY_SAMSUNG_USB2
- depends on CPU_EXYNOS4210
- help
- Enable USB PHY support for Exynos 4210. This option requires that
- Samsung USB 2.0 PHY driver is enabled and means that support for this
- particular SoC is compiled in the driver. In case of Exynos 4210 four
- phys are available - device, host, HSIC0 and HSIC1.
+ default CPU_EXYNOS4210

config PHY_EXYNOS4X12_USB2
- bool "Support for Exynos 4x12"
+ bool
depends on PHY_SAMSUNG_USB2
- depends on (SOC_EXYNOS4212 || SOC_EXYNOS4412)
- help
- Enable USB PHY support for Exynos 4x12. This option requires that
- Samsung USB 2.0 PHY driver is enabled and means that support for this
- particular SoC is compiled in the driver. In case of Exynos 4x12 four
- phys are available - device, host, HSIC0 and HSIC1.
+ default SOC_EXYNOS4212 || SOC_EXYNOS4412

config PHY_EXYNOS5250_USB2
- bool "Support for Exynos 5250"
+ bool
depends on PHY_SAMSUNG_USB2
- depends on SOC_EXYNOS5250
- help
- Enable USB PHY support for Exynos 5250. This option requires that
- Samsung USB 2.0 PHY driver is enabled and means that support for this
- particular SoC is compiled in the driver. In case of Exynos 5250 four
- phys are available - device, host, HSIC0 and HSIC.
+ default SOC_EXYNOS5250 || SOC_EXYNOS5420

config PHY_EXYNOS5_USBDRD
tristate "Exynos5 SoC series USB DRD PHY driver"
--
1.7.9.5


2014-07-09 11:53:33

by Sachin Kamat

[permalink] [raw]
Subject: [PATCH v2 2/2] phy: Kconfig: Update config for Exynos USB DRD

USB DWC3 driver on Exynos platform does not work without its
corresponding phy driver. Hence make the PHY driver depend on
Exynos DWC3 driver and default it to yes to make things easier
for the end user.

Signed-off-by: Sachin Kamat <[email protected]>
---
No changes since v1.
---
drivers/phy/Kconfig | 2 ++
1 file changed, 2 insertions(+)

diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
index 128f8b92b55c..ee6c80a5392a 100644
--- a/drivers/phy/Kconfig
+++ b/drivers/phy/Kconfig
@@ -152,8 +152,10 @@ config PHY_EXYNOS5_USBDRD
tristate "Exynos5 SoC series USB DRD PHY driver"
depends on ARCH_EXYNOS5 && OF
depends on HAS_IOMEM
+ depends on USB_DWC3_EXYNOS
select GENERIC_PHY
select MFD_SYSCON
+ default y
help
Enable USB DRD PHY support for Exynos 5 SoC series.
This driver provides PHY interface for USB 3.0 DRD controller
--
1.7.9.5

2014-07-10 06:50:21

by Jingoo Han

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs

On Wednesday, July 09, 2014 8:49 PM, Sachin Kamat wrote:
>
> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
> USB gadget controller supported by the DWC2 gadget driver, make it
> depend on them and default to ARCH_EXYNOS as they are meant for
> Exynos platforms. Also, make the sub-drivers silent options enabling
> them based on the SoC platforms that they are meant to work with. This
> will make life easier for end users who do not have any way knowing the
> dependencies.
>
> Signed-off-by: Sachin Kamat <[email protected]>

Reviewed-by: Jingoo Han <[email protected]>

Best regards,
Jingoo Han

> ---
> Changes since v1:
> * Added dependency on DWC2 gadget driver as suggested by Tomasz Figa.
> ---
> drivers/phy/Kconfig | 35 +++++++++++------------------------
> 1 file changed, 11 insertions(+), 24 deletions(-)
>
> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
> index fcdfe7c0e4a7..128f8b92b55c 100644
> --- a/drivers/phy/Kconfig
> +++ b/drivers/phy/Kconfig
> @@ -123,43 +123,30 @@ config PHY_SUN4I_USB
> config PHY_SAMSUNG_USB2
> tristate "Samsung USB 2.0 PHY driver"
> depends on HAS_IOMEM
> + depends on USB_EHCI_EXYNOS || USB_OHCI_EXYNOS || USB_DWC2
> select GENERIC_PHY
> select MFD_SYSCON
> + default ARCH_EXYNOS
> help
> Enable this to support the Samsung USB 2.0 PHY driver for Samsung
> - SoCs. This driver provides the interface for USB 2.0 PHY. Support for
> - particular SoCs has to be enabled in addition to this driver. Number
> - and type of supported phys depends on the SoC.
> + SoCs. This driver provides the interface for USB 2.0 PHY. Support
> + for particular PHYs will be enabled based on the SoC type in addition
> + to this driver.
>
> config PHY_EXYNOS4210_USB2
> - bool "Support for Exynos 4210"
> + bool
> depends on PHY_SAMSUNG_USB2
> - depends on CPU_EXYNOS4210
> - help
> - Enable USB PHY support for Exynos 4210. This option requires that
> - Samsung USB 2.0 PHY driver is enabled and means that support for this
> - particular SoC is compiled in the driver. In case of Exynos 4210 four
> - phys are available - device, host, HSIC0 and HSIC1.
> + default CPU_EXYNOS4210
>
> config PHY_EXYNOS4X12_USB2
> - bool "Support for Exynos 4x12"
> + bool
> depends on PHY_SAMSUNG_USB2
> - depends on (SOC_EXYNOS4212 || SOC_EXYNOS4412)
> - help
> - Enable USB PHY support for Exynos 4x12. This option requires that
> - Samsung USB 2.0 PHY driver is enabled and means that support for this
> - particular SoC is compiled in the driver. In case of Exynos 4x12 four
> - phys are available - device, host, HSIC0 and HSIC1.
> + default SOC_EXYNOS4212 || SOC_EXYNOS4412
>
> config PHY_EXYNOS5250_USB2
> - bool "Support for Exynos 5250"
> + bool
> depends on PHY_SAMSUNG_USB2
> - depends on SOC_EXYNOS5250
> - help
> - Enable USB PHY support for Exynos 5250. This option requires that
> - Samsung USB 2.0 PHY driver is enabled and means that support for this
> - particular SoC is compiled in the driver. In case of Exynos 5250 four
> - phys are available - device, host, HSIC0 and HSIC.
> + default SOC_EXYNOS5250 || SOC_EXYNOS5420
>
> config PHY_EXYNOS5_USBDRD
> tristate "Exynos5 SoC series USB DRD PHY driver"
> --
> 1.7.9.5

2014-07-10 06:52:00

by Jingoo Han

[permalink] [raw]
Subject: Re: [PATCH v2 2/2] phy: Kconfig: Update config for Exynos USB DRD

On Wednesday, July 09, 2014 8:49 PM, Sachin Kamat wrote:
>
> USB DWC3 driver on Exynos platform does not work without its
> corresponding phy driver. Hence make the PHY driver depend on
> Exynos DWC3 driver and default it to yes to make things easier
> for the end user.
>
> Signed-off-by: Sachin Kamat <[email protected]>

Reviewed-by: Jingoo Han <[email protected]>

Best regards,
Jingoo Han

> ---
> No changes since v1.
> ---
> drivers/phy/Kconfig | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
> index 128f8b92b55c..ee6c80a5392a 100644
> --- a/drivers/phy/Kconfig
> +++ b/drivers/phy/Kconfig
> @@ -152,8 +152,10 @@ config PHY_EXYNOS5_USBDRD
> tristate "Exynos5 SoC series USB DRD PHY driver"
> depends on ARCH_EXYNOS5 && OF
> depends on HAS_IOMEM
> + depends on USB_DWC3_EXYNOS
> select GENERIC_PHY
> select MFD_SYSCON
> + default y
> help
> Enable USB DRD PHY support for Exynos 5 SoC series.
> This driver provides PHY interface for USB 3.0 DRD controller
> --
> 1.7.9.5

2014-07-14 08:56:49

by Kishon Vijay Abraham I

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs

Hi,

On Wednesday 09 July 2014 05:19 PM, Sachin Kamat wrote:
> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
> USB gadget controller supported by the DWC2 gadget driver, make it
> depend on them and default to ARCH_EXYNOS as they are meant for
> Exynos platforms. Also, make the sub-drivers silent options enabling
> them based on the SoC platforms that they are meant to work with. This
> will make life easier for end users who do not have any way knowing the
> dependencies.

There is a new Exynos PHY in town, Exynos 3250. Can you rebase your patch on
top of that?

Thanks
Kishon
>
> Signed-off-by: Sachin Kamat <[email protected]>
> ---
> Changes since v1:
> * Added dependency on DWC2 gadget driver as suggested by Tomasz Figa.
> ---
> drivers/phy/Kconfig | 35 +++++++++++------------------------
> 1 file changed, 11 insertions(+), 24 deletions(-)
>
> diff --git a/drivers/phy/Kconfig b/drivers/phy/Kconfig
> index fcdfe7c0e4a7..128f8b92b55c 100644
> --- a/drivers/phy/Kconfig
> +++ b/drivers/phy/Kconfig
> @@ -123,43 +123,30 @@ config PHY_SUN4I_USB
> config PHY_SAMSUNG_USB2
> tristate "Samsung USB 2.0 PHY driver"
> depends on HAS_IOMEM
> + depends on USB_EHCI_EXYNOS || USB_OHCI_EXYNOS || USB_DWC2
> select GENERIC_PHY
> select MFD_SYSCON
> + default ARCH_EXYNOS
> help
> Enable this to support the Samsung USB 2.0 PHY driver for Samsung
> - SoCs. This driver provides the interface for USB 2.0 PHY. Support for
> - particular SoCs has to be enabled in addition to this driver. Number
> - and type of supported phys depends on the SoC.
> + SoCs. This driver provides the interface for USB 2.0 PHY. Support
> + for particular PHYs will be enabled based on the SoC type in addition
> + to this driver.
>
> config PHY_EXYNOS4210_USB2
> - bool "Support for Exynos 4210"
> + bool
> depends on PHY_SAMSUNG_USB2
> - depends on CPU_EXYNOS4210
> - help
> - Enable USB PHY support for Exynos 4210. This option requires that
> - Samsung USB 2.0 PHY driver is enabled and means that support for this
> - particular SoC is compiled in the driver. In case of Exynos 4210 four
> - phys are available - device, host, HSIC0 and HSIC1.
> + default CPU_EXYNOS4210
>
> config PHY_EXYNOS4X12_USB2
> - bool "Support for Exynos 4x12"
> + bool
> depends on PHY_SAMSUNG_USB2
> - depends on (SOC_EXYNOS4212 || SOC_EXYNOS4412)
> - help
> - Enable USB PHY support for Exynos 4x12. This option requires that
> - Samsung USB 2.0 PHY driver is enabled and means that support for this
> - particular SoC is compiled in the driver. In case of Exynos 4x12 four
> - phys are available - device, host, HSIC0 and HSIC1.
> + default SOC_EXYNOS4212 || SOC_EXYNOS4412
>
> config PHY_EXYNOS5250_USB2
> - bool "Support for Exynos 5250"
> + bool
> depends on PHY_SAMSUNG_USB2
> - depends on SOC_EXYNOS5250
> - help
> - Enable USB PHY support for Exynos 5250. This option requires that
> - Samsung USB 2.0 PHY driver is enabled and means that support for this
> - particular SoC is compiled in the driver. In case of Exynos 5250 four
> - phys are available - device, host, HSIC0 and HSIC.
> + default SOC_EXYNOS5250 || SOC_EXYNOS5420
>
> config PHY_EXYNOS5_USBDRD
> tristate "Exynos5 SoC series USB DRD PHY driver"
>

2014-07-14 08:59:39

by Sachin Kamat

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs

Hi,

On Mon, Jul 14, 2014 at 2:26 PM, Kishon Vijay Abraham I <[email protected]> wrote:
> Hi,
>
> On Wednesday 09 July 2014 05:19 PM, Sachin Kamat wrote:
>> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
>> USB gadget controller supported by the DWC2 gadget driver, make it
>> depend on them and default to ARCH_EXYNOS as they are meant for
>> Exynos platforms. Also, make the sub-drivers silent options enabling
>> them based on the SoC platforms that they are meant to work with. This
>> will make life easier for end users who do not have any way knowing the
>> dependencies.
>
> There is a new Exynos PHY in town, Exynos 3250. Can you rebase your patch on
> top of that?

Sure. But I did not see it in linux-next yet. Is it merged somewhere?

--
Regards,
Sachin.

2014-07-14 09:02:35

by Kishon Vijay Abraham I

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs



On Monday 14 July 2014 02:29 PM, Sachin Kamat wrote:
> Hi,
>
> On Mon, Jul 14, 2014 at 2:26 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>> Hi,
>>
>> On Wednesday 09 July 2014 05:19 PM, Sachin Kamat wrote:
>>> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
>>> USB gadget controller supported by the DWC2 gadget driver, make it
>>> depend on them and default to ARCH_EXYNOS as they are meant for
>>> Exynos platforms. Also, make the sub-drivers silent options enabling
>>> them based on the SoC platforms that they are meant to work with. This
>>> will make life easier for end users who do not have any way knowing the
>>> dependencies.
>>
>> There is a new Exynos PHY in town, Exynos 3250. Can you rebase your patch on
>> top of that?
>
> Sure. But I did not see it in linux-next yet. Is it merged somewhere?

It's in the list. I can push it to my tree if that helps.

-Kishon
>

2014-07-14 09:06:31

by Sachin Kamat

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs

On Mon, Jul 14, 2014 at 2:32 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>
>
> On Monday 14 July 2014 02:29 PM, Sachin Kamat wrote:
>> Hi,
>>
>> On Mon, Jul 14, 2014 at 2:26 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>>> Hi,
>>>
>>> On Wednesday 09 July 2014 05:19 PM, Sachin Kamat wrote:
>>>> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
>>>> USB gadget controller supported by the DWC2 gadget driver, make it
>>>> depend on them and default to ARCH_EXYNOS as they are meant for
>>>> Exynos platforms. Also, make the sub-drivers silent options enabling
>>>> them based on the SoC platforms that they are meant to work with. This
>>>> will make life easier for end users who do not have any way knowing the
>>>> dependencies.
>>>
>>> There is a new Exynos PHY in town, Exynos 3250. Can you rebase your patch on
>>> top of that?
>>
>> Sure. But I did not see it in linux-next yet. Is it merged somewhere?
>
> It's in the list. I can push it to my tree if that helps.

That would be great to avoid any other conflicts.

--
Regards,
Sachin.

2014-07-14 09:10:16

by Kishon Vijay Abraham I

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs



On Monday 14 July 2014 02:36 PM, Sachin Kamat wrote:
> On Mon, Jul 14, 2014 at 2:32 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>>
>>
>> On Monday 14 July 2014 02:29 PM, Sachin Kamat wrote:
>>> Hi,
>>>
>>> On Mon, Jul 14, 2014 at 2:26 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>>>> Hi,
>>>>
>>>> On Wednesday 09 July 2014 05:19 PM, Sachin Kamat wrote:
>>>>> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
>>>>> USB gadget controller supported by the DWC2 gadget driver, make it
>>>>> depend on them and default to ARCH_EXYNOS as they are meant for
>>>>> Exynos platforms. Also, make the sub-drivers silent options enabling
>>>>> them based on the SoC platforms that they are meant to work with. This
>>>>> will make life easier for end users who do not have any way knowing the
>>>>> dependencies.
>>>>
>>>> There is a new Exynos PHY in town, Exynos 3250. Can you rebase your patch on
>>>> top of that?
>>>
>>> Sure. But I did not see it in linux-next yet. Is it merged somewhere?
>>
>> It's in the list. I can push it to my tree if that helps.
>
> That would be great to avoid any other conflicts.

pushed to git://git.kernel.org/pub/scm/linux/kernel/git/kishon/linux-phy.git
next. You can use it to rebase your patch.

Thanks
Kishon

2014-07-14 09:11:26

by Sachin Kamat

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] phy: Kconfig: Re-organize Exynos USB 2.0 PHY configs

On Mon, Jul 14, 2014 at 2:39 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>
>
> On Monday 14 July 2014 02:36 PM, Sachin Kamat wrote:
>> On Mon, Jul 14, 2014 at 2:32 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>>>
>>>
>>> On Monday 14 July 2014 02:29 PM, Sachin Kamat wrote:
>>>> Hi,
>>>>
>>>> On Mon, Jul 14, 2014 at 2:26 PM, Kishon Vijay Abraham I <[email protected]> wrote:
>>>>> Hi,
>>>>>
>>>>> On Wednesday 09 July 2014 05:19 PM, Sachin Kamat wrote:
>>>>>> Since the USB 2.0 PHYs are required with EHCI/OHCI USB drivers and
>>>>>> USB gadget controller supported by the DWC2 gadget driver, make it
>>>>>> depend on them and default to ARCH_EXYNOS as they are meant for
>>>>>> Exynos platforms. Also, make the sub-drivers silent options enabling
>>>>>> them based on the SoC platforms that they are meant to work with. This
>>>>>> will make life easier for end users who do not have any way knowing the
>>>>>> dependencies.
>>>>>
>>>>> There is a new Exynos PHY in town, Exynos 3250. Can you rebase your patch on
>>>>> top of that?
>>>>
>>>> Sure. But I did not see it in linux-next yet. Is it merged somewhere?
>>>
>>> It's in the list. I can push it to my tree if that helps.
>>
>> That would be great to avoid any other conflicts.
>
> pushed to git://git.kernel.org/pub/scm/linux/kernel/git/kishon/linux-phy.git
> next. You can use it to rebase your patch.

Thanks. I will re-spin on top of it.

--
Regards,
Sachin.