atheros[uart]: pass only physical I/O mem address to 8250 driver
[openwrt/svn-archive/archive.git] / target / linux / atheros / patches-3.10 / 100-board.patch
index 4fdf435e87a6bec7c5358f66baf7c85608de3443..611d7ccf6000596ef109e49f805100bafaf9131e 100644 (file)
 +#define AR2315_LOCAL            0x10400000      /* LOCAL BUS MMR */
 +#define AR2315_ENET0            0x10500000      /* ETHERNET MMR */
 +#define AR2315_DSLBASE          0x11000000      /* RESET CONTROL MMR */
-+#define AR2315_UART0            0x11100003      /* UART MMR */
++#define AR2315_UART0            0x11100000      /* UART MMR */
 +#define AR2315_SPI_MMR          0x11300000      /* SPI FLASH MMR */
 +#define AR2315_PCIEXT           0x80000000      /* pci external */
 +
 +#define AR531X_SDRAMCTL         0x18300000
 +#define AR531X_FLASHCTL         0x18400000
 +#define AR531X_APBBASE                0x1c000000
++#define AR531X_UART0            0x1c000000      /* UART MMR */
 +#define AR531X_FLASH            0x1e000000
-+#define AR531X_UART0            0xbc000003      /* UART MMR */
 +
 +/*
 + * AR531X_NUM_ENET_MAC defines the number of ethernet MACs that
 +      ar231x_write_reg(AR531X_WD_CTRL, AR531X_WD_CTRL_IGNORE_EXPIRATION);
 +
 +      _machine_restart = ar5312_restart;
-+      ar231x_serial_setup(KSEG1ADDR(AR531X_UART0), AR531X_MISC_IRQ_UART0,
++      ar231x_serial_setup(AR531X_UART0, AR531X_MISC_IRQ_UART0,
 +                          ar5312_sys_frequency());
 +}
 +
 +      ar231x_write_reg(AR2315_WDC, AR2315_WDC_IGNORE_EXPIRATION);
 +
 +      _machine_restart = ar2315_restart;
-+      ar231x_serial_setup(KSEG1ADDR(AR2315_UART0), AR2315_MISC_IRQ_UART0,
++      ar231x_serial_setup(AR2315_UART0, AR2315_MISC_IRQ_UART0,
 +                          ar2315_apb_frequency());
 +}
 --- /dev/null
 +#endif
 --- /dev/null
 +++ b/arch/mips/ar231x/devices.c
-@@ -0,0 +1,181 @@
+@@ -0,0 +1,180 @@
 +#include <linux/kernel.h>
 +#include <linux/init.h>
 +#include <linux/serial.h>
 +
 +      memset(&s, 0, sizeof(s));
 +
-+      s.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST;
-+      s.iotype = UPIO_MEM;
++      s.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_IOREMAP;
++      s.iotype = UPIO_MEM32;
 +      s.irq = irq;
 +      s.regshift = 2;
 +      s.mapbase = mapbase;
 +      s.uartclk = uartclk;
-+      s.membase = (void __iomem *)s.mapbase;
 +
 +      early_serial_setup(&s);
 +}