From: Felipe Balbi <balbi@kernel.org>
To: Baolin Wang <baolin.wang@linaro.org>, Mark Brown <broonie@kernel.org>
Cc: Greg KH <gregkh@linuxfoundation.org>,
Sebastian Reichel <sre@kernel.org>,
Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>,
David Woodhouse <dwmw2@infradead.org>,
robh@kernel.org, Jun Li <jun.li@nxp.com>,
Marek Szyprowski <m.szyprowski@samsung.com>,
Ruslan Bilovol <ruslan.bilovol@gmail.com>,
Peter Chen <peter.chen@freescale.com>,
Alan Stern <stern@rowland.harvard.edu>,
r.baldyga@samsung.com, grygorii.strashko@ti.com,
Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>,
Lee Jones <lee.jones@linaro.org>,
Charles Keepax <ckeepax@opensource.wolfsonmicro.com>,
patches@opensource.wolfsonmicro.com,
Linux PM list <linux-pm@vger.kernel.org>,
USB <linux-usb@vger.kernel.org>,
device-mainlining@lists.linuxfoundation.org,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management
Date: Tue, 21 Jun 2016 14:53:44 +0300 [thread overview]
Message-ID: <87oa6un4fr.fsf@linux.intel.com> (raw)
In-Reply-To: <CAMz4kuJnkd=zpbnaCRcYd4wjzWVpr5Zom0BBJRnjTTikpwxKjA@mail.gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1187 bytes --]
Hi,
Baolin Wang <baolin.wang@linaro.org> writes:
> On 21 June 2016 at 19:03, Mark Brown <broonie@kernel.org> wrote:
>> On Tue, Jun 21, 2016 at 01:30:49PM +0300, Felipe Balbi wrote:
>>> Baolin Wang <baolin.wang@linaro.org> writes:
>>> > @@ -607,8 +647,31 @@ static int wm831x_power_probe(struct platform_device *pdev)
>>> > }
>>> > }
>>
>>> > + if (wm831x_pdata && wm831x_pdata->usb_gadget) {
>>> > + power->usb_charger =
>>> > + usb_charger_find_by_name(wm831x_pdata->usb_gadget);
>>
>>> the fact that you rely on strings and pass them via pdata is an
>>> indication that you don't have enough description of the HW. Seems like
>>> we need to come up with a set of DT properties which tie a charger to a
>>> UDC.
>>
>>> I'm thinking a phandle would be enough?
>>
>> The wm831x has no DT support currently.
>
> Another hand I suppose the usb charger is one virtual device and does
> not need be described from DT.
Right, I don't think that should be a device at all. But you can pass a
phandle to the UDC controller and use that to get to struct usb_gadget
from which you could reach ->charger.
--
balbi
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 818 bytes --]
next prev parent reply other threads:[~2016-06-21 12:09 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-21 8:39 [PATCH v12 0/4] Introduce usb charger framework to deal with the usb gadget power negotation Baolin Wang
[not found] ` <cover.1466497505.git.baolin.wang-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2016-06-21 8:39 ` [PATCH v12 1/4] gadget: Introduce the usb charger framework Baolin Wang
2016-06-21 8:39 ` Baolin Wang
2016-06-21 10:25 ` Felipe Balbi
2016-06-21 10:25 ` Felipe Balbi
2016-06-21 11:23 ` Baolin Wang
2016-06-21 14:50 ` Felipe Balbi
2016-06-22 1:49 ` Baolin Wang
2016-06-21 8:39 ` [PATCH v12 2/4] gadget: Support for " Baolin Wang
2016-06-21 8:39 ` Baolin Wang
2016-06-21 10:27 ` Felipe Balbi
2016-06-21 10:27 ` Felipe Balbi
2016-06-21 11:29 ` Baolin Wang
2016-06-21 11:49 ` Felipe Balbi
[not found] ` <87twgmn4m7.fsf-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2016-06-21 12:05 ` Baolin Wang
2016-06-21 12:05 ` Baolin Wang
2016-06-21 12:27 ` Felipe Balbi
[not found] ` <87inx2n2vs.fsf-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2016-06-21 12:34 ` Baolin Wang
2016-06-21 12:34 ` Baolin Wang
[not found] ` <CAMz4kuKnzjPOqEr9kJY6SCnq2rszsc55X5=7mWb+ZcbL6G_8DQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-06-21 12:36 ` Felipe Balbi
2016-06-21 12:36 ` Felipe Balbi
2016-06-21 12:43 ` Baolin Wang
2016-06-21 12:53 ` Felipe Balbi
2016-06-21 12:54 ` Felipe Balbi
[not found] ` <87a8ien1o0.fsf-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2016-06-22 1:45 ` Baolin Wang
2016-06-22 1:45 ` Baolin Wang
[not found] ` <87bn2uomzd.fsf-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2016-06-23 8:56 ` Baolin Wang
2016-06-23 8:56 ` Baolin Wang
2016-06-29 8:20 ` Felipe Balbi
2016-06-29 8:31 ` Baolin Wang
2016-06-29 8:34 ` Felipe Balbi
2016-06-29 8:38 ` Baolin Wang
[not found] ` <CAMz4kuL9pJzNsn7xXXCp4s9Rczm5vWhuWfF7VjkuxsMUzNZXZQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2016-06-29 12:06 ` Felipe Balbi
2016-06-29 12:06 ` Felipe Balbi
2016-06-29 12:16 ` Baolin Wang
2016-06-29 12:30 ` Felipe Balbi
2016-06-21 8:39 ` [PATCH v12 3/4] gadget: Integrate with the usb gadget supporting for usb charger Baolin Wang
2016-06-21 8:39 ` Baolin Wang
2016-06-21 8:39 ` [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Baolin Wang
2016-06-21 10:30 ` Felipe Balbi
2016-06-21 10:30 ` Felipe Balbi
2016-06-21 11:03 ` Mark Brown
2016-06-21 11:45 ` Baolin Wang
2016-06-21 11:53 ` Felipe Balbi [this message]
2016-06-21 11:57 ` Baolin Wang
2016-06-21 11:50 ` Felipe Balbi
2016-06-21 14:53 ` Mark Brown
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=87oa6un4fr.fsf@linux.intel.com \
--to=balbi@kernel.org \
--cc=baolin.wang@linaro.org \
--cc=broonie@kernel.org \
--cc=ckeepax@opensource.wolfsonmicro.com \
--cc=dbaryshkov@gmail.com \
--cc=device-mainlining@lists.linuxfoundation.org \
--cc=dwmw2@infradead.org \
--cc=gregkh@linuxfoundation.org \
--cc=grygorii.strashko@ti.com \
--cc=jun.li@nxp.com \
--cc=lee.jones@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=m.szyprowski@samsung.com \
--cc=patches@opensource.wolfsonmicro.com \
--cc=peter.chen@freescale.com \
--cc=r.baldyga@samsung.com \
--cc=robh@kernel.org \
--cc=ruslan.bilovol@gmail.com \
--cc=sre@kernel.org \
--cc=stern@rowland.harvard.edu \
--cc=yoshihiro.shimoda.uh@renesas.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.