[U-Boot] [PATCH 6/8] drivers: serial: Remove special handling for pci uart in the ns16550 driver

Bin Meng bmeng.cn at gmail.com
Sat Aug 15 09:07:48 CEST 2015


Now we have a dedicated PCI UART driver, remove previous special
handling for PCI UART in the ns16550 driver.

Signed-off-by: Bin Meng <bmeng.cn at gmail.com>
---

 drivers/serial/ns16550.c | 31 -------------------------------
 1 file changed, 31 deletions(-)

diff --git a/drivers/serial/ns16550.c b/drivers/serial/ns16550.c
index c8a77e2..8a5db49 100644
--- a/drivers/serial/ns16550.c
+++ b/drivers/serial/ns16550.c
@@ -363,38 +363,7 @@ int ns16550_serial_ofdata_to_platdata(struct udevice *dev)
 	struct ns16550_platdata *plat = dev->platdata;
 	fdt_addr_t addr;
 
-	/* try Processor Local Bus device first */
 	addr = fdtdec_get_addr(gd->fdt_blob, dev->of_offset, "reg");
-#ifdef CONFIG_PCI
-	if (addr == FDT_ADDR_T_NONE) {
-		/* then try pci device */
-		struct fdt_pci_addr pci_addr;
-		u32 bar;
-		int ret;
-
-		/* we prefer to use a memory-mapped register */
-		ret = fdtdec_get_pci_addr(gd->fdt_blob, dev->of_offset,
-					  FDT_PCI_SPACE_MEM32, "reg",
-					  &pci_addr);
-		if (ret) {
-			/* try if there is any i/o-mapped register */
-			ret = fdtdec_get_pci_addr(gd->fdt_blob,
-						  dev->of_offset,
-						  FDT_PCI_SPACE_IO,
-						  "reg", &pci_addr);
-			if (ret)
-				return ret;
-		}
-
-		ret = fdtdec_get_pci_bar32(gd->fdt_blob, dev->of_offset,
-					   &pci_addr, &bar);
-		if (ret)
-			return ret;
-
-		addr = bar;
-	}
-#endif
-
 	if (addr == FDT_ADDR_T_NONE)
 		return -EINVAL;
 
-- 
1.8.2.1



More information about the U-Boot mailing list