Re: [PATCH] chipidea: core: Move hw_phymode_configure() into probe
Fabio Estevam fabio.este...@freescale.com writes: Currently hw_phymode_configure() is located inside hw_device_reset(), which is only called by chipidea udc driver. When operating in host mode, we also need to call hw_phymode_configure() in order to properly configure the PHY mode, so move this function into probe. After this change, USB Host1 port on mx53qsb board is functional. Signed-off-by: Fabio Estevam fabio.este...@freescale.com Applied and pushed, thanks! -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH] chipidea: core: Move hw_phymode_configure() into probe
Fabio Estevam fabio.este...@freescale.com writes: Currently hw_phymode_configure() is located inside hw_device_reset(), which is only called by chipidea udc driver. When operating in host mode, we also need to call hw_phymode_configure() in order to properly configure the PHY mode, so move this function into probe. After this change, USB Host1 port on mx53qsb board is functional. nice catch. With this patch and the vbus supply patch, the 2 ports of my imx53qsb are working here too. Thanks. Signed-off-by: Fabio Estevam fabio.este...@freescale.com Tested-by: Arnaud Patard arnaud.pat...@rtp-net.org Arnaud -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH] chipidea: core: Move hw_phymode_configure() into probe
Currently hw_phymode_configure() is located inside hw_device_reset(), which is only called by chipidea udc driver. When operating in host mode, we also need to call hw_phymode_configure() in order to properly configure the PHY mode, so move this function into probe. After this change, USB Host1 port on mx53qsb board is functional. Signed-off-by: Fabio Estevam fabio.este...@freescale.com --- drivers/usb/chipidea/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c index a5df24c..a5b3774 100644 --- a/drivers/usb/chipidea/core.c +++ b/drivers/usb/chipidea/core.c @@ -264,8 +264,6 @@ int hw_device_reset(struct ci_hdrc *ci, u32 mode) while (hw_read(ci, OP_USBCMD, USBCMD_RST)) udelay(10); /* not RTOS friendly */ - hw_phymode_configure(ci); - if (ci-platdata-notify_event) ci-platdata-notify_event(ci, CI_HDRC_CONTROLLER_RESET_EVENT); @@ -457,6 +455,8 @@ static int ci_hdrc_probe(struct platform_device *pdev) if (!ci-platdata-phy_mode) ci-platdata-phy_mode = of_usb_get_phy_mode(dev-of_node); + hw_phymode_configure(ci); + if (!ci-platdata-dr_mode) ci-platdata-dr_mode = of_usb_get_dr_mode(dev-of_node); -- 1.8.1.2 -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: [PATCH] chipidea: core: Move hw_phymode_configure() into probe
On Thu, Jul 25, 2013 at 06:20:34PM -0300, Fabio Estevam wrote: Currently hw_phymode_configure() is located inside hw_device_reset(), which is only called by chipidea udc driver. When operating in host mode, we also need to call hw_phymode_configure() in order to properly configure the PHY mode, so move this function into probe. After this change, USB Host1 port on mx53qsb board is functional. Signed-off-by: Fabio Estevam fabio.este...@freescale.com --- drivers/usb/chipidea/core.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c index a5df24c..a5b3774 100644 --- a/drivers/usb/chipidea/core.c +++ b/drivers/usb/chipidea/core.c @@ -264,8 +264,6 @@ int hw_device_reset(struct ci_hdrc *ci, u32 mode) while (hw_read(ci, OP_USBCMD, USBCMD_RST)) udelay(10); /* not RTOS friendly */ - hw_phymode_configure(ci); - if (ci-platdata-notify_event) ci-platdata-notify_event(ci, CI_HDRC_CONTROLLER_RESET_EVENT); @@ -457,6 +455,8 @@ static int ci_hdrc_probe(struct platform_device *pdev) if (!ci-platdata-phy_mode) ci-platdata-phy_mode = of_usb_get_phy_mode(dev-of_node); + hw_phymode_configure(ci); + if (!ci-platdata-dr_mode) ci-platdata-dr_mode = of_usb_get_dr_mode(dev-of_node); -- 1.8.1.2 At old version (not upsteamed), Michael did put it at probe, I don't know why move it to hw_device_reset later. Talked with IC guys, usbcmd.rst will not reset PORTSC_PTS at chipidea core IP default, unless some vendors changes this behaviour(very low possibilities). So, it is safe to put it at probe, unless we need consider above uncertain change. Reviewed-by: Peter Chen peter.c...@freescale.com -- Best Regards, Peter Chen -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html