diff mbox series

[1/1] USB: PHY: JZ4770: Fix static checker warning.

Message ID 20200825081654.18186-2-zhouyanjie@wanyeetech.com (mailing list archive)
State Mainlined
Commit 41dd70b368278f3ac789bed25bc810f764e14bbf
Headers show
Series Fix static checker warning. | expand

Commit Message

Zhou Yanjie Aug. 25, 2020, 8:16 a.m. UTC
The commit 2a6c0b82e651 ("USB: PHY: JZ4770: Add support for new
Ingenic SoCs.") introduced the initialization function for different
chips, but left the relevant code involved in the resetting process
in the original function, resulting in uninitialized variable calls.

Fixes: 2a6c0b82e651 ("USB: PHY: JZ4770: Add support for new
Ingenic SoCs.").

Signed-off-by: 周琰杰 (Zhou Yanjie) <zhouyanjie@wanyeetech.com>
---
 drivers/usb/phy/phy-jz4770.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Felipe Balbi Aug. 27, 2020, 1:06 p.m. UTC | #1
周琰杰 (Zhou Yanjie) <zhouyanjie@wanyeetech.com> writes:

> The commit 2a6c0b82e651 ("USB: PHY: JZ4770: Add support for new
> Ingenic SoCs.") introduced the initialization function for different
> chips, but left the relevant code involved in the resetting process
> in the original function, resulting in uninitialized variable calls.
>
> Fixes: 2a6c0b82e651 ("USB: PHY: JZ4770: Add support for new
> Ingenic SoCs.").

These two lines here, they should be one line :-)

For the Fixes: line, you shouldn't worry about the 72-char limit. Also,
when resending, don't add a blank line between Fixes and Signed-off-by
and since this is a bug fix, it seems like Cc: stable is in order.
diff mbox series

Patch

diff --git a/drivers/usb/phy/phy-jz4770.c b/drivers/usb/phy/phy-jz4770.c
index d4ee3cb721ea..f6d3731581eb 100644
--- a/drivers/usb/phy/phy-jz4770.c
+++ b/drivers/usb/phy/phy-jz4770.c
@@ -176,6 +176,7 @@  static int ingenic_usb_phy_init(struct usb_phy *phy)
 
 	/* Wait for PHY to reset */
 	usleep_range(30, 300);
+	reg = readl(priv->base + REG_USBPCR_OFFSET);
 	writel(reg & ~USBPCR_POR, priv->base + REG_USBPCR_OFFSET);
 	usleep_range(300, 1000);