diff options
author | Tom Rini <trini@konsulko.com> | 2017-02-08 16:24:44 -0500 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2017-02-08 16:24:44 -0500 |
commit | 21342d4aed6c77a4aa7a5b2579b3c23e21aea31a (patch) | |
tree | 279c781bdcbe697257ff86714fa0355bcd92fd19 /drivers/net/designware.c | |
parent | 7582ddce132390fba10822c5977cd1ab532bb1eb (diff) | |
parent | f11a0af713a714ee2efcd810dd81c6dfd59381aa (diff) | |
download | u-boot-imx-21342d4aed6c77a4aa7a5b2579b3c23e21aea31a.zip u-boot-imx-21342d4aed6c77a4aa7a5b2579b3c23e21aea31a.tar.gz u-boot-imx-21342d4aed6c77a4aa7a5b2579b3c23e21aea31a.tar.bz2 |
Merge git://git.denx.de/u-boot-dm
Diffstat (limited to 'drivers/net/designware.c')
-rw-r--r-- | drivers/net/designware.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/designware.c b/drivers/net/designware.c index e207bc6..eee4e09 100644 --- a/drivers/net/designware.c +++ b/drivers/net/designware.c @@ -728,7 +728,8 @@ int designware_eth_ofdata_to_platdata(struct udevice *dev) pdata->iobase = dev_get_addr(dev); pdata->phy_interface = -1; - phy_mode = fdt_getprop(gd->fdt_blob, dev->of_offset, "phy-mode", NULL); + phy_mode = fdt_getprop(gd->fdt_blob, dev_of_offset(dev), "phy-mode", + NULL); if (phy_mode) pdata->phy_interface = phy_get_interface_by_name(phy_mode); if (pdata->phy_interface == -1) { @@ -737,19 +738,19 @@ int designware_eth_ofdata_to_platdata(struct udevice *dev) } pdata->max_speed = 0; - cell = fdt_getprop(gd->fdt_blob, dev->of_offset, "max-speed", NULL); + cell = fdt_getprop(gd->fdt_blob, dev_of_offset(dev), "max-speed", NULL); if (cell) pdata->max_speed = fdt32_to_cpu(*cell); #ifdef CONFIG_DM_GPIO - if (fdtdec_get_bool(gd->fdt_blob, dev->of_offset, + if (fdtdec_get_bool(gd->fdt_blob, dev_of_offset(dev), "snps,reset-active-low")) reset_flags |= GPIOD_ACTIVE_LOW; ret = gpio_request_by_name(dev, "snps,reset-gpio", 0, &priv->reset_gpio, reset_flags); if (ret == 0) { - ret = fdtdec_get_int_array(gd->fdt_blob, dev->of_offset, + ret = fdtdec_get_int_array(gd->fdt_blob, dev_of_offset(dev), "snps,reset-delays-us", dw_pdata->reset_delays, 3); } else if (ret == -ENOENT) { ret = 0; |