From: peter.chen@freescale.com (Peter Chen)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v8 07/13] usb: chipidea: fix phy handling
Date: Tue, 18 Nov 2014 12:47:28 +0800 [thread overview]
Message-ID: <20141118044727.GB15650@shlinux2> (raw)
In-Reply-To: <1416231347-27193-8-git-send-email-antoine.tenart@free-electrons.com>
On Mon, Nov 17, 2014 at 02:35:41PM +0100, Antoine Tenart wrote:
> The generic plaftorm device for ChipIdea drivers is probed by calling
> ci_hdrc_probe. The device structure used is not the one of the specific
> ChipIdea driver but the one of the generic ChipIdea platform device.
>
> This results in not being able to probe the PHYs as we're not using the
> right device structure. Since all ChipIdea drivers are retrieving their
> PHYs in their specific driver code, this didn't impact any of them yet.
>
> Fixes it using the right device structure (dev->parent).
>
> Signed-off-by: Antoine Tenart <antoine.tenart@free-electrons.com>
> ---
> drivers/usb/chipidea/core.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c
> index de1e4a84aa93..068e0c6acc3f 100644
> --- a/drivers/usb/chipidea/core.c
> +++ b/drivers/usb/chipidea/core.c
> @@ -686,8 +686,8 @@ static int ci_hdrc_probe(struct platform_device *pdev)
> } else if (ci->platdata->usb_phy) {
> ci->usb_phy = ci->platdata->usb_phy;
> } else {
> - ci->phy = devm_phy_get(dev, "usb-phy");
> - ci->usb_phy = devm_usb_get_phy(dev, USB_PHY_TYPE_USB2);
> + ci->phy = devm_phy_get(dev->parent, "usb-phy");
> + ci->usb_phy = devm_usb_get_phy(dev->parent, USB_PHY_TYPE_USB2);
>
> /* if both generic PHY and USB PHY layers aren't enabled */
> if (PTR_ERR(ci->phy) == -ENOSYS &&
> --
> 2.1.0
>
Acked-by: Peter Chen <peter.chen@freescale.com>
--
Best Regards,
Peter Chen
next prev parent reply other threads:[~2014-11-18 4:47 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-11-17 13:35 [PATCH v8 00/13] ARM: berlin: USB support Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 01/13] reset: add the Berlin reset controller driver Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 02/13] Documentation: bindings: add reset bindings docs for Marvell Berlin SoCs Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 03/13] ARM: Berlin: select the reset controller Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 04/13] ARM: dts: berlin: add a required reset property in the chip controller node Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 05/13] phy: add the Berlin USB PHY driver Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 06/13] Documentation: bindings: add doc for the Berlin USB PHY Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 07/13] usb: chipidea: fix phy handling Antoine Tenart
2014-11-18 4:47 ` Peter Chen [this message]
2014-11-17 13:35 ` [PATCH v8 08/13] usb: chipidea: add a usb2 driver for ci13xxx Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 09/13] Documentation: bindings: add doc for the USB2 ChipIdea USB driver Antoine Tenart
2014-11-17 13:35 ` [PATCH v8 10/13] ARM: dts: berlin: add BG2Q nodes for USB support Antoine Tenart
2014-11-17 18:26 ` Sergei Shtylyov
2014-11-18 19:36 ` Sebastian Hesselbarth
2014-11-17 13:35 ` [PATCH v8 11/13] ARM: dts: Berlin: enable USB on the BG2Q DMP Antoine Tenart
2014-11-18 19:37 ` Sebastian Hesselbarth
2014-11-17 13:35 ` [PATCH v8 12/13] ARM: dts: berlin: add BG2CD nodes for USB support Antoine Tenart
2014-11-18 19:38 ` Sebastian Hesselbarth
2014-11-17 13:35 ` [PATCH v8 13/13] ARM: dts: berlin: enable USB on the Google Chromecast Antoine Tenart
2014-11-18 19:38 ` Sebastian Hesselbarth
2014-11-18 5:00 ` [PATCH v8 00/13] ARM: berlin: USB support Peter Chen
2014-11-18 19:40 ` Sebastian Hesselbarth
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=20141118044727.GB15650@shlinux2 \
--to=peter.chen@freescale.com \
--cc=linux-arm-kernel@lists.infradead.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).