summaryrefslogtreecommitdiffstats
path: root/drivers/usb/musb
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2022-12-14 13:35:08 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2023-01-10 15:43:46 +0100
commite70b9d7a74698f1374244b2251216428db920aed (patch)
treeb8091531241075d04501751b5236ab54afbe48c2 /drivers/usb/musb
parent12763d0fe56899d3729d0e6755446ed7c740a88a (diff)
downloadbarebox-e70b9d7a74698f1374244b2251216428db920aed.tar.gz
barebox-e70b9d7a74698f1374244b2251216428db920aed.tar.xz
Rename device_d::device_node to device_d::of_node
Linux struct device has the member of_node for the device_node pointer. Rename this in barebox accordingly to minimize the necessary changes when porting Linux code. This was done with the semantic patch: @@ struct device_d E; @@ - E.device_node + E.of_node @@ struct device_d *E; @@ - E->device_node + E->of_node Plus some manual adjustments. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> Link: https://lore.barebox.org/20221214123512.189688-2-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/usb/musb')
-rw-r--r--drivers/usb/musb/musb_am335x.c2
-rw-r--r--drivers/usb/musb/musb_dsps.c4
-rw-r--r--drivers/usb/musb/phy-am335x-control.c2
-rw-r--r--drivers/usb/musb/phy-am335x.c2
4 files changed, 5 insertions, 5 deletions
diff --git a/drivers/usb/musb/musb_am335x.c b/drivers/usb/musb/musb_am335x.c
index 03f30d92aa..14307c95d5 100644
--- a/drivers/usb/musb/musb_am335x.c
+++ b/drivers/usb/musb/musb_am335x.c
@@ -7,7 +7,7 @@ static int am335x_child_probe(struct device_d *dev)
{
int ret;
- ret = of_platform_populate(dev->device_node, NULL, dev);
+ ret = of_platform_populate(dev->of_node, NULL, dev);
if (ret)
return ret;
diff --git a/drivers/usb/musb/musb_dsps.c b/drivers/usb/musb/musb_dsps.c
index ee0215024a..397a5792e2 100644
--- a/drivers/usb/musb/musb_dsps.c
+++ b/drivers/usb/musb/musb_dsps.c
@@ -264,7 +264,7 @@ static int get_musb_port_mode(struct device_d *dev)
{
enum usb_dr_mode mode;
- mode = of_usb_get_dr_mode(dev->device_node, NULL);
+ mode = of_usb_get_dr_mode(dev->of_node, NULL);
switch (mode) {
case USB_DR_MODE_HOST:
return MUSB_PORT_MODE_HOST;
@@ -302,7 +302,7 @@ static int dsps_probe(struct device_d *dev)
struct resource *iores[2];
struct musb_hdrc_platform_data *pdata;
struct musb_hdrc_config *config;
- struct device_node *dn = dev->device_node;
+ struct device_node *dn = dev->of_node;
const struct dsps_musb_wrapper *wrp;
struct device_node *phy_node;
struct device_d *phy_dev;
diff --git a/drivers/usb/musb/phy-am335x-control.c b/drivers/usb/musb/phy-am335x-control.c
index bc0f6b9485..2cdf8a2105 100644
--- a/drivers/usb/musb/phy-am335x-control.c
+++ b/drivers/usb/musb/phy-am335x-control.c
@@ -108,7 +108,7 @@ struct phy_control *am335x_get_phy_control(struct device_d *dev)
struct device_node *node;
struct am335x_control_usb *ctrl_usb;
- node = of_parse_phandle(dev->device_node, "ti,ctrl_mod", 0);
+ node = of_parse_phandle(dev->of_node, "ti,ctrl_mod", 0);
if (!node)
return ERR_PTR(-ENOENT);
diff --git a/drivers/usb/musb/phy-am335x.c b/drivers/usb/musb/phy-am335x.c
index 67787cfec3..aa0aec70d4 100644
--- a/drivers/usb/musb/phy-am335x.c
+++ b/drivers/usb/musb/phy-am335x.c
@@ -43,7 +43,7 @@ static int am335x_phy_probe(struct device_d *dev)
goto err_release;
}
- am_usbphy->id = of_alias_get_id(dev->device_node, "phy");
+ am_usbphy->id = of_alias_get_id(dev->of_node, "phy");
if (am_usbphy->id < 0) {
dev_err(dev, "Missing PHY id: %d\n", am_usbphy->id);
ret = am_usbphy->id;