[coreboot-gerrit] New patch to review for coreboot: drivers/uart/oxpcie_early.c: remove uart_fill_lb()

Martin Roth (martinroth@google.com) gerrit at coreboot.org
Mon Dec 26 20:15:44 CET 2016


Martin Roth (martinroth at google.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/17966

-gerrit

commit 07117304b797b41359c6641e6b9875ce38cfebcf
Author: Martin Roth <martinroth at google.com>
Date:   Sun Dec 18 11:02:56 2016 -0700

    drivers/uart/oxpcie_early.c: remove uart_fill_lb()
    
    uart_fill_lb() was added to drivers/uart/uart8250mem.c, so when the
    Oxford OXPCIe952 Kconfig option is enabled, we were getting an error.
    "multiple definition of `uart_fill_lb'"
    
    The new version of uart_fill_lb sets the regwidth depending on the
    Kconfig symbol DRIVERS_UART_8250MEM_32, so if that's selected, don't
    give DRIVERS_UART_OXPCIE as a choice.
    
    Change-Id: Ife24ab390553b10b2266809595c2e06463de708c
    Signed-off-by: Martin Roth <martinroth at google.com>
---
 src/drivers/uart/Kconfig        |  2 +-
 src/drivers/uart/oxpcie_early.c | 14 --------------
 2 files changed, 1 insertion(+), 15 deletions(-)

diff --git a/src/drivers/uart/Kconfig b/src/drivers/uart/Kconfig
index 518e7ca..54f591d 100644
--- a/src/drivers/uart/Kconfig
+++ b/src/drivers/uart/Kconfig
@@ -47,7 +47,7 @@ config HAVE_UART_SPECIAL
 config DRIVERS_UART_OXPCIE
 	bool "Oxford OXPCIe952"
 	default n
-	depends on PCI
+	depends on PCI && !DRIVERS_UART_8250MEM_32
 	select DRIVERS_UART_8250MEM
 	select EARLY_PCI_BRIDGE
 	select UART_OVERRIDE_REFCLK
diff --git a/src/drivers/uart/oxpcie_early.c b/src/drivers/uart/oxpcie_early.c
index 0a778d9..f44e3e8 100644
--- a/src/drivers/uart/oxpcie_early.c
+++ b/src/drivers/uart/oxpcie_early.c
@@ -84,20 +84,6 @@ void oxford_remap(u32 new_base)
 {
 	uart0_base = new_base + 0x1000;
 }
-
-void uart_fill_lb(void *data)
-{
-	struct lb_serial serial;
-	serial.type = LB_SERIAL_TYPE_MEMORY_MAPPED;
-	serial.baseaddr = uart_platform_base(CONFIG_UART_FOR_CONSOLE);
-	serial.baud = default_baudrate();
-	serial.regwidth = 1;
-	serial.input_hertz = uart_platform_refclk();
-	serial.uart_pci_addr = CONFIG_UART_PCI_ADDR;
-	lb_add_serial(&serial, data);
-
-	lb_add_console(LB_TAG_CONSOLE_SERIAL8250MEM, data);
-}
 #endif
 
 unsigned int uart_platform_refclk(void)



More information about the coreboot-gerrit mailing list