Skip to content

Commit 4941c49

Browse files
committed
phy: tegra: xusb: Remove usb3 supply
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=2122414 Tested: Verify USB-A and USB-C are functional on Nvidia Orin board, and no regressions on other platforms. commit 2428787 Author: Wayne Chang <waynec@nvidia.com> Date: Wed Oct 5 16:40:31 2022 +0800 phy: tegra: xusb: Remove usb3 supply Remove redundant codes for getting the vbus supply of usb3 ports because we get and control the vbus supply by the companion usb2 ports Signed-off-by: Wayne Chang <waynec@nvidia.com> Signed-off-by: Haotien Hsu <haotienh@nvidia.com> Reviewed-by: Jon Hunter <jonathanh@nvidia.com> Link: https://lore.kernel.org/r/20221005084031.2154251-1-haotienh@nvidia.com Signed-off-by: Vinod Koul <vkoul@kernel.org> (cherry picked from commit 2428787) Signed-off-by: David Marlin <dmarlin@redhat.com>
1 parent 3e9968b commit 4941c49

File tree

5 files changed

+1
-14
lines changed

5 files changed

+1
-14
lines changed

drivers/phy/tegra/xusb-tegra124.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1652,7 +1652,6 @@ tegra124_usb3_port_map(struct tegra_xusb_port *port)
16521652

16531653
static const struct tegra_xusb_port_ops tegra124_usb3_port_ops = {
16541654
.release = tegra_xusb_usb3_port_release,
1655-
.remove = tegra_xusb_usb3_port_remove,
16561655
.enable = tegra124_usb3_port_enable,
16571656
.disable = tegra124_usb3_port_disable,
16581657
.map = tegra124_usb3_port_map,

drivers/phy/tegra/xusb-tegra186.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1185,7 +1185,6 @@ tegra186_usb3_port_map(struct tegra_xusb_port *port)
11851185

11861186
static const struct tegra_xusb_port_ops tegra186_usb3_port_ops = {
11871187
.release = tegra_xusb_usb3_port_release,
1188-
.remove = tegra_xusb_usb3_port_remove,
11891188
.enable = tegra186_usb3_port_enable,
11901189
.disable = tegra186_usb3_port_disable,
11911190
.map = tegra186_usb3_port_map,

drivers/phy/tegra/xusb-tegra210.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3078,7 +3078,6 @@ tegra210_usb3_port_map(struct tegra_xusb_port *port)
30783078

30793079
static const struct tegra_xusb_port_ops tegra210_usb3_port_ops = {
30803080
.release = tegra_xusb_usb3_port_release,
3081-
.remove = tegra_xusb_usb3_port_remove,
30823081
.enable = tegra210_usb3_port_enable,
30833082
.disable = tegra210_usb3_port_disable,
30843083
.map = tegra210_usb3_port_map,

drivers/phy/tegra/xusb.c

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -954,8 +954,7 @@ static int tegra_xusb_usb3_port_parse_dt(struct tegra_xusb_usb3_port *usb3)
954954
return -EINVAL;
955955
}
956956

957-
usb3->supply = regulator_get(&port->dev, "vbus");
958-
return PTR_ERR_OR_ZERO(usb3->supply);
957+
return 0;
959958
}
960959

961960
static int tegra_xusb_add_usb3_port(struct tegra_xusb_padctl *padctl,
@@ -1012,13 +1011,6 @@ void tegra_xusb_usb3_port_release(struct tegra_xusb_port *port)
10121011
kfree(usb3);
10131012
}
10141013

1015-
void tegra_xusb_usb3_port_remove(struct tegra_xusb_port *port)
1016-
{
1017-
struct tegra_xusb_usb3_port *usb3 = to_usb3_port(port);
1018-
1019-
regulator_put(usb3->supply);
1020-
}
1021-
10221014
static void __tegra_xusb_remove_ports(struct tegra_xusb_padctl *padctl)
10231015
{
10241016
struct tegra_xusb_port *port, *tmp;

drivers/phy/tegra/xusb.h

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -359,7 +359,6 @@ void tegra_xusb_hsic_port_release(struct tegra_xusb_port *port);
359359

360360
struct tegra_xusb_usb3_port {
361361
struct tegra_xusb_port base;
362-
struct regulator *supply;
363362
bool context_saved;
364363
unsigned int port;
365364
bool internal;
@@ -381,7 +380,6 @@ struct tegra_xusb_usb3_port *
381380
tegra_xusb_find_usb3_port(struct tegra_xusb_padctl *padctl,
382381
unsigned int index);
383382
void tegra_xusb_usb3_port_release(struct tegra_xusb_port *port);
384-
void tegra_xusb_usb3_port_remove(struct tegra_xusb_port *port);
385383

386384
struct tegra_xusb_port_ops {
387385
void (*release)(struct tegra_xusb_port *port);

0 commit comments

Comments
 (0)