Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1548090 > unrolled thread
| Started by | Stephen Boyd <stephen.boyd@linaro.org> |
|---|---|
| First post | 2016-12-29 00:00 +0100 |
| Last post | 2017-01-03 07:50 +0100 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH v6 22/25] usb: chipidea: Drop lock across event_notify during gadget stop Stephen Boyd <stephen.boyd@linaro.org> - 2016-12-29 00:00 +0100
Re: [PATCH v6 22/25] usb: chipidea: Drop lock across event_notify during gadget stop Peter Chen <hzpeterchen@gmail.com> - 2017-01-03 07:50 +0100
| From | Stephen Boyd <stephen.boyd@linaro.org> |
|---|---|
| Date | 2016-12-29 00:00 +0100 |
| Subject | [PATCH v6 22/25] usb: chipidea: Drop lock across event_notify during gadget stop |
| Message-ID | <sTvmq-6sL-39@gated-at.bofh.it> |
The CI_HDRC_CONTROLLER_STOPPED_EVENT may want to call sleeping
APIs similar to how _gadget_stop_activity() may. Let's drop the
lock across the event so that glue drivers can make sleeping
calls.
Cc: Peter Chen <peter.chen@nxp.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org>
---
drivers/usb/chipidea/udc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
index 0db56fb7e9e9..0d532a724d48 100644
--- a/drivers/usb/chipidea/udc.c
+++ b/drivers/usb/chipidea/udc.c
@@ -1793,10 +1793,10 @@ static int ci_udc_stop(struct usb_gadget *gadget)
if (ci->vbus_active) {
hw_device_state(ci, 0);
+ spin_unlock_irqrestore(&ci->lock, flags);
if (ci->platdata->notify_event)
ci->platdata->notify_event(ci,
CI_HDRC_CONTROLLER_STOPPED_EVENT);
- spin_unlock_irqrestore(&ci->lock, flags);
_gadget_stop_activity(&ci->gadget);
spin_lock_irqsave(&ci->lock, flags);
pm_runtime_put(&ci->gadget.dev);
--
2.10.0.297.gf6727b0
[toc] | [next] | [standalone]
| From | Peter Chen <hzpeterchen@gmail.com> |
|---|---|
| Date | 2017-01-03 07:50 +0100 |
| Subject | Re: [PATCH v6 22/25] usb: chipidea: Drop lock across event_notify during gadget stop |
| Message-ID | <sVr4Z-2iY-5@gated-at.bofh.it> |
| In reply to | #1548090 |
On Wed, Dec 28, 2016 at 02:57:08PM -0800, Stephen Boyd wrote:
> The CI_HDRC_CONTROLLER_STOPPED_EVENT may want to call sleeping
> APIs similar to how _gadget_stop_activity() may. Let's drop the
> lock across the event so that glue drivers can make sleeping
> calls.
>
> Cc: Peter Chen <peter.chen@nxp.com>
> Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org>
> ---
> drivers/usb/chipidea/udc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
> index 0db56fb7e9e9..0d532a724d48 100644
> --- a/drivers/usb/chipidea/udc.c
> +++ b/drivers/usb/chipidea/udc.c
> @@ -1793,10 +1793,10 @@ static int ci_udc_stop(struct usb_gadget *gadget)
>
> if (ci->vbus_active) {
> hw_device_state(ci, 0);
> + spin_unlock_irqrestore(&ci->lock, flags);
> if (ci->platdata->notify_event)
> ci->platdata->notify_event(ci,
> CI_HDRC_CONTROLLER_STOPPED_EVENT);
> - spin_unlock_irqrestore(&ci->lock, flags);
> _gadget_stop_activity(&ci->gadget);
> spin_lock_irqsave(&ci->lock, flags);
> pm_runtime_put(&ci->gadget.dev);
> --
Acked-by: Peter Chen <peter.chen@nxp.com>
--
Best Regards,
Peter Chen
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web