Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1502610 > unrolled thread
| Started by | Stephen Boyd <stephen.boyd@linaro.org> |
|---|---|
| First post | 2016-10-18 02:20 +0200 |
| Last post | 2016-10-19 16:30 +0200 |
| Articles | 2 — 2 participants |
Back to article view | Back to linux.kernel
[PATCH] extcon: qcom-spmi-misc: Sync the extcon state on interrupt Stephen Boyd <stephen.boyd@linaro.org> - 2016-10-18 02:20 +0200
Re: [PATCH] extcon: qcom-spmi-misc: Sync the extcon state on interrupt Chanwoo Choi <cw00.choi@samsung.com> - 2016-10-19 16:30 +0200
| From | Stephen Boyd <stephen.boyd@linaro.org> |
|---|---|
| Date | 2016-10-18 02:20 +0200 |
| Subject | [PATCH] extcon: qcom-spmi-misc: Sync the extcon state on interrupt |
| Message-ID | <stqim-2Hw-21@gated-at.bofh.it> |
The driver was changed after submission to use the new style APIs
like extcon_set_state(). Unfortunately, that only sets the state,
and doesn't notify any consumers that the cable state has
changed. Use extcon_set_state_sync() here instead so that we
notify cable consumers of the state change. This fixes USB
host-device role switching on the db8074 platform.
Fixes: 38085c987f52 ("extcon: Add support for qcom SPMI PMIC USB id detection hardware")
Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org>
---
drivers/extcon/extcon-qcom-spmi-misc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/extcon/extcon-qcom-spmi-misc.c b/drivers/extcon/extcon-qcom-spmi-misc.c
index ca957a5f4291..b8cde096a808 100644
--- a/drivers/extcon/extcon-qcom-spmi-misc.c
+++ b/drivers/extcon/extcon-qcom-spmi-misc.c
@@ -51,7 +51,7 @@ static void qcom_usb_extcon_detect_cable(struct work_struct *work)
if (ret)
return;
- extcon_set_state(info->edev, EXTCON_USB_HOST, !id);
+ extcon_set_state_sync(info->edev, EXTCON_USB_HOST, !id);
}
static irqreturn_t qcom_usb_irq_handler(int irq, void *dev_id)
--
2.10.0.297.gf6727b0
[toc] | [next] | [standalone]
| From | Chanwoo Choi <cw00.choi@samsung.com> |
|---|---|
| Date | 2016-10-19 16:30 +0200 |
| Message-ID | <su02v-2rf-117@gated-at.bofh.it> |
| In reply to | #1502610 |
Hi Stephen,
On 2016년 10월 18일 09:16, Stephen Boyd wrote:
> The driver was changed after submission to use the new style APIs
> like extcon_set_state(). Unfortunately, that only sets the state,
> and doesn't notify any consumers that the cable state has
> changed. Use extcon_set_state_sync() here instead so that we
> notify cable consumers of the state change. This fixes USB
> host-device role switching on the db8074 platform.
>
> Fixes: 38085c987f52 ("extcon: Add support for qcom SPMI PMIC USB id detection hardware")
> Signed-off-by: Stephen Boyd <stephen.boyd@linaro.org>
> ---
> drivers/extcon/extcon-qcom-spmi-misc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/extcon/extcon-qcom-spmi-misc.c b/drivers/extcon/extcon-qcom-spmi-misc.c
> index ca957a5f4291..b8cde096a808 100644
> --- a/drivers/extcon/extcon-qcom-spmi-misc.c
> +++ b/drivers/extcon/extcon-qcom-spmi-misc.c
> @@ -51,7 +51,7 @@ static void qcom_usb_extcon_detect_cable(struct work_struct *work)
> if (ret)
> return;
>
> - extcon_set_state(info->edev, EXTCON_USB_HOST, !id);
> + extcon_set_state_sync(info->edev, EXTCON_USB_HOST, !id);
> }
>
> static irqreturn_t qcom_usb_irq_handler(int irq, void *dev_id)
>
Applied it.
Best Regards,
Chanwoo Choi
[toc] | [prev] | [standalone]
Back to top | Article view | linux.kernel
csiph-web