arm: tegra: usb_phy: Separate the consumer supply
Penny Chiu [Wed, 25 Jul 2012 07:35:25 +0000 (15:35 +0800)]
Add usb host controller device names for avdd_usb
consumer supply. This change will make all usb
host controller devices have separate regulator
debugfs.

Bug 946361

Change-Id: I8f2a49bffc4623eac2e3f71333b602fb7a6caf7d
Signed-off-by: Penny Chiu <pchiu@nvidia.com>

arch/arm/mach-tegra/board-cardhu-power.c
arch/arm/mach-tegra/usb_phy.c

index ace103f..ae355a3 100644 (file)
@@ -538,7 +538,10 @@ static struct regulator_consumer_supply fixed_reg_en_3v3_sys_supply[] = {
        REGULATOR_SUPPLY("hvdd_pex_pmu", NULL),
        REGULATOR_SUPPLY("avdd_hdmi", NULL),
        REGULATOR_SUPPLY("vpp_fuse", NULL),
-       REGULATOR_SUPPLY("avdd_usb", NULL),
+       REGULATOR_SUPPLY("avdd_usb", "tegra-udc.0"),
+       REGULATOR_SUPPLY("avdd_usb", "tegra-ehci.0"),
+       REGULATOR_SUPPLY("avdd_usb", "tegra-ehci.1"),
+       REGULATOR_SUPPLY("avdd_usb", "tegra-ehci.2"),
        REGULATOR_SUPPLY("vdd_ddr_rx", NULL),
        REGULATOR_SUPPLY("vcore_nand", NULL),
        REGULATOR_SUPPLY("hvdd_sata", NULL),
index 80a3337..aed8ec2 100644 (file)
@@ -276,7 +276,7 @@ struct tegra_usb_phy *tegra_usb_phy_open(struct platform_device *pdev)
                goto fail_io;
        }
 
-       phy->vdd_reg = regulator_get(NULL, "avdd_usb");
+       phy->vdd_reg = regulator_get(&pdev->dev, "avdd_usb");
        if (IS_ERR_OR_NULL(phy->vdd_reg)) {
                ERR("inst:[%d] couldn't get regulator avdd_usb: %ld\n",
                        phy->inst, PTR_ERR(phy->vdd_reg));