diff options
author | Bin Meng <bmeng.cn@gmail.com> | 2016-02-02 05:58:00 -0800 |
---|---|---|
committer | Bin Meng <bmeng.cn@gmail.com> | 2016-02-05 12:47:23 +0800 |
commit | 6758a6ccc120dbdc0d1c05d38a5e00fcfdc59fd7 (patch) | |
tree | 53767f894602f087b63b2ee41f5aae5a855dfc4f | |
parent | c52ac3f901f437672d282459cf28d25d4865f305 (diff) | |
download | u-boot-imx-6758a6ccc120dbdc0d1c05d38a5e00fcfdc59fd7.zip u-boot-imx-6758a6ccc120dbdc0d1c05d38a5e00fcfdc59fd7.tar.gz u-boot-imx-6758a6ccc120dbdc0d1c05d38a5e00fcfdc59fd7.tar.bz2 |
net: designware: Use dm_pci_mem_to_phys() in the probe routine
Convert to use native DM PCI API dm_pci_mem_to_phys().
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
-rw-r--r-- | drivers/net/designware.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/net/designware.c b/drivers/net/designware.c index 77b98c9..ca58f34 100644 --- a/drivers/net/designware.c +++ b/drivers/net/designware.c @@ -591,11 +591,9 @@ static int designware_eth_probe(struct udevice *dev) * or via a PCI bridge, fill in platdata before we probe the hardware. */ if (device_is_on_pci_bus(dev)) { - pci_dev_t bdf = dm_pci_get_bdf(dev); - dm_pci_read_config32(dev, PCI_BASE_ADDRESS_0, &iobase); iobase &= PCI_BASE_ADDRESS_MEM_MASK; - iobase = pci_mem_to_phys(bdf, iobase); + iobase = dm_pci_mem_to_phys(dev, iobase); pdata->iobase = iobase; pdata->phy_interface = PHY_INTERFACE_MODE_RMII; |