From: Peter Chen <hzpeterchen@gmail.com>
To: Jun Li <jun.li@nxp.com>
Cc: "mark.rutland@arm.com" <mark.rutland@arm.com>,
Peter Chen <peter.chen@nxp.com>,
"ulf.hansson@linaro.org" <ulf.hansson@linaro.org>,
Stephen Boyd <stephen.boyd@linaro.org>,
"k.kozlowski@samsung.com" <k.kozlowski@samsung.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"festevam@gmail.com" <festevam@gmail.com>,
"stillcompiling@gmail.com" <stillcompiling@gmail.com>,
"pawel.moll@arm.com" <pawel.moll@arm.com>,
"dbaryshkov@gmail.com" <dbaryshkov@gmail.com>,
"mka@chromium.org" <mka@chromium.org>,
"stern@rowland.harvard.edu" <stern@rowland.harvard.edu>,
Peter Chen <peter.chen@freescale.com>,
"dwmw3@infradead.org" <dwmw3@infradead.org>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"mail@maciej.szmigiero.name" <mail@maciej.szmigiero.name>,
"arnd@arndb.de" <arnd@arndb.de>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
s.hauer@pengutro
Subject: Re: [PATCH v5 5/6] usb: chipidea: let chipidea core device of_node equal's glue layer device of_node
Date: Wed, 10 Aug 2016 17:19:30 +0800 [thread overview]
Message-ID: <20160810091930.GB30158@shlinux2> (raw)
In-Reply-To: <AM4PR04MB2130F9E9E9E304D47C44AC46891D0@AM4PR04MB2130.eurprd04.prod.outlook.com>
On Wed, Aug 10, 2016 at 09:00:15AM +0000, Jun Li wrote:
> Hi, Peter
>
> > -----Original Message-----
> > From: linux-usb-owner@vger.kernel.org [mailto:linux-usb-
> > owner@vger.kernel.org] On Behalf Of Peter Chen
> > Sent: Wednesday, August 10, 2016 11:12 AM
> > To: Stephen Boyd <stephen.boyd@linaro.org>
> > Cc: Peter Chen <peter.chen@nxp.com>; gregkh@linuxfoundation.org;
> > stern@rowland.harvard.edu; ulf.hansson@linaro.org; broonie@kernel.org;
> > sre@kernel.org; robh+dt@kernel.org; shawnguo@kernel.org;
> > dbaryshkov@gmail.com; dwmw3@infradead.org; k.kozlowski@samsung.com; linux-
> > arm-kernel@lists.infradead.org; p.zabel@pengutronix.de;
> > devicetree@vger.kernel.org; pawel.moll@arm.com; mark.rutland@arm.com;
> > linux-usb@vger.kernel.org; arnd@arndb.de; s.hauer@pengutronix.de;
> > mail@maciej.szmigiero.name; troy.kisky@boundarydevices.com;
> > festevam@gmail.com; oscar@naiandei.net; linux-pm@vger.kernel.org;
> > stillcompiling@gmail.com; linux-kernel@vger.kernel.org; mka@chromium.org;
> > Peter Chen <peter.chen@freescale.com>
> > Subject: Re: [PATCH v5 5/6] usb: chipidea: let chipidea core device
> > of_node equal's glue layer device of_node
> >
> > On Tue, Aug 09, 2016 at 05:15:36PM -0700, Stephen Boyd wrote:
> > > Quoting Peter Chen (2016-08-08 01:52:10)
> > > > From: Peter Chen <peter.chen@freescale.com>
> > > >
> > > > At device tree, we have no device node for chipidea core, the glue
> > > > layer's node is the parent node for host and udc device. But in
> > > > related driver, the parent device is chipidea core. So, in order to
> > > > let the common driver get parent's node, we let the core's device
> > > > node equals glue layer device node.
> > > >
> > > > Signed-off-by: Peter Chen <peter.chen@freescale.com>
> > > > Tested-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
> > > > Tested-by Joshua Clayton <stillcompiling@gmail.com>
> > > > ---
> > > > drivers/usb/chipidea/core.c | 11 +++++++++++
> > > > 1 file changed, 11 insertions(+)
> > > >
> > > > diff --git a/drivers/usb/chipidea/core.c
> > > > b/drivers/usb/chipidea/core.c index 69426e6..b189dc7 100644
> > > > --- a/drivers/usb/chipidea/core.c
> > > > +++ b/drivers/usb/chipidea/core.c
> > > > @@ -954,6 +954,15 @@ static int ci_hdrc_probe(struct platform_device
> > *pdev)
> > > > dev_err(dev, "unable to init phy: %d\n", ret);
> > > > return ret;
> > > > }
> > > > + /*
> > > > + * At device tree, we have no device node for chipidea core,
> > > > + * the glue layer's node is the parent node for host and udc
> > > > + * device. But in related driver, the parent device is
> > chipidea
> > > > + * core. So, in order to let the common driver get parent's
> > node,
> > > > + * we let the core's device node equals glue layer's node.
> > > > + */
> > > > + if (dev->parent && dev->parent->of_node)
> > > > + dev->of_node = dev->parent->of_node;
> > >
> > > Can this be done earlier? Perhaps after hw_device_init() in this probe
> > > routine? That would allow me to remove the awkward parent searching in
> > > my ULPI DT awareness patch.
> >
> > The reason why I locate it there is to avoid "goto label" for error path
> > during PHY's get and initialization operation.
> >
> > Ok, to simplify your work, I will change it at next version.
>
> As iommu need this to be done even more earlier, will you consider to
> put it before adding the core's platform device?
>
I can't do it, it will introduce another issue that the pinctrl has
already requested by parents. The warning is similar like below, but
occurs at the probe.
http://lkml.iu.edu/hypermail/linux/kernel/1607.2/03150.html
I will see how iommu support can be added for platform devices which
are created by runtime (like chipidea core device).
--
Best Regards,
Peter Chen
WARNING: multiple messages have this Message-ID (diff)
From: hzpeterchen@gmail.com (Peter Chen)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v5 5/6] usb: chipidea: let chipidea core device of_node equal's glue layer device of_node
Date: Wed, 10 Aug 2016 17:19:30 +0800 [thread overview]
Message-ID: <20160810091930.GB30158@shlinux2> (raw)
In-Reply-To: <AM4PR04MB2130F9E9E9E304D47C44AC46891D0@AM4PR04MB2130.eurprd04.prod.outlook.com>
On Wed, Aug 10, 2016 at 09:00:15AM +0000, Jun Li wrote:
> Hi, Peter
>
> > -----Original Message-----
> > From: linux-usb-owner at vger.kernel.org [mailto:linux-usb-
> > owner at vger.kernel.org] On Behalf Of Peter Chen
> > Sent: Wednesday, August 10, 2016 11:12 AM
> > To: Stephen Boyd <stephen.boyd@linaro.org>
> > Cc: Peter Chen <peter.chen@nxp.com>; gregkh at linuxfoundation.org;
> > stern at rowland.harvard.edu; ulf.hansson at linaro.org; broonie at kernel.org;
> > sre at kernel.org; robh+dt at kernel.org; shawnguo at kernel.org;
> > dbaryshkov at gmail.com; dwmw3 at infradead.org; k.kozlowski at samsung.com; linux-
> > arm-kernel at lists.infradead.org; p.zabel at pengutronix.de;
> > devicetree at vger.kernel.org; pawel.moll at arm.com; mark.rutland at arm.com;
> > linux-usb at vger.kernel.org; arnd at arndb.de; s.hauer at pengutronix.de;
> > mail at maciej.szmigiero.name; troy.kisky at boundarydevices.com;
> > festevam at gmail.com; oscar at naiandei.net; linux-pm at vger.kernel.org;
> > stillcompiling at gmail.com; linux-kernel at vger.kernel.org; mka at chromium.org;
> > Peter Chen <peter.chen@freescale.com>
> > Subject: Re: [PATCH v5 5/6] usb: chipidea: let chipidea core device
> > of_node equal's glue layer device of_node
> >
> > On Tue, Aug 09, 2016 at 05:15:36PM -0700, Stephen Boyd wrote:
> > > Quoting Peter Chen (2016-08-08 01:52:10)
> > > > From: Peter Chen <peter.chen@freescale.com>
> > > >
> > > > At device tree, we have no device node for chipidea core, the glue
> > > > layer's node is the parent node for host and udc device. But in
> > > > related driver, the parent device is chipidea core. So, in order to
> > > > let the common driver get parent's node, we let the core's device
> > > > node equals glue layer device node.
> > > >
> > > > Signed-off-by: Peter Chen <peter.chen@freescale.com>
> > > > Tested-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
> > > > Tested-by Joshua Clayton <stillcompiling@gmail.com>
> > > > ---
> > > > drivers/usb/chipidea/core.c | 11 +++++++++++
> > > > 1 file changed, 11 insertions(+)
> > > >
> > > > diff --git a/drivers/usb/chipidea/core.c
> > > > b/drivers/usb/chipidea/core.c index 69426e6..b189dc7 100644
> > > > --- a/drivers/usb/chipidea/core.c
> > > > +++ b/drivers/usb/chipidea/core.c
> > > > @@ -954,6 +954,15 @@ static int ci_hdrc_probe(struct platform_device
> > *pdev)
> > > > dev_err(dev, "unable to init phy: %d\n", ret);
> > > > return ret;
> > > > }
> > > > + /*
> > > > + * At device tree, we have no device node for chipidea core,
> > > > + * the glue layer's node is the parent node for host and udc
> > > > + * device. But in related driver, the parent device is
> > chipidea
> > > > + * core. So, in order to let the common driver get parent's
> > node,
> > > > + * we let the core's device node equals glue layer's node.
> > > > + */
> > > > + if (dev->parent && dev->parent->of_node)
> > > > + dev->of_node = dev->parent->of_node;
> > >
> > > Can this be done earlier? Perhaps after hw_device_init() in this probe
> > > routine? That would allow me to remove the awkward parent searching in
> > > my ULPI DT awareness patch.
> >
> > The reason why I locate it there is to avoid "goto label" for error path
> > during PHY's get and initialization operation.
> >
> > Ok, to simplify your work, I will change it at next version.
>
> As iommu need this to be done even more earlier, will you consider to
> put it before adding the core's platform device?
>
I can't do it, it will introduce another issue that the pinctrl has
already requested by parents. The warning is similar like below, but
occurs at the probe.
http://lkml.iu.edu/hypermail/linux/kernel/1607.2/03150.html
I will see how iommu support can be added for platform devices which
are created by runtime (like chipidea core device).
--
Best Regards,
Peter Chen
WARNING: multiple messages have this Message-ID (diff)
From: Peter Chen <hzpeterchen@gmail.com>
To: Jun Li <jun.li@nxp.com>
Cc: Stephen Boyd <stephen.boyd@linaro.org>,
Peter Chen <peter.chen@nxp.com>,
"gregkh@linuxfoundation.org" <gregkh@linuxfoundation.org>,
"stern@rowland.harvard.edu" <stern@rowland.harvard.edu>,
"ulf.hansson@linaro.org" <ulf.hansson@linaro.org>,
"broonie@kernel.org" <broonie@kernel.org>,
"sre@kernel.org" <sre@kernel.org>,
"robh+dt@kernel.org" <robh+dt@kernel.org>,
"shawnguo@kernel.org" <shawnguo@kernel.org>,
"dbaryshkov@gmail.com" <dbaryshkov@gmail.com>,
"dwmw3@infradead.org" <dwmw3@infradead.org>,
"k.kozlowski@samsung.com" <k.kozlowski@samsung.com>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>,
"p.zabel@pengutronix.de" <p.zabel@pengutronix.de>,
"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
"pawel.moll@arm.com" <pawel.moll@arm.com>,
"mark.rutland@arm.com" <mark.rutland@arm.com>,
"linux-usb@vger.kernel.org" <linux-usb@vger.kernel.org>,
"arnd@arndb.de" <arnd@arndb.de>,
"s.hauer@pengutronix.de" <s.hauer@pengutronix.de>,
"mail@maciej.szmigiero.name" <mail@maciej.szmigiero.name>,
"troy.kisky@boundarydevices.com" <troy.kisky@boundarydevices.com>,
"festevam@gmail.com" <festevam@gmail.com>,
"oscar@naiandei.net" <oscar@naiandei.net>,
"linux-pm@vger.kernel.org" <linux-pm@vger.kernel.org>,
"stillcompiling@gmail.com" <stillcompiling@gmail.com>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"mka@chromium.org" <mka@chromium.org>,
Peter Chen <peter.chen@freescale.com>
Subject: Re: [PATCH v5 5/6] usb: chipidea: let chipidea core device of_node equal's glue layer device of_node
Date: Wed, 10 Aug 2016 17:19:30 +0800 [thread overview]
Message-ID: <20160810091930.GB30158@shlinux2> (raw)
In-Reply-To: <AM4PR04MB2130F9E9E9E304D47C44AC46891D0@AM4PR04MB2130.eurprd04.prod.outlook.com>
On Wed, Aug 10, 2016 at 09:00:15AM +0000, Jun Li wrote:
> Hi, Peter
>
> > -----Original Message-----
> > From: linux-usb-owner@vger.kernel.org [mailto:linux-usb-
> > owner@vger.kernel.org] On Behalf Of Peter Chen
> > Sent: Wednesday, August 10, 2016 11:12 AM
> > To: Stephen Boyd <stephen.boyd@linaro.org>
> > Cc: Peter Chen <peter.chen@nxp.com>; gregkh@linuxfoundation.org;
> > stern@rowland.harvard.edu; ulf.hansson@linaro.org; broonie@kernel.org;
> > sre@kernel.org; robh+dt@kernel.org; shawnguo@kernel.org;
> > dbaryshkov@gmail.com; dwmw3@infradead.org; k.kozlowski@samsung.com; linux-
> > arm-kernel@lists.infradead.org; p.zabel@pengutronix.de;
> > devicetree@vger.kernel.org; pawel.moll@arm.com; mark.rutland@arm.com;
> > linux-usb@vger.kernel.org; arnd@arndb.de; s.hauer@pengutronix.de;
> > mail@maciej.szmigiero.name; troy.kisky@boundarydevices.com;
> > festevam@gmail.com; oscar@naiandei.net; linux-pm@vger.kernel.org;
> > stillcompiling@gmail.com; linux-kernel@vger.kernel.org; mka@chromium.org;
> > Peter Chen <peter.chen@freescale.com>
> > Subject: Re: [PATCH v5 5/6] usb: chipidea: let chipidea core device
> > of_node equal's glue layer device of_node
> >
> > On Tue, Aug 09, 2016 at 05:15:36PM -0700, Stephen Boyd wrote:
> > > Quoting Peter Chen (2016-08-08 01:52:10)
> > > > From: Peter Chen <peter.chen@freescale.com>
> > > >
> > > > At device tree, we have no device node for chipidea core, the glue
> > > > layer's node is the parent node for host and udc device. But in
> > > > related driver, the parent device is chipidea core. So, in order to
> > > > let the common driver get parent's node, we let the core's device
> > > > node equals glue layer device node.
> > > >
> > > > Signed-off-by: Peter Chen <peter.chen@freescale.com>
> > > > Tested-by: Maciej S. Szmigiero <mail@maciej.szmigiero.name>
> > > > Tested-by Joshua Clayton <stillcompiling@gmail.com>
> > > > ---
> > > > drivers/usb/chipidea/core.c | 11 +++++++++++
> > > > 1 file changed, 11 insertions(+)
> > > >
> > > > diff --git a/drivers/usb/chipidea/core.c
> > > > b/drivers/usb/chipidea/core.c index 69426e6..b189dc7 100644
> > > > --- a/drivers/usb/chipidea/core.c
> > > > +++ b/drivers/usb/chipidea/core.c
> > > > @@ -954,6 +954,15 @@ static int ci_hdrc_probe(struct platform_device
> > *pdev)
> > > > dev_err(dev, "unable to init phy: %d\n", ret);
> > > > return ret;
> > > > }
> > > > + /*
> > > > + * At device tree, we have no device node for chipidea core,
> > > > + * the glue layer's node is the parent node for host and udc
> > > > + * device. But in related driver, the parent device is
> > chipidea
> > > > + * core. So, in order to let the common driver get parent's
> > node,
> > > > + * we let the core's device node equals glue layer's node.
> > > > + */
> > > > + if (dev->parent && dev->parent->of_node)
> > > > + dev->of_node = dev->parent->of_node;
> > >
> > > Can this be done earlier? Perhaps after hw_device_init() in this probe
> > > routine? That would allow me to remove the awkward parent searching in
> > > my ULPI DT awareness patch.
> >
> > The reason why I locate it there is to avoid "goto label" for error path
> > during PHY's get and initialization operation.
> >
> > Ok, to simplify your work, I will change it at next version.
>
> As iommu need this to be done even more earlier, will you consider to
> put it before adding the core's platform device?
>
I can't do it, it will introduce another issue that the pinctrl has
already requested by parents. The warning is similar like below, but
occurs at the probe.
http://lkml.iu.edu/hypermail/linux/kernel/1607.2/03150.html
I will see how iommu support can be added for platform devices which
are created by runtime (like chipidea core device).
--
Best Regards,
Peter Chen
next prev parent reply other threads:[~2016-08-10 9:19 UTC|newest]
Thread overview: 57+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-08 8:52 [PATCH v5 0/6] power: add power sequence library Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` [PATCH v5 1/6] binding-doc: power: pwrseq-generic: add binding doc for generic " Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` [PATCH v5 2/6] power: add " Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
[not found] ` <1470646331-23227-3-git-send-email-peter.chen-3arQi8VN3Tc@public.gmane.org>
2016-08-09 0:25 ` Matthias Kaehlcke
2016-08-09 0:25 ` Matthias Kaehlcke
2016-08-09 0:25 ` Matthias Kaehlcke
2016-08-08 8:52 ` [PATCH v5 3/6] binding-doc: usb: usb-device: add optional properties for power sequence Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` [PATCH v5 4/6] usb: core: add power sequence handling for USB devices Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` [PATCH v5 5/6] usb: chipidea: let chipidea core device of_node equal's glue layer device of_node Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-10 0:15 ` Stephen Boyd
2016-08-10 0:15 ` Stephen Boyd
2016-08-10 3:11 ` Peter Chen
2016-08-10 3:11 ` Peter Chen
2016-08-10 9:00 ` Jun Li
2016-08-10 9:00 ` Jun Li
2016-08-10 9:00 ` Jun Li
2016-08-10 9:19 ` Peter Chen [this message]
2016-08-10 9:19 ` Peter Chen
2016-08-10 9:19 ` Peter Chen
2016-08-08 8:52 ` [PATCH v5 6/6] ARM: dts: imx6qdl-udoo.dtsi: fix onboard USB HUB property Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-08 8:52 ` Peter Chen
2016-08-09 23:33 ` Joshua Clayton
2016-08-09 23:33 ` Joshua Clayton
[not found] ` <57AA684F.4020004-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2016-08-10 3:02 ` Peter Chen
2016-08-10 3:02 ` Peter Chen
2016-08-10 3:02 ` Peter Chen
2016-08-11 16:40 ` [PATCHES] ARM: dts: update udoo and evi hubs to use pwrseq Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
2016-08-11 16:40 ` [PATCH 2/3] ARM: dts: imx6qdl-udoo.dtsi: fix onboard USB HUB property Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
[not found] ` <1470933632-22133-1-git-send-email-stillcompiling-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2016-08-11 16:40 ` [PATCH 1/3] ARM: dts: imx6qdl: Enable usb node children with <reg> Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
2016-08-11 16:40 ` [PATCH 3/3] ARM: dts: imx6q-evi: Fix onboard hub reset line Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
2016-08-11 16:40 ` Joshua Clayton
2016-08-12 3:11 ` Peter Chen
2016-08-12 3:11 ` Peter Chen
2016-08-12 15:20 ` Joshua Clayton
2016-08-12 15:20 ` Joshua Clayton
2016-08-12 15:20 ` Joshua Clayton
2016-08-12 3:09 ` [PATCHES] ARM: dts: update udoo and evi hubs to use pwrseq Peter Chen
2016-08-12 3:09 ` Peter Chen
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=20160810091930.GB30158@shlinux2 \
--to=hzpeterchen@gmail.com \
--cc=arnd@arndb.de \
--cc=dbaryshkov@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=dwmw3@infradead.org \
--cc=festevam@gmail.com \
--cc=jun.li@nxp.com \
--cc=k.kozlowski@samsung.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=mail@maciej.szmigiero.name \
--cc=mark.rutland@arm.com \
--cc=mka@chromium.org \
--cc=pawel.moll@arm.com \
--cc=peter.chen@freescale.com \
--cc=peter.chen@nxp.com \
--cc=s.hauer@pengutro \
--cc=stephen.boyd@linaro.org \
--cc=stern@rowland.harvard.edu \
--cc=stillcompiling@gmail.com \
--cc=ulf.hansson@linaro.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.