From 392e8802486cb573b916e746010e141a75f507e6 Mon Sep 17 00:00:00 2001 From: Kevin Date: Sat, 15 Nov 2014 09:58:27 +0800 Subject: init android origin source code --- .../arm/mach-picoxcell/include/mach/debug-macro.S | 35 ++++++++++++++++++++++ .../arch/arm/mach-picoxcell/include/mach/gpio.h | 1 + .../arm/mach-picoxcell/include/mach/hardware.h | 21 +++++++++++++ .../arch/arm/mach-picoxcell/include/mach/map.h | 25 ++++++++++++++++ .../mach-picoxcell/include/mach/picoxcell_soc.h | 25 ++++++++++++++++ .../arch/arm/mach-picoxcell/include/mach/timex.h | 25 ++++++++++++++++ .../arm/mach-picoxcell/include/mach/uncompress.h | 21 +++++++++++++ 7 files changed, 153 insertions(+) create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/debug-macro.S create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/gpio.h create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/hardware.h create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/map.h create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/picoxcell_soc.h create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/timex.h create mode 100644 ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/uncompress.h (limited to 'ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach') diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/debug-macro.S b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/debug-macro.S new file mode 100644 index 00000000..58d4ee3a --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/debug-macro.S @@ -0,0 +1,35 @@ +/* + * Copyright (c) 2011 Picochip Ltd., Jamie Iles + * + * 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 + * published by the Free Software Foundation. + * + * Derived from arch/arm/mach-davinci/include/mach/debug-macro.S to use 32-bit + * accesses to the 8250. + */ +#include +#include +#include + +#define UART_SHIFT 2 + + .macro addruart, rp, rv, tmp + ldr \rv, =PHYS_TO_IO(PICOXCELL_UART1_BASE) + ldr \rp, =PICOXCELL_UART1_BASE + .endm + + .macro senduart,rd,rx + str \rd, [\rx, #UART_TX << UART_SHIFT] + .endm + + .macro busyuart,rd,rx +1002: ldr \rd, [\rx, #UART_LSR << UART_SHIFT] + and \rd, \rd, #UART_LSR_TEMT | UART_LSR_THRE + teq \rd, #UART_LSR_TEMT | UART_LSR_THRE + bne 1002b + .endm + + /* The UART's don't have any flow control IO's wired up. */ + .macro waituart,rd,rx + .endm diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/gpio.h b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/gpio.h new file mode 100644 index 00000000..40a8c178 --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/gpio.h @@ -0,0 +1 @@ +/* empty */ diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/hardware.h b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/hardware.h new file mode 100644 index 00000000..70ff5819 --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/hardware.h @@ -0,0 +1,21 @@ +/* + * Copyright (c) 2011 Picochip Ltd., Jamie Iles + * + * This file contains the hardware definitions of the picoXcell SoC devices. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ +#ifndef __ASM_ARCH_HARDWARE_H +#define __ASM_ARCH_HARDWARE_H + +#include + +#endif diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/map.h b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/map.h new file mode 100644 index 00000000..c06afad2 --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/map.h @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2011 Picochip Ltd., Jamie Iles + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ +#ifndef __PICOXCELL_MAP_H__ +#define __PICOXCELL_MAP_H__ + +#define PHYS_TO_IO(x) (((x) & 0x00ffffff) | 0xfe000000) + +#ifdef __ASSEMBLY__ +#define IO_ADDRESS(x) PHYS_TO_IO((x)) +#else +#define IO_ADDRESS(x) (void __iomem __force *)(PHYS_TO_IO((x))) +#endif + +#endif /* __PICOXCELL_MAP_H__ */ diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/picoxcell_soc.h b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/picoxcell_soc.h new file mode 100644 index 00000000..5566fc88 --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/picoxcell_soc.h @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2011 Picochip Ltd., Jamie Iles + * + * This file contains the hardware definitions of the picoXcell SoC devices. + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ +#ifndef __PICOXCELL_SOC_H__ +#define __PICOXCELL_SOC_H__ + +#define PICOXCELL_UART1_BASE 0x80230000 +#define PICOXCELL_PERIPH_BASE 0x80000000 +#define PICOXCELL_PERIPH_LENGTH SZ_4M +#define PICOXCELL_VIC0_BASE 0x80060000 +#define PICOXCELL_VIC1_BASE 0x80064000 + +#endif /* __PICOXCELL_SOC_H__ */ diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/timex.h b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/timex.h new file mode 100644 index 00000000..6c540a69 --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/timex.h @@ -0,0 +1,25 @@ +/* + * Copyright (c) 2011 Picochip Ltd., Jamie Iles + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +#ifndef __TIMEX_H__ +#define __TIMEX_H__ + +/* Bogus value to allow the kernel to compile. */ +#define CLOCK_TICK_RATE 1000000 + +#endif /* __TIMEX_H__ */ + diff --git a/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/uncompress.h b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/uncompress.h new file mode 100644 index 00000000..b60b19d1 --- /dev/null +++ b/ANDROID_3.4.5/arch/arm/mach-picoxcell/include/mach/uncompress.h @@ -0,0 +1,21 @@ +/* + * Copyright (c) 2011 Picochip Ltd., Jamie Iles + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + */ +#define putc(c) +#define flush() +#define arch_decomp_setup() +#define arch_decomp_wdog() -- cgit