Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1251267
| From | Jiada Wang <jiada_wang@mentor.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] usb: chipidea: udc: clear vbus_active flag in udc_stop |
| Date | 2015-10-20 04:40 +0200 |
| Message-ID | <qlv0d-70J-1@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
Currently in udc_stop, if vbus_active flag is true, all USB activities
will be stopped, but vbus_active flag is still left to be true,
this causes issue, when afterwards driver tries to connect gadget
device to host, But due to the uncleared vbus_active, some necessary
setup steps are skipped.
This patch clears vbus_active flag in udc_stop callback.
Signed-off-by: Jiada Wang <jiada_wang@mentor.com>
---
drivers/usb/chipidea/udc.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
index 8223fe7..b9ac228 100644
--- a/drivers/usb/chipidea/udc.c
+++ b/drivers/usb/chipidea/udc.c
@@ -1762,6 +1762,7 @@ static int ci_udc_stop(struct usb_gadget *gadget)
spin_lock_irqsave(&ci->lock, flags);
if (ci->vbus_active) {
+ ci->vbus_active = 0;
hw_device_state(ci, 0);
if (ci->platdata->notify_event)
ci->platdata->notify_event(ci,
--
2.4.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH] usb: chipidea: udc: clear vbus_active flag in udc_stop Jiada Wang <jiada_wang@mentor.com> - 2015-10-20 04:40 +0200
Re: [PATCH] usb: chipidea: udc: clear vbus_active flag in udc_stop Jiada Wang <jiada_wang@mentor.com> - 2015-10-20 08:20 +0200
Re: [PATCH] usb: chipidea: udc: clear vbus_active flag in udc_stop Jiada Wang <jiada_wang@mentor.com> - 2015-10-20 08:40 +0200
csiph-web