Skip to contentSkip to conversation

usb: chipidea: fixes for v5.7

PATCH In review Peter Chen 3 participants 5 messages May 7, 2020

Subsystems (2)
lore
Share & tools
lore

Peter Chen

author maintainer
#0 lore raw

cover usb: chipidea: fixes for v5.7

From: Peter Chen <[email protected]>

Bryan O'Donoghue (1):
usb: chipidea: msm: Ensure proper controller reset using role switch
API

 drivers/usb/chipidea/ci_hdrc_msm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
2.17.1
author maintainer
#1 lore raw

PATCH 1/1 usb: chipidea: msm: Ensure proper controller reset using role switch API

From: Bryan O'Donoghue <[email protected]>

Currently we check to make sure there is no error state on the extcon handle for VBUS when writing to the HS_PHY_GENCONFIG_2 register. When using the USB role-switch API we still need to write to this register absent an extcon handle.

This patch makes the appropriate update to ensure the write happens if role-switching is true.

Fixes 05559f10ed79 ("usb: chipidea: add role switch class support")
---
 drivers/usb/chipidea/ci_hdrc_msm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/chipidea/ci_hdrc_msm.c +1 -1
index af648ba6544d..46105457e1ca 100644
@@ -114,7 +114,7 @@ static int ci_hdrc_msm_notify_event(struct ci_hdrc *ci, unsigned event)
 			hw_write_id_reg(ci, HS_PHY_GENCONFIG_2,
 					HS_PHY_ULPI_TX_PKT_EN_CLR_FIX, 0);
 
-		if (!IS_ERR(ci->platdata->vbus_extcon.edev)) {
+		if (!IS_ERR(ci->platdata->vbus_extcon.edev) || ci->role_switch) {
 			hw_write_id_reg(ci, HS_PHY_GENCONFIG_2,
 					HS_PHY_SESS_VLD_CTRL_EN,
 					HS_PHY_SESS_VLD_CTRL_EN);
Signature · 1 line
2.17.1
maintainer
#2 lore raw

Re: [PATCH 1/1] usb: chipidea: msm: Ensure proper controller reset using role switch API

Quoted 7 lines · Peter Chen

From: Bryan O'Donoghue <[email protected]>

Currently we check to make sure there is no error state on the extcon handle for VBUS when writing to the HS_PHY_GENCONFIG_2 register. When using the USB role-switch API we still need to write to this register absent an extcon handle.

Quoted 6 lines

This patch makes the appropriate update to ensure the write happens if role-switching is true.

Fixes 05559f10ed79 ("usb: chipidea: add role switch class support")
Cc Peter Chen <[email protected]>

No blank line needed, and you can drop your own Cc: in the patch :)

I'll edit it by hand...

greg k-h

maintainer
#3 lore raw

Re: [PATCH 1/1] usb: chipidea: msm: Ensure proper controller reset using role switch API

In reply to Peter Chen
Quoted 11 lines · Peter Chen

From: Bryan O'Donoghue <[email protected]>

Currently we check to make sure there is no error state on the extcon handle for VBUS when writing to the HS_PHY_GENCONFIG_2 register. When using the USB role-switch API we still need to write to this register absent an extcon handle.

This patch makes the appropriate update to ensure the write happens if role-switching is true.

Fixes 05559f10ed79 ("usb: chipidea: add role switch class support")

This should also go do stable kernels, I'll mark that...

#4 lore raw

RE: [PATCH 1/1] usb: chipidea: msm: Ensure proper controller reset using role switch API

Quoted 10 lines · Peter Chen
Quoted 7 lines

From: Bryan O'Donoghue <[email protected]>

Currently we check to make sure there is no error state on the extcon handle for VBUS when writing to the HS_PHY_GENCONFIG_2 register. When using the USB role-switch API we still need to write to this register absent an extcon handle.

Quoted 6 lines
Quoted 4 lines

This patch makes the appropriate update to ensure the write happens if role-switching is true.

Fixes 05559f10ed79 ("usb: chipidea: add role switch class support")

This should also go do stable kernels, I'll mark that...

Thanks, Greg.

Peter