usb: chipidea: imx: add missing USB PHY DPDM wakeup setting
authorXu Yang <xu.yang_2@nxp.com>
Wed, 17 May 2023 08:19:07 +0000 (16:19 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 13 Jun 2023 10:05:42 +0000 (12:05 +0200)
USB PHY DPDM wakeup bit is enabled by default, when USB wakeup
is not required(/sys/.../wakeup is disabled), this bit should be
disabled, otherwise we will have unexpected wakeup if do USB device
connect/disconnect while system sleep.
This bit can be enabled for both host and device mode.

Signed-off-by: Li Jun <jun.li@nxp.com>
Signed-off-by: Xu Yang <xu.yang_2@nxp.com>
Acked-by: Peter Chen <peter.chen@kernel.org>
Message-ID: <20230517081907.3410465-3-xu.yang_2@nxp.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/chipidea/usbmisc_imx.c

index 9566022a2183146cd34bc205d20c5569b538de93..9ee9621e2ccca9766189f9d61633a8882de7efd1 100644 (file)
 #define TXVREFTUNE0_MASK               (0xf << 20)
 
 #define MX6_USB_OTG_WAKEUP_BITS (MX6_BM_WAKEUP_ENABLE | MX6_BM_VBUS_WAKEUP | \
-                                MX6_BM_ID_WAKEUP)
+                                MX6_BM_ID_WAKEUP | MX6SX_BM_DPDM_WAKEUP_EN)
 
 struct usbmisc_ops {
        /* It's called once when probe a usb device */