forked from luck/tmp_suning_uos_patched
[ARM] mmp: avengers lite (pxa168) board bring up
Signed-off-by: Gavin Gu <gavin.gu@marvell.com> Signed-off-by: Jing Xiang <jxiang@marvell.com> Signed-off-by: Jack Ren <jack.ren@marvell.com> Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
This commit is contained in:
parent
0925e2f0fc
commit
9896de72d2
@ -16,6 +16,13 @@ config MACH_ZYLONITE2
|
||||
Say 'Y' here if you want to support the Marvell PXA168-based
|
||||
Zylonite2 Development Board.
|
||||
|
||||
config MACH_AVENGERS_LITE
|
||||
bool "Marvell's PXA168 Avengers Lite Development Board"
|
||||
select CPU_PXA168
|
||||
help
|
||||
Say 'Y' here if you want to support the Marvell PXA168-based
|
||||
Avengers Lite Development Board.
|
||||
|
||||
config MACH_TAVOREVB
|
||||
bool "Marvell's PXA910 TavorEVB Development Board"
|
||||
select CPU_PXA910
|
||||
|
@ -11,5 +11,6 @@ obj-$(CONFIG_CPU_PXA910) += pxa910.o
|
||||
# board support
|
||||
obj-$(CONFIG_MACH_ASPENITE) += aspenite.o
|
||||
obj-$(CONFIG_MACH_ZYLONITE2) += aspenite.o
|
||||
obj-$(CONFIG_MACH_AVENGERS_LITE)+= avengers_lite.o
|
||||
obj-$(CONFIG_MACH_TAVOREVB) += tavorevb.o
|
||||
obj-$(CONFIG_MACH_TTC_DKB) += ttc_dkb.o
|
||||
|
51
arch/arm/mach-mmp/avengers_lite.c
Normal file
51
arch/arm/mach-mmp/avengers_lite.c
Normal file
@ -0,0 +1,51 @@
|
||||
/*
|
||||
* linux/arch/arm/mach-mmp/avengers_lite.c
|
||||
*
|
||||
* Support for the Marvell PXA168-based Avengers lite Development Platform.
|
||||
*
|
||||
* Copyright (C) 2009-2010 Marvell International Ltd.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License version 2 as
|
||||
* publishhed by the Free Software Foundation.
|
||||
*/
|
||||
|
||||
#include <linux/init.h>
|
||||
#include <linux/kernel.h>
|
||||
#include <linux/platform_device.h>
|
||||
|
||||
#include <asm/mach-types.h>
|
||||
#include <asm/mach/arch.h>
|
||||
#include <mach/addr-map.h>
|
||||
#include <mach/mfp-pxa168.h>
|
||||
#include <mach/pxa168.h>
|
||||
#include <mach/irqs.h>
|
||||
|
||||
|
||||
#include "common.h"
|
||||
#include <linux/delay.h>
|
||||
|
||||
/* Avengers lite MFP configurations */
|
||||
static unsigned long avengers_lite_pin_config_V16F[] __initdata = {
|
||||
/* DEBUG_UART */
|
||||
GPIO88_UART2_TXD,
|
||||
GPIO89_UART2_RXD,
|
||||
};
|
||||
|
||||
static void __init avengers_lite_init(void)
|
||||
{
|
||||
mfp_config(ARRAY_AND_SIZE(avengers_lite_pin_config_V16F));
|
||||
|
||||
/* on-chip devices */
|
||||
pxa168_add_uart(2);
|
||||
}
|
||||
|
||||
MACHINE_START(AVENGERS_LITE, "PXA168 Avengers lite Development Platform")
|
||||
.phys_io = APB_PHYS_BASE,
|
||||
.boot_params = 0x00000100,
|
||||
.io_pg_offst = (APB_VIRT_BASE >> 18) & 0xfffc,
|
||||
.map_io = pxa_map_io,
|
||||
.init_irq = pxa168_init_irq,
|
||||
.timer = &pxa168_timer,
|
||||
.init_machine = avengers_lite_init,
|
||||
MACHINE_END
|
@ -193,7 +193,9 @@
|
||||
#define GPIO32_CF_nCD1 MFP_CFG(GPIO32, AF3)
|
||||
#define GPIO33_CF_nCD2 MFP_CFG(GPIO33, AF3)
|
||||
|
||||
/* UART1 */
|
||||
/* UART */
|
||||
#define GPIO88_UART2_TXD MFP_CFG(GPIO88, AF2)
|
||||
#define GPIO89_UART2_RXD MFP_CFG(GPIO89, AF2)
|
||||
#define GPIO107_UART1_TXD MFP_CFG_DRV(GPIO107, AF1, FAST)
|
||||
#define GPIO107_UART1_RXD MFP_CFG_DRV(GPIO107, AF2, FAST)
|
||||
#define GPIO108_UART1_RXD MFP_CFG_DRV(GPIO108, AF1, FAST)
|
||||
|
@ -8,15 +8,16 @@
|
||||
|
||||
#include <linux/serial_reg.h>
|
||||
#include <mach/addr-map.h>
|
||||
#include <asm/mach-types.h>
|
||||
|
||||
#define UART1_BASE (APB_PHYS_BASE + 0x36000)
|
||||
#define UART2_BASE (APB_PHYS_BASE + 0x17000)
|
||||
#define UART3_BASE (APB_PHYS_BASE + 0x18000)
|
||||
|
||||
static volatile unsigned long *UART = (unsigned long *)UART2_BASE;
|
||||
|
||||
static inline void putc(char c)
|
||||
{
|
||||
volatile unsigned long *UART = (unsigned long *)UART2_BASE;
|
||||
|
||||
/* UART enabled? */
|
||||
if (!(UART[UART_IER] & UART_IER_UUE))
|
||||
return;
|
||||
@ -34,8 +35,14 @@ static inline void flush(void)
|
||||
{
|
||||
}
|
||||
|
||||
static inline void arch_decomp_setup(void)
|
||||
{
|
||||
if (machine_is_avengers_lite())
|
||||
UART = (unsigned long *)UART3_BASE;
|
||||
}
|
||||
|
||||
/*
|
||||
* nothing to do
|
||||
*/
|
||||
#define arch_decomp_setup()
|
||||
|
||||
#define arch_decomp_wdog()
|
||||
|
Loading…
Reference in New Issue
Block a user