summaryrefslogtreecommitdiff
path: root/drivers/phy
diff options
context:
space:
mode:
authorKamil Debski <k.debski@samsung.com>2013-10-07 18:23:49 +0200
committerChanho Park <chanho61.park@samsung.com>2014-11-18 11:44:52 +0900
commitc9852a94fd231af04113d951b53e5d120cbedeff (patch)
treede4264ae01efe4d73eca8e5cf669b87a351ffa1c /drivers/phy
parentdd74a535d1e8e6146b14fb241104764c574d9c2e (diff)
downloadlinux-3.10-c9852a94fd231af04113d951b53e5d120cbedeff.tar.gz
linux-3.10-c9852a94fd231af04113d951b53e5d120cbedeff.tar.bz2
linux-3.10-c9852a94fd231af04113d951b53e5d120cbedeff.zip
phy: exynos: Change order of initialization of phy in power_on
The order was changed to turn power on first and the disable the physical isolation. Signed-off-by: Kamil Debski <k.debski@samsung.com> Phy driver change - order of init - to be squashed
Diffstat (limited to 'drivers/phy')
-rw-r--r--drivers/phy/phy-exynos4210-usb.c24
-rw-r--r--drivers/phy/phy-exynos4212-usb.c2
2 files changed, 3 insertions, 23 deletions
diff --git a/drivers/phy/phy-exynos4210-usb.c b/drivers/phy/phy-exynos4210-usb.c
index d75a5546327..6102aac2447 100644
--- a/drivers/phy/phy-exynos4210-usb.c
+++ b/drivers/phy/phy-exynos4210-usb.c
@@ -222,19 +222,9 @@ static int exynos4210_power_on(struct uphy_instance *inst)
if (inst->ref_cnt > 1)
return 0;
- exynos4210_isol(inst, 0);
+ /* Order of initialisation is important - first power then isolation */
exynos4210_phy_pwr(inst, 1);
-
- /* Power on the device, as it is necessary for HSIC to work */
- if (inst->cfg->id == EXYNOS4210_HOST) {
- struct uphy_instance *device =
- &drv->uphy_instances[EXYNOS4210_DEVICE];
- device->ref_cnt++;
- if (device->ref_cnt > 1)
- return 0;
- exynos4210_phy_pwr(device, 1);
- exynos4210_isol(device, 0);
- }
+ exynos4210_isol(inst, 0);
return 0;
}
@@ -257,16 +247,6 @@ static int exynos4210_power_off(struct uphy_instance *inst)
exynos4210_phy_pwr(inst, 0);
exynos4210_isol(inst, 1);
- if (inst->cfg->id == EXYNOS4210_HOST) {
- struct uphy_instance *device =
- &drv->uphy_instances[EXYNOS4210_DEVICE];
- device->ref_cnt--;
- if (device->ref_cnt > 0)
- return 0;
- exynos4210_phy_pwr(device, 0);
- exynos4210_isol(device, 1);
- }
-
return 0;
}
diff --git a/drivers/phy/phy-exynos4212-usb.c b/drivers/phy/phy-exynos4212-usb.c
index 80480a4facf..b7de33f6324 100644
--- a/drivers/phy/phy-exynos4212-usb.c
+++ b/drivers/phy/phy-exynos4212-usb.c
@@ -255,8 +255,8 @@ static int exynos4212_power_on(struct uphy_instance *inst)
if (inst->ref_cnt > 1)
return 0;
- exynos4212_isol(inst, 0);
exynos4212_phy_pwr(inst, 1);
+ exynos4212_isol(inst, 0);
/* Power on the device, as it is necessary for HSIC to work */
if (inst->cfg->id == EXYNOS4212_HSIC0) {