usb: dwc2: Rename dwc2_core_reset()
authorJohn Youn <John.Youn@synopsys.com>
Thu, 17 Dec 2015 19:15:49 +0000 (11:15 -0800)
committerFelipe Balbi <balbi@ti.com>
Tue, 22 Dec 2015 17:55:21 +0000 (11:55 -0600)
Renamed dwc2_core_reset() to dwc2_core_reset_and_force_dr_mode(). This
describes what it is doing more accurately. This is in preparation of
introducing a plain dwc2_core_reset() function that only performs the
reset and doesn't force the mode.

Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/dwc2/core.c
drivers/usb/dwc2/core.h
drivers/usb/dwc2/platform.c

index 62505068abf2e2a90daf38807ca3e0d73c5e6cfa..eb291c9e3c169e2d55c71e025b8ff940aabffb01 100644 (file)
@@ -481,7 +481,7 @@ static void dwc2_init_fs_ls_pclk_sel(struct dwc2_hsotg *hsotg)
  * Do core a soft reset of the core.  Be careful with this because it
  * resets all the internal state machines of the core.
  */
-int dwc2_core_reset(struct dwc2_hsotg *hsotg)
+int dwc2_core_reset_and_force_dr_mode(struct dwc2_hsotg *hsotg)
 {
        u32 greset;
        int count = 0;
@@ -561,7 +561,7 @@ static int dwc2_fs_phy_init(struct dwc2_hsotg *hsotg, bool select_phy)
                        dwc2_writel(usbcfg, hsotg->regs + GUSBCFG);
 
                        /* Reset after a PHY select */
-                       retval = dwc2_core_reset(hsotg);
+                       retval = dwc2_core_reset_and_force_dr_mode(hsotg);
 
                        if (retval) {
                                dev_err(hsotg->dev,
@@ -640,7 +640,7 @@ static int dwc2_hs_phy_init(struct dwc2_hsotg *hsotg, bool select_phy)
                dwc2_writel(usbcfg, hsotg->regs + GUSBCFG);
 
                /* Reset after setting the PHY parameters */
-               retval = dwc2_core_reset(hsotg);
+               retval = dwc2_core_reset_and_force_dr_mode(hsotg);
                if (retval) {
                        dev_err(hsotg->dev,
                                "%s: Reset failed, aborting", __func__);
@@ -805,7 +805,7 @@ int dwc2_core_init(struct dwc2_hsotg *hsotg, bool initial_setup)
         * needed to in order to properly detect various parameters).
         */
        if (!initial_setup) {
-               retval = dwc2_core_reset(hsotg);
+               retval = dwc2_core_reset_and_force_dr_mode(hsotg);
                if (retval) {
                        dev_err(hsotg->dev, "%s(): Reset failed, aborting\n",
                                        __func__);
index cbece3a68c30edc6f2848caf1ace801bb6ce3f79..d1989c68c728a6418a45f986665db8e3ee1425b5 100644 (file)
@@ -880,7 +880,7 @@ enum dwc2_halt_status {
  * The following functions support initialization of the core driver component
  * and the DWC_otg controller
  */
-extern int dwc2_core_reset(struct dwc2_hsotg *hsotg);
+extern int dwc2_core_reset_and_force_dr_mode(struct dwc2_hsotg *hsotg);
 extern void dwc2_core_host_init(struct dwc2_hsotg *hsotg);
 extern int dwc2_enter_hibernation(struct dwc2_hsotg *hsotg);
 extern int dwc2_exit_hibernation(struct dwc2_hsotg *hsotg, bool restore);
index a72302d740dde492025a10a069ddd5ec4eed433a..8bd7315a06c900048b791fe44c6dcdfafbdcd1ae 100644 (file)
@@ -460,7 +460,7 @@ static int dwc2_driver_probe(struct platform_device *dev)
         * Reset before dwc2_get_hwparams() then it could get power-on real
         * reset value form registers.
         */
-       dwc2_core_reset(hsotg);
+       dwc2_core_reset_and_force_dr_mode(hsotg);
 
        /* Detect config values from hardware */
        retval = dwc2_get_hwparams(hsotg);
This page took 0.029885 seconds and 5 git commands to generate.