sunxi: usb: Rename sunxi_usbc_foo functions to sunxi_usb_phy_bar

Rename the sunxi_usbc_foo functions to sunxi_usb_phy_bar to make it clear
that these are usb-phy functions. Also change the verbs & nouns in the suffix
to match the verbs & nouns used in the Linux kernels generic phy framework.

This patch purely renames things, it contains no functional changes.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Acked-by: Ian Campbell <ijc@hellion.org.uk>
diff --git a/drivers/usb/host/ehci-sunxi.c b/drivers/usb/host/ehci-sunxi.c
index 5de20f9..b6fa538 100644
--- a/drivers/usb/host/ehci-sunxi.c
+++ b/drivers/usb/host/ehci-sunxi.c
@@ -1,7 +1,8 @@
 /*
- * Copyright (C) 2014 Roman Byshko
+ * Sunxi ehci glue
  *
- * Roman Byshko <rbyshko@gmail.com>
+ * Copyright (C) 2015 Hans de Goede <hdegoede@redhat.com>
+ * Copyright (C) 2014 Roman Byshko <rbyshko@gmail.com>
  *
  * Based on code from
  * Allwinner Technology Co., Ltd. <www.allwinnertech.com>
@@ -21,7 +22,7 @@
 	struct sunxi_ccm_reg *ccm = (struct sunxi_ccm_reg *)SUNXI_CCM_BASE;
 	int ahb_gate_offset, err;
 
-	err = sunxi_usbc_request_resources(index + 1);
+	err = sunxi_usb_phy_probe(index + 1);
 	if (err)
 		return err;
 
@@ -32,8 +33,8 @@
 	setbits_le32(&ccm->ahb_reset0_cfg, 1 << ahb_gate_offset);
 #endif
 
-	sunxi_usbc_enable(index + 1);
-	sunxi_usbc_vbus_enable(index + 1);
+	sunxi_usb_phy_init(index + 1);
+	sunxi_usb_phy_power_on(index + 1);
 
 	if (index == 0)
 		*hccr = (void *)SUNXI_USB1_BASE;
@@ -55,8 +56,8 @@
 	struct sunxi_ccm_reg *ccm = (struct sunxi_ccm_reg *)SUNXI_CCM_BASE;
 	int ahb_gate_offset;
 
-	sunxi_usbc_vbus_disable(index + 1);
-	sunxi_usbc_disable(index + 1);
+	sunxi_usb_phy_power_off(index + 1);
+	sunxi_usb_phy_exit(index + 1);
 
 	ahb_gate_offset = index ? AHB_GATE_OFFSET_USB_EHCI1 :
 				  AHB_GATE_OFFSET_USB_EHCI0;
@@ -65,5 +66,5 @@
 #endif
 	clrbits_le32(&ccm->ahb_gate0, 1 << ahb_gate_offset);
 
-	return sunxi_usbc_free_resources(index + 1);
+	return sunxi_usb_phy_remove(index + 1);
 }
diff --git a/drivers/usb/musb-new/musb_uboot.c b/drivers/usb/musb-new/musb_uboot.c
index 7d90ebc..4d0213a5 100644
--- a/drivers/usb/musb-new/musb_uboot.c
+++ b/drivers/usb/musb-new/musb_uboot.c
@@ -195,12 +195,12 @@
 	 * when clearing reset on low-speed devices, temporary disable
 	 * squelch detection to work around this.
 	 */
-	sunxi_usbc_enable_squelch_detect(0, 0);
+	sunxi_usb_phy_enable_squelch_detect(0, 0);
 #endif
 	power = musb_readb(mbase, MUSB_POWER);
 	musb_writeb(mbase, MUSB_POWER, ~MUSB_POWER_RESET & power);
 #ifdef CONFIG_ARCH_SUNXI
-	sunxi_usbc_enable_squelch_detect(0, 1);
+	sunxi_usb_phy_enable_squelch_detect(0, 1);
 #endif
 	host->isr(0, host);
 	host_speed = (musb_readb(mbase, MUSB_POWER) & MUSB_POWER_HSMODE) ?
diff --git a/drivers/usb/musb-new/sunxi.c b/drivers/usb/musb-new/sunxi.c
index e3c6d6a..5a9d39c 100644
--- a/drivers/usb/musb-new/sunxi.c
+++ b/drivers/usb/musb-new/sunxi.c
@@ -214,7 +214,7 @@
 
 	if (is_host_enabled(musb)) {
 		/* port power on */
-		sunxi_usbc_vbus_enable(0);
+		sunxi_usb_phy_power_on(0);
 	}
 }
 
@@ -226,7 +226,7 @@
 
 	/* Put the controller back in a pristane state for "usb reset" */
 	if (musb->is_active) {
-		sunxi_usbc_disable(0);
+		sunxi_usb_phy_exit(0);
 #ifdef CONFIG_SUNXI_GEN_SUN6I
 		clrbits_le32(&ccm->ahb_reset0_cfg, 1 << AHB_GATE_OFFSET_USB0);
 #endif
@@ -238,7 +238,7 @@
 #ifdef CONFIG_SUNXI_GEN_SUN6I
 		setbits_le32(&ccm->ahb_reset0_cfg, 1 << AHB_GATE_OFFSET_USB0);
 #endif
-		sunxi_usbc_enable(0);
+		sunxi_usb_phy_init(0);
 		musb->is_active = 0;
 	}
 }
@@ -250,15 +250,15 @@
 
 	pr_debug("%s():\n", __func__);
 
-	err = sunxi_usbc_request_resources(0);
+	err = sunxi_usb_phy_probe(0);
 	if (err)
 		return err;
 
 	if (is_host_enabled(musb)) {
-		err = sunxi_usbc_vbus_detect(0);
+		err = sunxi_usb_phy_vbus_detect(0);
 		if (err) {
 			eprintf("Error: A charger is plugged into the OTG\n");
-			sunxi_usbc_free_resources(0);
+			sunxi_usb_phy_remove(0);
 			return -EIO;
 		}
 	}
@@ -269,7 +269,7 @@
 #ifdef CONFIG_SUNXI_GEN_SUN6I
 	setbits_le32(&ccm->ahb_reset0_cfg, 1 << AHB_GATE_OFFSET_USB0);
 #endif
-	sunxi_usbc_enable(0);
+	sunxi_usb_phy_init(0);
 
 	USBC_ConfigFIFO_Base();
 	USBC_EnableDpDmPullUp(musb->mregs);
@@ -293,10 +293,10 @@
 
 	USBC_DisableDpDmPullUp(musb->mregs);
 	USBC_DisableIdPullUp(musb->mregs);
-	sunxi_usbc_vbus_disable(0);
-	sunxi_usbc_disable(0);
+	sunxi_usb_phy_power_off(0);
+	sunxi_usb_phy_exit(0);
 
-	return sunxi_usbc_free_resources(0);
+	return sunxi_usb_phy_remove(0);
 }
 
 const struct musb_platform_ops sunxi_musb_ops = {