On 21 June 2016 at 20:53, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>>>>> Can't you just tie a charger to a UDC and avoid the charger class
>>>>>>>>> completely?
On 21 June 2016 at 22:50, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> This patch introduces the usb charger driver based on usb gadget that
>>>> makes an enhancement to a power driver.
It will be crash to stop gadget when the dwc3 device had been into suspend
state, thus we need to check if the dwc3 device had been into suspend state
when UDC try to stop gadget.
By the way I have rebased on your 'testing/next' branch.
Signed-off-by: Baolin Wang <baolin.w...@linaro.
On 21 June 2016 at 20:27, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>> Can't you just tie a charger to a UDC and avoid the charger
On 21 June 2016 at 18:25, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>> This patch introduces the usb charger driver based on usb gadget that
>> makes an enhancement to a power driver. It works well in pr
On 21 June 2016 at 20:36, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>> Baolin Wang <baolin.w...@linaro.org> writes:
>>>&
Hi Felipe,
On 21 June 2016 at 15:45, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi Baolin,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> -Original Message-
>>>> From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-
>>>&g
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Reviewed-by: Li Jun <jun...@nxp.com>
Tested-by:
-by: Mark Brown <broo...@kernel.org>
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Lee Jones <lee.jo...@linaro.org>
Acked-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com>
Acked-by: Peter Chen <peter.c...@freescale.com>
Acked-by: Seba
When the usb gadget supporting for usb charger is ready, the usb charger
can implement the usb_charger_plug_by_gadget() function and usb_charger_exit()
function by getting 'struct usb_charger' from 'struct gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Reviewed-by: Li Ju
For supporting the usb charger, it adds the usb_charger_init() and
usb_charger_exit() functions for usb charger initialization and exit.
It will report to the usb charger when the gadget state is changed,
then the usb charger can do the power things.
Signed-off-by: Baolin Wang <baoli
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Reviewed-by: Li Jun <jun...@nxp.com>
Tested-by:
-by: Mark Brown <broo...@kernel.org>
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Lee Jones <lee.jo...@linaro.org>
Acked-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com>
Acked-by: Peter Chen <peter.c...@freescale.com>
Acked-by: Seba
When the usb gadget supporting for usb charger is ready, the usb charger
can implement the usb_charger_plug_by_gadget() function, usb_charger_exit()
function and dev_to_uchger() function by getting 'struct usb_charger' from
'struct gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.
mutex lock in usb_charger_set_cur_limit_by_type() function
in case will be issued in atomic context.
Baolin Wang (4):
usb: gadget: Introduce the usb charger framework
usb: gadget: Support for the usb charger framework
usb: gadget: Integrate with the usb gadget supporting for usb charg
For supporting the usb charger, it adds the usb_charger_init() and
usb_charger_exit() functions for usb charger initialization and exit.
It will report to the usb charger when the gadget state is changed,
then the usb charger can do the power things.
Signed-off-by: Baolin Wang <baoli
Hi,
On 21 June 2016 at 18:27, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>> For supporting the usb charger, it adds the usb_charger_init() and
>> usb_charger_exit() functions for usb charger initializ
Hi Felipe,
On 13 June 2016 at 23:13, Jun Li <jun...@nxp.com> wrote:
> Hi
>
>> -Original Message-
>> From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-
>> ow...@vger.kernel.org] On Behalf Of Baolin Wang
>> Sent: Monday, June 13, 2016
Hi Felipe,
On 29 June 2016 at 16:20, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> For supporting the usb charger, it adds the usb_charger_i
On 29 June 2016 at 16:34, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>> For supporting the usb charger, it adds the usb_charger_init() and
>>>>>> usb_char
On 25 January 2016 at 11:44, Greg KH <gre...@linuxfoundation.org> wrote:
> On Mon, Jan 04, 2016 at 11:04:26AM +0800, Baolin Wang wrote:
>> Currently the Linux kernel does not provide any standard integration of this
>> feature that integrates the USB subsystem with the sy
On 16 March 2016 at 19:48, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi Baolin,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>> [ text/plain ]
>> Currently the Linux kernel does not provide any standard integration of this
>> feature that integrat
On 16 March 2016 at 20:09, Oliver Neukum <oneu...@suse.com> wrote:
> On Wed, 2016-03-16 at 19:46 +0800, Baolin Wang wrote:
>> This patch introduces the usb charger driver based on usb gadget that
>> makes an enhancement to a power driver. It works well in practice but
>
On 29 March 2016 at 08:32, Peter Chen <peter.c...@nxp.com> wrote:
>
>>
>> On 28 March 2016 at 15:13, Peter Chen <hzpeterc...@gmail.com> wrote:
>> > On Mon, Mar 28, 2016 at 02:51:40PM +0800, Baolin Wang wrote:
>> >> On 25 March 2016 at 15:09, Peter Ch
On 31 March 2016 at 14:18, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>> [ text/plain ]
>> On 30 March 2016 at 19:24, Felipe Balbi <ba...@kernel.org> wrote:
>>>>> >> >> >
On 30 March 2016 at 18:58, Jun Li wrote:
>> >> >> > Seems you don't want to guarantee charger type detection is done
>> >> >> > before gadget connection(pullup DP), right?
>> >> >> > I see you call usb_charger_detect_type() in each gadget usb
>> >> >> > state
>> >> >> changes.
>>
On 30 March 2016 at 19:24, Felipe Balbi wrote:
>>> >> >> >
>>> >> >> > Seems you don't want to guarantee charger type detection is done
>>> >> >> > before gadget connection(pullup DP), right?
>>> >> >> > I see you call usb_charger_detect_type() in each gadget usb
>>> >> >> >
gt;> + return -EINVAL;
>> +
>> + device_unregister(>dev);
>> + return 0;
>> +}
>> +
>> +static void devm_uchger_dev_unreg(struct device *dev, void *res)
>> +{
>> + usb_charger_unregister(*(struct usb_charger **)res);
>> +}
>>
On 31 March 2016 at 14:12, Jun Li <jun...@nxp.com> wrote:
> Hi
>
>> -Original Message-----
>> From: Baolin Wang [mailto:baolin.w...@linaro.org]
>> Sent: Thursday, March 31, 2016 1:23 PM
>> To: Jun Li <jun...@nxp.com>
>> Cc: Peter Chen <hzp
On 31 March 2016 at 14:42, Felipe Balbi wrote:
+#define DEFAULT_CUR_PROTECT (50)
>>>
>>> Where is this coming from ? Also, () are not necessary.
>>
>> Just want to protect the default current limitation. If that does not
>> need, I'll remove it.
>
> It's your HW :-) You
On 31 March 2016 at 16:18, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>> +#define DEFAULT_SDP_CUR_LIMIT(500 - DEFAULT_CUR_PROTECT)
>>>>>
>>>>> According to
On 31 March 2016 at 16:15, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi Baolin,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> >> Make sense. In our company's solution, charger detection can be done
>>>> >> by hardware from PMIC a
For supporting the usb charger, it adds the usb_charger_init() and
usb_charger_exit() functions for usb charger initialization and exit.
It will report to the usb charger when the gadget state is changed,
then the usb charger can do the power things.
Signed-off-by: Baolin Wang <baoli
When the usb gadget supporting for usb charger is ready, the usb charger
can implement the usb_charger_plug_by_gadget() function and usb_charger_exit()
function by getting 'struct usb_charger' from 'struct gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadg
-by: Mark Brown <broo...@kernel.org>
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Lee Jones <lee.jo...@linaro.org>
Acked-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com>
Acked-by: Peter Chen <peter.c...@freescale.com>
Acked-by: Seba
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/Kconfig |7 +
drive
sysfs attributes.
- Change the SDP charger default current if gadget is SS.
- Remove the 'get_charger_type' callback in gadget->ops.
Baolin Wang (4):
gadget: Introduce the usb charger framework
gadget: Support for the usb charger framework
gadget: Integrate with the usb gadget support
On 6 April 2016 at 15:19, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Fri, Apr 01, 2016 at 03:21:50PM +0800, Baolin Wang wrote:
>>
>> @@ -563,6 +564,8 @@ struct usb_gadget_ops {
>> struct usb_ep *(*match_ep)(struct usb_gadget *,
>>
On 6 April 2016 at 16:26, Jun Li wrote:
> Hi
>
>> + */
>> +static enum usb_charger_type
>> +usb_charger_get_type_by_others(struct usb_charger *uchger) {
>> + if (uchger->type != UNKNOWN_TYPE)
>> + return uchger->type;
>> +
>> + if (uchger->psy) {
>> +
...@gmail.com> writes:
>>> > On Wed, Apr 06, 2016 at 11:05:26AM +0300, Felipe Balbi wrote:
>>> >> Peter Chen <hzpeterc...@gmail.com> writes:
>>> >> > On Wed, Apr 06, 2016 at 10:38:23AM +0300, Felipe Balbi wrote:
>>> >> >> Peter C
On 8 April 2016 at 19:27, Jun Li <jun...@nxp.com> wrote:
>
>
>> -Original Message-----
>> From: Baolin Wang [mailto:baolin.w...@linaro.org]
>> Sent: Friday, April 08, 2016 7:00 PM
>> To: Jun Li <jun...@nxp.com>
>> Cc: ba...@kernel.org; gre...@
Hi Jun,
>> >> +/*
>> >> + * usb_charger_detect_type() - detect the charger type manually.
>> >> + * @uchger - usb charger device
>> >> + *
>> >> + * Note: You should ensure you need to detect the charger type
>> >> +manually on your
>> >> + * platform.
>> >> + * You should call it at the right
Hi Jun,
On 8 April 2016 at 16:04, Jun Li wrote:
> Hi, Baolin
>
>> +/*
>> + * usb_charger_detect_type() - detect the charger type manually.
>> + * @uchger - usb charger device
>> + *
>> + * Note: You should ensure you need to detect the charger type manually
>> +on your
>> + *
Hi Jun,
Sorry for late reply.
>> >> >> >> +/*
>> >> >> >> + * usb_charger_detect_type() - detect the charger type manually.
>> >> >> >> + * @uchger - usb charger device
>> >> >> >> + *
>> >> >> >> + * Note: You should ensure you need to detect the charger type
>> >> >> >> +manually on your
>> >>
When the usb gadget supporting for usb charger is ready, the usb charger
should get the type by the 'get_charger_type' callback which is implemented
by the usb gadget operations, and get the usb charger pointer from struct
'usb_gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.
On 16 March 2016 at 19:20, Mark Brown <broo...@kernel.org> wrote:
> On Wed, Mar 16, 2016 at 01:05:27PM +0200, Felipe Balbi wrote:
>> Mark Brown <broo...@kernel.org> writes:
>> > On Mon, Feb 29, 2016 at 11:22:12PM +0900, Mark Brown wrote:
>> >> On Mon, Jan
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/Kconfig |7 +
drive
will implemented by
user for usb gadget operations to get the usb charger type.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/udc/udc-core.c | 11 +++
include/linux/usb/gadget.h| 11 +++
2 files changed, 22 insertions(+)
diff
When the usb gadget supporting for usb charger is ready, the usb charger
should get the type by the 'get_charger_type' callback which is implemented
by the usb gadget operations, and get the usb charger pointer from struct
'usb_gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.
detection.
- Supply the notification mechanism to userspace when charger state is changed.
- Integrate with the vbus staff in the gadget API.
Baolin Wang (4):
gadget: Introduce the usb charger framework
gadget: Support for the usb charger framework
gadget: Integrate with the usb gadget supporting
-by: Mark Brown <broo...@kernel.org>
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Lee Jones <lee.jo...@linaro.org>
Acked-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com>
Acked-by: Peter Chen <peter.c...@freescale.com>
Acked-by: Seba
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/Kconfig |7 +
drive
Hi Peter,
On 5 April 2016 at 14:46, Peter Chen wrote:
>
> We are thinking USB charger framework for Freescale i.mx SoC series,
> since our internal framework is not good enough.
> So I have more questions for your framework since there are many
> different USB charger
On 5 April 2016 at 15:56, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Fri, Apr 01, 2016 at 03:21:49PM +0800, Baolin Wang wrote:
>> +
>> +int devm_usb_charger_register(struct device *dev,
>> + struct usb_charger *uchger)
>> +{
On 5 April 2016 at 16:12, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Tue, Apr 05, 2016 at 03:54:31PM +0800, Baolin Wang wrote:
>> Hi Peter,
>>
>> On 5 April 2016 at 14:46, Peter Chen <hzpeterc...@gmail.com> wrote:
>> >
>> > We are thinking
On 5 April 2016 at 17:43, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Tue, Apr 05, 2016 at 05:34:02PM +0800, Baolin Wang wrote:
>> On 5 April 2016 at 16:12, Peter Chen <hzpeterc...@gmail.com> wrote:
>> > On Tue, Apr 05, 2016 at 03:54:31PM +0800, Bao
On 30 March 2016 at 17:19, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Wed, Mar 30, 2016 at 04:40:31PM +0800, Baolin Wang wrote:
>> >> > - Third, since composite driver covers 500mA (and more for CDP) after
>> >> > set
>> >> > config
On 30 March 2016 at 16:07, Jun Li wrote:
> Hi
>> On 30 March 2016 at 10:54, Jun Li wrote:
>> >> >> It is not for udc driver but for power users who want to negotiate
>> >> >> with USB subsystem.
>> >> >>
>> >> >
>> >> > Seems you don't want to guarantee charger
On 30 March 2016 at 15:42, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Wed, Mar 30, 2016 at 03:07:49PM +0800, Baolin Wang wrote:
>> On 30 March 2016 at 10:05, Peter Chen <hzpeterc...@gmail.com> wrote:
>> > On Tue, Mar 29, 2016 at 10:23:14AM -0700, Mark Brown wro
.
Baolin Wang (4):
gadget: Introduce the usb charger framework
gadget: Support for the usb charger framework
gadget: Integrate with the usb gadget supporting for usb charger
power: wm831x_power: Support USB charger current limit management
drivers/power/wm831x_power.c | 69
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/Kconfig |7 +
drive
When the usb gadget supporting for usb charger is ready, the usb charger
should get the type by the 'get_charger_type' callback which is implemented
by the usb gadget operations, and get the usb charger pointer from struct
'usb_gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.
will implemented by
user for usb gadget operations to get the usb charger type.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/udc/udc-core.c | 11 +++
include/linux/usb/gadget.h| 15 +++
2 files changed, 26 insertions(+)
diff
-by: Mark Brown <broo...@kernel.org>
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Lee Jones <lee.jo...@linaro.org>
Acked-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com>
Acked-by: Peter Chen <peter.c...@freescale.com>
Acked-by: Seba
On 25 March 2016 at 15:09, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Thu, Mar 24, 2016 at 08:35:53PM +0800, Baolin Wang wrote:
>> Currently the Linux kernel does not provide any standard integration of this
>> feature that integrates the USB subsystem with the sy
On 28 March 2016 at 15:13, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Mon, Mar 28, 2016 at 02:51:40PM +0800, Baolin Wang wrote:
>> On 25 March 2016 at 15:09, Peter Chen <hzpeterc...@gmail.com> wrote:
>> > On Thu, Mar 24, 2016 at 08:35:53PM +0800, Baolin Wang wr
On 29 March 2016 at 16:45, Jun Li <jun...@nxp.com> wrote:
>
>
>> -Original Message-
>> From: linux-usb-ow...@vger.kernel.org [mailto:linux-usb-
>> ow...@vger.kernel.org] On Behalf Of Baolin Wang
>> Sent: Monday, March 28, 2016 2:52 PM
>> To: Peter
On 30 March 2016 at 10:54, Jun Li wrote:
>> >> It is not for udc driver but for power users who want to negotiate
>> >> with USB subsystem.
>> >>
>> >
>> > Seems you don't want to guarantee charger type detection is done
>> > before gadget connection(pullup DP), right?
>> > I see
On 30 March 2016 at 10:05, Peter Chen <hzpeterc...@gmail.com> wrote:
> On Tue, Mar 29, 2016 at 10:23:14AM -0700, Mark Brown wrote:
>> On Mon, Mar 28, 2016 at 03:13:51PM +0800, Peter Chen wrote:
>> > On Mon, Mar 28, 2016 at 02:51:40PM +0800, Baolin Wang wrote:
>>
On 31 March 2016 at 18:06, Felipe Balbi <ba...@kernel.org> wrote:
> Baolin Wang <baolin.w...@linaro.org> writes:
>> [ text/plain ]
>> On 31 March 2016 at 16:18, Felipe Balbi <ba...@kernel.org> wrote:
>>>
>>> Hi,
>>>
>&g
Hi Pavel,
On 24 April 2016 at 03:53, Pavel Machek wrote:
> Hi!
>
>> +/*
>> + * Sysfs attributes:
>> + *
>> + * These sysfs attributes are used for showing and setting different type
>> + * (SDP/DCP/CDP/ACA) chargers' current limitation.
>> + */
>> +static ssize_t
usb_charger_get_state() function to check charger state.
- Remove the mutex lock in usb_charger_set_cur_limit_by_type() function
in case will be issued in atomic context.
Baolin Wang (4):
gadget: Introduce the usb charger framework
gadget: Support for the usb charger framework
gadget: Integrate
When the usb gadget supporting for usb charger is ready, the usb charger
can implement the usb_charger_plug_by_gadget() function and usb_charger_exit()
function by getting 'struct usb_charger' from 'struct gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadg
For supporting the usb charger, it adds the usb_charger_init() and
usb_charger_exit() functions for usb charger initialization and exit.
It will report to the usb charger when the gadget state is changed,
then the usb charger can do the power things.
Signed-off-by: Baolin Wang <baoli
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/Kconfig |7 +
drive
Hi Felipe,
On 13 May 2016 at 20:46, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>> why does it need restart? Why is dwc3 powered off? Who powers it off?
>>>>
>>>> Because when
On 17 May 2016 at 17:25, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>> Make sense.
>>>>>
>>>>> cool, if you wanna work on it, let me know and I can give some details
It had changed to be suspend event for BIT6 in DEVT register from
version 2.30a and above. Thus this patch introduces one suspend
event handler to handle the suspend event.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/dwc3/gadget.c | 26 +-
On 13 May 2016 at 20:46, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>> why does it need restart? Why is dwc3 powered off? Who powers it off?
>>>>
>>>> Because when the dwc3
Hi Felipe,
On 13 May 2016 at 18:40, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>> Currently on some platforms, the gadget device can be power off to
>> save power when the Vbus is off, which means no cable p
On 13 May 2016 at 20:09, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> diff --git a/drivers/usb/dwc3/core.h b/drivers/usb/dwc3/core.h
>>>> index 6254b2f..dada5c6 100644
>>>> ---
Currently on some platforms, the gadget device can be power off to save power
when the Vbus is off, which means no cable plugging in now. In this situation
we should defer starting the gadget until the gadget device is power on by
connecting host.
Signed-off-by: Baolin Wang <baoli
Hi Felipe,
On 17 May 2016 at 18:47, Baolin Wang <baolin.w...@linaro.org> wrote:
> On 17 May 2016 at 17:25, Felipe Balbi <ba...@kernel.org> wrote:
>>
>> Hi,
>>
>> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>>> Make sense.
On 18 May 2016 at 19:21, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>> @@ -1748,15 +1754,25 @@ static int dwc3_gadget_start(struct usb_gadget
>>>>>> *g,
>>>>>
Hi,
On 18 May 2016 at 18:22, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> @@ -1485,16 +1490,11 @@ static int dwc3_gadget_run_stop(struct dwc3
>>>> *dwc, int is_on, int suspend)
On 18 May 2016 at 18:12, Felipe Balbi <ba...@kernel.org> wrote:
>
> Hi,
>
> Baolin Wang <baolin.w...@linaro.org> writes:
>>>> Baolin Wang <baolin.w...@linaro.org> writes:
>>>>>>>>> Make sense.
>>>>>>>>
>
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadget/Kconfig |7 +
drive
When the usb gadget supporting for usb charger is ready, the usb charger
can implement the usb_charger_plug_by_gadget() function and usb_charger_exit()
function by getting 'struct usb_charger' from 'struct gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
---
drivers/usb/gadg
-by: Mark Brown <broo...@kernel.org>
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Lee Jones <lee.jo...@linaro.org>
Acked-by: Charles Keepax <ckee...@opensource.wolfsonmicro.com>
Acked-by: Peter Chen <peter.c...@freescale.com>
Acked-by: Seba
sysfs attributes.
- Change the SDP charger default current if gadget is SS.
- Remove the 'get_charger_type' callback in gadget->ops.
Baolin Wang (4):
gadget: Introduce the usb charger framework
gadget: Support for the usb charger framework
gadget: Integrate with the usb gadget support
For supporting the usb charger, it adds the usb_charger_init() and
usb_charger_exit() functions for usb charger initialization and exit.
It will report to the usb charger when the gadget state is changed,
then the usb charger can do the power things.
Signed-off-by: Baolin Wang <baoli
Hi Felipe,
What do you think of this version patchset? Could you review this
patchset when you feel free? I really hope to move the usb charger
forwards with suggestions. Thanks.
On 7 April 2016 at 19:48, Baolin Wang <baolin.w...@linaro.org> wrote:
> Currently the Linux kernel does no
Hi Jun,
On 18 April 2016 at 16:27, Jun Li wrote:
>> >>
>> >> But another issue is some users may need to get the charger type from
>> >> power supply by "power_supply_get_property()" function, we need to
>> >> integrate with the power supply things in the usb charger framework,
Hi,
On 26 July 2016 at 07:15, Felipe F. Tonello wrote:
> USB spec specifies wMaxPacketSize to be little endian (as other properties),
> so when using this variable in the driver we should convert to the current
> CPU endianness if necessary.
>
> Signed-off-by: Felipe F.
Hi Felipe,
On 26 July 2016 at 19:06, Felipe Ferreri Tonello <e...@felipetonello.com> wrote:
> Hi Baolin,
>
> Sorry for not replying for previous emails because for some reason these
> emails were archived. :(
>
> On 12/07/16 10:01, Baolin Wang wrote:
>> Some gadg
.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Acked-by: Michal Nazarewicz <min...@mina86.com>
---
Changelog:
v2:
- Simplify the method to get buffer length.
v1:
- Remove the in_ep modification.
- Remove max_t() function.
drivers/usb/gadget/function/f_midi.c | 11 +++
For supporting the usb charger, it adds the usb_charger_init() and
usb_charger_exit() functions for usb charger initialization and exit.
It will report to the usb charger when the gadget state is changed,
then the usb charger can do the power things.
Signed-off-by: Baolin Wang <baoli
When the usb gadget supporting for usb charger is ready, the usb charger
can implement the usb_charger_plug_by_gadget() function, usb_charger_exit()
function and dev_to_uchger() function by getting 'struct usb_charger' from
'struct gadget'.
Signed-off-by: Baolin Wang <baolin.w...@linaro.
or usb gadget state.
This patch doesn't yet integrate with the gadget code, so some functions
which rely on the 'gadget' are not completed, that will be implemented
in the following patches.
Signed-off-by: Baolin Wang <baolin.w...@linaro.org>
Reviewed-by: Li Jun <jun...@nxp.com>
Tested-by:
ic context.
Baolin Wang (4):
usb: gadget: Introduce the usb charger framework
usb: gadget: Support for the usb charger framework
usb: gadget: Integrate with the usb gadget supporting for usb charger
power: wm831x_power: Support USB charger current limit management
drivers/power/wm831x_power.c
101 - 200 of 509 matches
Mail list logo