All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: Kishon Vijay Abraham I <kishon@ti.com>,
	devicetree@vger.kernel.org, robh+dt@kernel.org,
	pawel.moll@arm.com, mark.rutland@arm.com,
	ijc+devicetree@hellion.org.uk, galak@codeaurora.org
Cc: linux-sh@vger.kernel.org, magnus.damm@gmail.com,
	linux-doc@vger.kernel.org, rdunlap@infradead.org,
	grant.likely@linaro.org
Subject: Re: [PATCH v2] phy: Renesas R-Car Gen2 PHY driver
Date: Fri, 11 Apr 2014 12:10:28 +0000	[thread overview]
Message-ID: <5347DBB4.3070401@cogentembedded.com> (raw)
In-Reply-To: <5346F6B6.8000901@cogentembedded.com>

Hello.

On 10-04-2014 23:53, Sergei Shtylyov wrote:

>> On Wednesday 09 April 2014 03:14 AM, Sergei Shtylyov wrote:
>>> This PHY, though formally being a part of Renesas USBHS controller,
>>> contains the
>>> UGCTRL2 register that controls multiplexing of the USB ports (Renesas calls
>>> them
>>> channels) to the different USB controllers: channel 0 can be connected to
>>> either
>>> PCI EHCI/OHCI or USBHS controllers, channel 2 can be connected to PCI
>>> EHCI/OHCI
>>> or xHCI controllers.

>>> This is a new driver for this USB PHY currently already supported under
>>> drivers/
>>> usb/phy/. The reason for writing the new driver was the requirement that the
>>> multiplexing of USB channels to the controller be dynamic, depending on what
>>> USB drivers are loaded,  rather than static as provided by the old driver.

[...]

>>> The infrastructure provided by drivers/phy/phy-core.c seems to fit that
>>> purpose
>>> ideally. The new driver only supports device tree probing for now.

>>> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

[...]

>>> Index: linux-phy/drivers/phy/phy-rcar-gen2.c
>>> =================================>>> --- /dev/null
>>> +++ linux-phy/drivers/phy/phy-rcar-gen2.c
>>> @@ -0,0 +1,287 @@

[...]

>>> +static struct phy_ops rcar_gen2_phy_ops = {
>>> +    .init        = rcar_gen2_phy_init,
>>> +    .exit        = rcar_gen2_phy_exit,
>>> +    .owner        = THIS_MODULE,
>>> +};
>>> +
>>> +static struct phy_ops rcar_gen2_usbhs_phy_ops = {
>>> +    .init        = rcar_gen2_phy_init,
>>> +    .exit        = rcar_gen2_phy_exit,
>>> +    .power_on    = rcar_gen2_usbhs_phy_power_on,
>>> +    .power_off    = rcar_gen2_usbhs_phy_power_off,
>>> +    .owner        = THIS_MODULE,
>>> +};

>> Let's not create multiple phy_ops for a single driver.

>     Unfortunately, I have to because not all PHYs are equal.

    OK, actually I can do without extra 'struct phy_ops'. I just figured that 
out a bit late...

WBR, Sergei


WARNING: multiple messages have this Message-ID (diff)
From: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>
To: Kishon Vijay Abraham I <kishon@ti.com>,
	devicetree@vger.kernel.org, robh+dt@kernel.org,
	pawel.moll@arm.com, mark.rutland@arm.com,
	ijc+devicetree@hellion.org.uk, galak@codeaurora.org
Cc: linux-sh@vger.kernel.org, magnus.damm@gmail.com,
	linux-doc@vger.kernel.org, rdunlap@infradead.org,
	grant.likely@linaro.org
Subject: Re: [PATCH v2] phy: Renesas R-Car Gen2 PHY driver
Date: Fri, 11 Apr 2014 16:10:28 +0400	[thread overview]
Message-ID: <5347DBB4.3070401@cogentembedded.com> (raw)
In-Reply-To: <5346F6B6.8000901@cogentembedded.com>

Hello.

On 10-04-2014 23:53, Sergei Shtylyov wrote:

>> On Wednesday 09 April 2014 03:14 AM, Sergei Shtylyov wrote:
>>> This PHY, though formally being a part of Renesas USBHS controller,
>>> contains the
>>> UGCTRL2 register that controls multiplexing of the USB ports (Renesas calls
>>> them
>>> channels) to the different USB controllers: channel 0 can be connected to
>>> either
>>> PCI EHCI/OHCI or USBHS controllers, channel 2 can be connected to PCI
>>> EHCI/OHCI
>>> or xHCI controllers.

>>> This is a new driver for this USB PHY currently already supported under
>>> drivers/
>>> usb/phy/. The reason for writing the new driver was the requirement that the
>>> multiplexing of USB channels to the controller be dynamic, depending on what
>>> USB drivers are loaded,  rather than static as provided by the old driver.

[...]

>>> The infrastructure provided by drivers/phy/phy-core.c seems to fit that
>>> purpose
>>> ideally. The new driver only supports device tree probing for now.

>>> Signed-off-by: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>

[...]

>>> Index: linux-phy/drivers/phy/phy-rcar-gen2.c
>>> ===================================================================
>>> --- /dev/null
>>> +++ linux-phy/drivers/phy/phy-rcar-gen2.c
>>> @@ -0,0 +1,287 @@

[...]

>>> +static struct phy_ops rcar_gen2_phy_ops = {
>>> +    .init        = rcar_gen2_phy_init,
>>> +    .exit        = rcar_gen2_phy_exit,
>>> +    .owner        = THIS_MODULE,
>>> +};
>>> +
>>> +static struct phy_ops rcar_gen2_usbhs_phy_ops = {
>>> +    .init        = rcar_gen2_phy_init,
>>> +    .exit        = rcar_gen2_phy_exit,
>>> +    .power_on    = rcar_gen2_usbhs_phy_power_on,
>>> +    .power_off    = rcar_gen2_usbhs_phy_power_off,
>>> +    .owner        = THIS_MODULE,
>>> +};

>> Let's not create multiple phy_ops for a single driver.

>     Unfortunately, I have to because not all PHYs are equal.

    OK, actually I can do without extra 'struct phy_ops'. I just figured that 
out a bit late...

WBR, Sergei


  reply	other threads:[~2014-04-11 12:10 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-08 21:44 [PATCH v2] phy: Renesas R-Car Gen2 PHY driver Sergei Shtylyov
2014-04-08 21:44 ` Sergei Shtylyov
2014-04-10 10:01 ` Kishon Vijay Abraham I
2014-04-10 10:13   ` Kishon Vijay Abraham I
2014-04-10 19:53   ` Sergei Shtylyov
2014-04-10 19:53     ` Sergei Shtylyov
2014-04-11 12:10     ` Sergei Shtylyov [this message]
2014-04-11 12:10       ` Sergei Shtylyov

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=5347DBB4.3070401@cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded.com \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=grant.likely@linaro.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=kishon@ti.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-sh@vger.kernel.org \
    --cc=magnus.damm@gmail.com \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=rdunlap@infradead.org \
    --cc=robh+dt@kernel.org \
    /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.