Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1427670
| From | Baolin Wang <baolin.wang@linaro.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management |
| Date | 2016-06-21 14:00 +0200 |
| Message-ID | <rMsvv-5kN-13@gated-at.bofh.it> (permalink) |
| References | (1 earlier) <rMpxD-3qk-1@gated-at.bofh.it> <rMrg6-4Cx-19@gated-at.bofh.it> <rMsc9-5dO-7@gated-at.bofh.it> <rMslQ-5hj-31@gated-at.bofh.it> <rMsvv-5kN-15@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
On 21 June 2016 at 19:53, Felipe Balbi <balbi@kernel.org> wrote:
>
> 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.
Ah, make sense.
--
Baolin.wang
Best Regards
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Baolin Wang <baolin.wang@linaro.org> - 2016-06-21 10:50 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Felipe Balbi <balbi@kernel.org> - 2016-06-21 12:40 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Mark Brown <broonie@kernel.org> - 2016-06-21 13:40 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Baolin Wang <baolin.wang@linaro.org> - 2016-06-21 13:50 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Baolin Wang <baolin.wang@linaro.org> - 2016-06-21 14:00 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Felipe Balbi <balbi@kernel.org> - 2016-06-21 14:20 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Felipe Balbi <balbi@kernel.org> - 2016-06-21 14:00 +0200
Re: [PATCH v12 4/4] power: wm831x_power: Support USB charger current limit management Mark Brown <broonie@kernel.org> - 2016-06-21 17:00 +0200
csiph-web