From: 黄涛 Date: Thu, 5 Jul 2012 10:22:44 +0000 (+0800) Subject: rk2928: add initial support X-Git-Tag: firefly_0821_release~8912^2~113 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=64e1e8cff85ddcfe97b9d5525b879ffb5f51f0f9;p=firefly-linux-kernel-4.4.55.git rk2928: add initial support --- diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index b7635e71087d..359ef7a6dbb2 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig @@ -871,6 +871,17 @@ config ARCH_RK29 help Support for Rockchip's RK29xx SoCs. +config ARCH_RK2928 + bool "Rockchip RK2928" + select PLAT_RK + select CPU_V7 + select ARM_GIC + select PL330 + select MIGHT_HAVE_CACHE_L2X0 + select ARM_ERRATA_754322 + help + Support for Rockchip's RK2928 SoCs. + config ARCH_RK30 bool "Rockchip RK30xx" select PLAT_RK @@ -986,6 +997,7 @@ source "arch/arm/mach-realview/Kconfig" source "arch/arm/plat-rk/Kconfig" source "arch/arm/mach-rk29/Kconfig" +source "arch/arm/mach-rk2928/Kconfig" source "arch/arm/mach-rk30/Kconfig" source "arch/arm/mach-sa1100/Kconfig" diff --git a/arch/arm/Makefile b/arch/arm/Makefile index 83aa4bd2c5a7..43c17789695f 100644 --- a/arch/arm/Makefile +++ b/arch/arm/Makefile @@ -172,6 +172,7 @@ machine-$(CONFIG_ARCH_PNX4008) := pnx4008 machine-$(CONFIG_ARCH_PXA) := pxa machine-$(CONFIG_ARCH_REALVIEW) := realview machine-$(CONFIG_ARCH_RK29) := rk29 +machine-$(CONFIG_ARCH_RK2928) := rk2928 machine-$(CONFIG_ARCH_RK30) := rk30 machine-$(CONFIG_ARCH_RPC) := rpc machine-$(CONFIG_ARCH_S3C2410) := s3c2410 s3c2400 s3c2412 s3c2416 s3c2440 s3c2443 diff --git a/arch/arm/mach-rk2928/Kconfig b/arch/arm/mach-rk2928/Kconfig new file mode 100644 index 000000000000..9427d232d354 --- /dev/null +++ b/arch/arm/mach-rk2928/Kconfig @@ -0,0 +1,15 @@ +if ARCH_RK2928 + +choice + prompt "RK2928 Board Type" + default MACH_RK2928_SDK + +config MACH_RK2928_FPGA + bool "RK2928 FPGA board" + +config MACH_RK2928_SDK + bool "RK2928 SDK board" + +endchoice + +endif diff --git a/arch/arm/mach-rk2928/Makefile.boot b/arch/arm/mach-rk2928/Makefile.boot new file mode 100644 index 000000000000..820e50c1b2b6 --- /dev/null +++ b/arch/arm/mach-rk2928/Makefile.boot @@ -0,0 +1,3 @@ + zreladdr-y := 0x60408000 +params_phys-y := 0x60088000 +initrd_phys-y := 0x60800000 diff --git a/arch/arm/mach-rk2928/include/mach/clkdev.h b/arch/arm/mach-rk2928/include/mach/clkdev.h new file mode 100644 index 000000000000..c0cf3286a662 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/clkdev.h @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/debug-macro.S b/arch/arm/mach-rk2928/include/mach/debug-macro.S new file mode 100644 index 000000000000..00d5467951fe --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/debug-macro.S @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/dma-pl330.h b/arch/arm/mach-rk2928/include/mach/dma-pl330.h new file mode 100644 index 000000000000..9afde6529658 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/dma-pl330.h @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/entry-macro.S b/arch/arm/mach-rk2928/include/mach/entry-macro.S new file mode 100644 index 000000000000..d5136aa47385 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/entry-macro.S @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/fiq.h b/arch/arm/mach-rk2928/include/mach/fiq.h new file mode 100644 index 000000000000..31e146e6f1f4 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/fiq.h @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/hardware.h b/arch/arm/mach-rk2928/include/mach/hardware.h new file mode 100644 index 000000000000..9e84f2395d97 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/hardware.h @@ -0,0 +1,4 @@ +#ifndef __MACH_HARDWARE_H +#define __MACH_HARDWARE_H + +#endif diff --git a/arch/arm/mach-rk2928/include/mach/memory.h b/arch/arm/mach-rk2928/include/mach/memory.h new file mode 100644 index 000000000000..5aa902f91630 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/memory.h @@ -0,0 +1,14 @@ +#ifndef __MACH_MEMORY_H +#define __MACH_MEMORY_H + +#include + +/* + * SRAM memory whereabouts + */ +#define SRAM_CODE_OFFSET (RK2928_IMEM_BASE + 0x0000) +#define SRAM_CODE_END (RK2928_IMEM_BASE + 0x0FFF) +#define SRAM_DATA_OFFSET (RK2928_IMEM_BASE + 0x1000) +#define SRAM_DATA_END (RK2928_IMEM_BASE + 0x1FFF) + +#endif diff --git a/arch/arm/mach-rk2928/include/mach/sram.h b/arch/arm/mach-rk2928/include/mach/sram.h new file mode 100644 index 000000000000..eba76bccf64d --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/sram.h @@ -0,0 +1,13 @@ +#ifndef __MACH_SRAM_H +#define __MACH_SRAM_H + +#include + +#define SRAM_LOOPS_PER_USEC 24 +#define SRAM_LOOP(loops) do { unsigned int i = (loops); if (i < 7) i = 7; barrier(); while (--i) barrier(); } while (0) +/* delay on slow mode */ +#define sram_udelay(usecs) SRAM_LOOP((usecs)*SRAM_LOOPS_PER_USEC) +/* delay on deep slow mode */ +#define sram_32k_udelay(usecs) SRAM_LOOP(((usecs)*SRAM_LOOPS_PER_USEC)/(24000000/32768)) + +#endif diff --git a/arch/arm/mach-rk2928/include/mach/system.h b/arch/arm/mach-rk2928/include/mach/system.h new file mode 100644 index 000000000000..e68cfe7e31ed --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/system.h @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/timex.h b/arch/arm/mach-rk2928/include/mach/timex.h new file mode 100644 index 000000000000..d2a02f98c397 --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/timex.h @@ -0,0 +1 @@ +#include diff --git a/arch/arm/mach-rk2928/include/mach/uncompress.h b/arch/arm/mach-rk2928/include/mach/uncompress.h new file mode 100644 index 000000000000..a4acb7198e1c --- /dev/null +++ b/arch/arm/mach-rk2928/include/mach/uncompress.h @@ -0,0 +1 @@ +#include