Hi Sudhakar,
On Tue, Aug 12, 2008 at 10:01 AM, Sudhakar Rajashekhara
<[EMAIL PROTECTED]> wrote:
> Description:
> Moves the serial initialization data from serial.c to board-evm.c file.
> Signed-off-by: Sudhakar Rajashekhara <[EMAIL PROTECTED]>
> ---
> arch/arm/mach-davinci/board-evm.c | 48 ++++++++++++++++++++++++++++-
> arch/arm/mach-davinci/serial.c | 54
> ++-------------------------------
> include/asm-arm/arch-davinci/common.h | 2 +-
> 3 files changed, 51 insertions(+), 53 deletions(-)
>
> diff --git a/arch/arm/mach-davinci/board-evm.c
> b/arch/arm/mach-davinci/board-evm.c
> index 399bfea..6955208 100644
> --- a/arch/arm/mach-davinci/board-evm.c
> +++ b/arch/arm/mach-davinci/board-evm.c
> @@ -15,6 +15,7 @@
> #include <linux/platform_device.h>
> #include <linux/i2c.h>
> #include <linux/gpio.h>
> +#include <linux/serial_8250.h>
> #include <linux/i2c/pcf857x.h>
> #include <linux/leds.h>
>
> @@ -36,6 +37,7 @@
> #include <asm/arch/common.h>
> #include <asm/arch/hardware.h>
> #include <asm/arch/psc.h>
> +#include <asm/arch/serial.h>
>
> /* other misc. init functions */
> void __init davinci_psc_init(void);
> @@ -46,6 +48,49 @@ void __init davinci_init_common_hw(void);
> /* NOR Flash base address set to CS0 by default */
> #define NOR_FLASH_PHYS 0x02000000
>
> +#define DAVINCI_UART_CLK 27000000
> +
> +static struct plat_serial8250_port serial_platform_data[] = {
> + {
> + .membase = (char *)IO_ADDRESS(DAVINCI_UART0_BASE),
> + .mapbase = (unsigned long)DAVINCI_UART0_BASE,
> + .irq = IRQ_UARTINT0,
> + .flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST,
> + .iotype = UPIO_MEM,
> + .regshift = 2,
> + .uartclk = DAVINCI_UART_CLK,
> + },
> + {
> + .membase = (char *)IO_ADDRESS(DAVINCI_UART1_BASE),
> + .mapbase = (unsigned long)DAVINCI_UART1_BASE,
> + .irq = IRQ_UARTINT1,
> + .flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST,
> + .iotype = UPIO_MEM,
> + .regshift = 2,
> + .uartclk = DAVINCI_UART_CLK,
> + },
> + {
> + .membase = (char *)IO_ADDRESS(DAVINCI_UART2_BASE),
> + .mapbase = (unsigned long)DAVINCI_UART2_BASE,
> + .irq = IRQ_UARTINT2,
> + .flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST,
> + .iotype = UPIO_MEM,
> + .regshift = 2,
> + .uartclk = DAVINCI_UART_CLK,
> + },
> + {
> + .flags = 0
> + },
> +};
Could you please explain in more detail why you did these changes?
AFAIK, base addresses are chip specific resources not board resources?
So every board designer then has to copy these structures over and
over if you have made above changes.
Kevin,
Could you please comment on this? I don't like this change. I remember
that I have submitted ATAG_SERIAL support and it should very much work
by changing base addresses across cpu series if there are any
differences in new chips.
--
---Trilok Soni
http://triloksoni.wordpress.com
http://www.linkedin.com/in/triloksoni
_______________________________________________
Davinci-linux-open-source mailing list
[email protected]
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source