diff options
author | Vineet Gupta <vgupta@synopsys.com> | 2015-05-11 09:16:22 -0400 |
---|---|---|
committer | Vineet Gupta <vgupta@synopsys.com> | 2016-09-30 17:48:15 -0400 |
commit | 9efac6798b20ae6b63ce244b569755f3b60d80aa (patch) | |
tree | bf19fcd137b4100371ebb5eadca850fac98de42a | |
parent | 618a9cd06dd471ac232f5b27325b24d26eba5571 (diff) |
ARCv2: Add support for ZeBu Emulation platform for HS cores
The cool thing is that same kernel image can run on
- nsim OSCI simulation platform
- SDPlite FPGA setups
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
-rw-r--r-- | arch/arc/boot/dts/zebu_hs.dts | 69 | ||||
-rw-r--r-- | arch/arc/boot/dts/zebu_hs_idu.dts | 85 | ||||
-rw-r--r-- | arch/arc/configs/zebu_hs_defconfig | 86 | ||||
-rw-r--r-- | arch/arc/configs/zebu_hs_smp_defconfig | 89 | ||||
-rw-r--r-- | arch/arc/plat-sim/platform.c | 1 |
5 files changed, 330 insertions, 0 deletions
diff --git a/arch/arc/boot/dts/zebu_hs.dts b/arch/arc/boot/dts/zebu_hs.dts new file mode 100644 index 000000000000..1c1324e84965 --- /dev/null +++ b/arch/arc/boot/dts/zebu_hs.dts | |||
@@ -0,0 +1,69 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2016-2014 Synopsys, Inc. (www.synopsys.com) | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License version 2 as | ||
6 | * published by the Free Software Foundation. | ||
7 | */ | ||
8 | /dts-v1/; | ||
9 | |||
10 | /include/ "skeleton_hs.dtsi" | ||
11 | |||
12 | / { | ||
13 | model = "snps,zebu_hs"; | ||
14 | compatible = "snps,zebu_hs"; | ||
15 | #address-cells = <1>; | ||
16 | #size-cells = <1>; | ||
17 | interrupt-parent = <&core_intc>; | ||
18 | |||
19 | memory { | ||
20 | device_type = "memory"; | ||
21 | reg = <0x80000000 0x20000000>; /* 512 */ | ||
22 | }; | ||
23 | |||
24 | chosen { | ||
25 | bootargs = "earlycon=uart8250,mmio32,0xf0000000,115200n8 console=ttyS0,115200n8 debug print-fatal-signals=1"; | ||
26 | }; | ||
27 | |||
28 | aliases { | ||
29 | serial0 = &uart0; | ||
30 | }; | ||
31 | |||
32 | fpga { | ||
33 | compatible = "simple-bus"; | ||
34 | #address-cells = <1>; | ||
35 | #size-cells = <1>; | ||
36 | |||
37 | /* child and parent address space 1:1 mapped */ | ||
38 | ranges; | ||
39 | |||
40 | core_clk: core_clk { | ||
41 | #clock-cells = <0>; | ||
42 | compatible = "fixed-clock"; | ||
43 | clock-frequency = <50000000>; | ||
44 | }; | ||
45 | |||
46 | core_intc: interrupt-controller { | ||
47 | compatible = "snps,archs-intc"; | ||
48 | interrupt-controller; | ||
49 | #interrupt-cells = <1>; | ||
50 | }; | ||
51 | |||
52 | uart0: serial@f0000000 { | ||
53 | compatible = "ns8250"; | ||
54 | reg = <0xf0000000 0x2000>; | ||
55 | interrupts = <24>; | ||
56 | clock-frequency = <50000000>; | ||
57 | baud = <115200>; | ||
58 | reg-shift = <2>; | ||
59 | reg-io-width = <4>; | ||
60 | no-loopback-test = <1>; | ||
61 | }; | ||
62 | |||
63 | arcpct0: pct { | ||
64 | compatible = "snps,archs-pct"; | ||
65 | #interrupt-cells = <1>; | ||
66 | interrupts = <20>; | ||
67 | }; | ||
68 | }; | ||
69 | }; | ||
diff --git a/arch/arc/boot/dts/zebu_hs_idu.dts b/arch/arc/boot/dts/zebu_hs_idu.dts new file mode 100644 index 000000000000..65204b4c0f13 --- /dev/null +++ b/arch/arc/boot/dts/zebu_hs_idu.dts | |||
@@ -0,0 +1,85 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2016-2014 Synopsys, Inc. (www.synopsys.com) | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License version 2 as | ||
6 | * published by the Free Software Foundation. | ||
7 | */ | ||
8 | /dts-v1/; | ||
9 | |||
10 | /include/ "skeleton_hs_idu.dtsi" | ||
11 | |||
12 | / { | ||
13 | model = "snps,zebu_hs-smp"; | ||
14 | compatible = "snps,zebu_hs"; | ||
15 | #address-cells = <1>; | ||
16 | #size-cells = <1>; | ||
17 | interrupt-parent = <&core_intc>; | ||
18 | |||
19 | memory { | ||
20 | device_type = "memory"; | ||
21 | reg = <0x80000000 0x20000000>; /* 512 */ | ||
22 | }; | ||
23 | |||
24 | chosen { | ||
25 | bootargs = "earlycon=uart8250,mmio32,0xf0000000,115200n8 console=ttyS0,115200n8 debug"; | ||
26 | }; | ||
27 | |||
28 | aliases { | ||
29 | serial0 = &uart0; | ||
30 | }; | ||
31 | |||
32 | fpga { | ||
33 | compatible = "simple-bus"; | ||
34 | #address-cells = <1>; | ||
35 | #size-cells = <1>; | ||
36 | |||
37 | /* child and parent address space 1:1 mapped */ | ||
38 | ranges; | ||
39 | |||
40 | core_clk: core_clk { | ||
41 | #clock-cells = <0>; | ||
42 | compatible = "fixed-clock"; | ||
43 | clock-frequency = <50000000>; /* 50 MHZ */ | ||
44 | }; | ||
45 | |||
46 | core_intc: interrupt-controller { | ||
47 | compatible = "snps,archs-intc"; | ||
48 | interrupt-controller; | ||
49 | #interrupt-cells = <1>; | ||
50 | /* interrupts = <16 17 18 19 20 21 22 23 24 25>; */ | ||
51 | }; | ||
52 | |||
53 | idu_intc: idu-interrupt-controller { | ||
54 | compatible = "snps,archs-idu-intc"; | ||
55 | interrupt-controller; | ||
56 | interrupt-parent = <&core_intc>; | ||
57 | /* <hwirq distribution> | ||
58 | distribution: 0=RR; 1=cpu0, 2=cpu1, 4=cpu2, 8=cpu3 */ | ||
59 | #interrupt-cells = <2>; | ||
60 | interrupts = <24 25 26 27 28 29 30 31>; | ||
61 | |||
62 | }; | ||
63 | |||
64 | uart0: serial@f0000000 { | ||
65 | /* compatible = "ns8250"; Doesn't use FIFOs */ | ||
66 | compatible = "ns16550a"; | ||
67 | reg = <0xf0000000 0x2000>; | ||
68 | interrupt-parent = <&idu_intc>; | ||
69 | /* interrupts = <0 1>; DEST=1*/ | ||
70 | /* interrupts = <0 2>; DEST=2*/ | ||
71 | interrupts = <0 0>; /* RR*/ | ||
72 | clock-frequency = <50000000>; | ||
73 | baud = <115200>; | ||
74 | reg-shift = <2>; | ||
75 | reg-io-width = <4>; | ||
76 | no-loopback-test = <1>; | ||
77 | }; | ||
78 | |||
79 | arcpct0: pct { | ||
80 | compatible = "snps,archs-pct"; | ||
81 | #interrupt-cells = <1>; | ||
82 | interrupts = <20>; | ||
83 | }; | ||
84 | }; | ||
85 | }; | ||
diff --git a/arch/arc/configs/zebu_hs_defconfig b/arch/arc/configs/zebu_hs_defconfig new file mode 100644 index 000000000000..9f6166be7145 --- /dev/null +++ b/arch/arc/configs/zebu_hs_defconfig | |||
@@ -0,0 +1,86 @@ | |||
1 | CONFIG_DEFAULT_HOSTNAME="ARCLinux" | ||
2 | # CONFIG_SWAP is not set | ||
3 | CONFIG_SYSVIPC=y | ||
4 | CONFIG_POSIX_MQUEUE=y | ||
5 | # CONFIG_CROSS_MEMORY_ATTACH is not set | ||
6 | CONFIG_NO_HZ_IDLE=y | ||
7 | CONFIG_HIGH_RES_TIMERS=y | ||
8 | CONFIG_IKCONFIG=y | ||
9 | CONFIG_IKCONFIG_PROC=y | ||
10 | CONFIG_NAMESPACES=y | ||
11 | # CONFIG_UTS_NS is not set | ||
12 | # CONFIG_PID_NS is not set | ||
13 | CONFIG_BLK_DEV_INITRD=y | ||
14 | CONFIG_INITRAMFS_SOURCE="../../arc_initramfs_hs/" | ||
15 | CONFIG_EXPERT=y | ||
16 | CONFIG_PERF_EVENTS=y | ||
17 | # CONFIG_COMPAT_BRK is not set | ||
18 | CONFIG_SLAB=y | ||
19 | CONFIG_MODULES=y | ||
20 | # CONFIG_LBDAF is not set | ||
21 | # CONFIG_BLK_DEV_BSG is not set | ||
22 | # CONFIG_IOSCHED_DEADLINE is not set | ||
23 | # CONFIG_IOSCHED_CFQ is not set | ||
24 | CONFIG_ARC_PLAT_SIM=y | ||
25 | CONFIG_ISA_ARCV2=y | ||
26 | CONFIG_ARC_BUILTIN_DTB_NAME="zebu_hs" | ||
27 | CONFIG_PREEMPT=y | ||
28 | # CONFIG_COMPACTION is not set | ||
29 | CONFIG_NET=y | ||
30 | CONFIG_PACKET=y | ||
31 | CONFIG_PACKET_DIAG=y | ||
32 | CONFIG_UNIX=y | ||
33 | CONFIG_UNIX_DIAG=y | ||
34 | CONFIG_NET_KEY=y | ||
35 | CONFIG_INET=y | ||
36 | # CONFIG_INET_XFRM_MODE_TRANSPORT is not set | ||
37 | # CONFIG_INET_XFRM_MODE_TUNNEL is not set | ||
38 | # CONFIG_INET_XFRM_MODE_BEET is not set | ||
39 | # CONFIG_IPV6 is not set | ||
40 | # CONFIG_WIRELESS is not set | ||
41 | CONFIG_DEVTMPFS=y | ||
42 | # CONFIG_STANDALONE is not set | ||
43 | # CONFIG_PREVENT_FIRMWARE_BUILD is not set | ||
44 | # CONFIG_FIRMWARE_IN_KERNEL is not set | ||
45 | # CONFIG_BLK_DEV is not set | ||
46 | CONFIG_NETDEVICES=y | ||
47 | # CONFIG_NET_VENDOR_ARC is not set | ||
48 | # CONFIG_NET_VENDOR_BROADCOM is not set | ||
49 | # CONFIG_NET_VENDOR_INTEL is not set | ||
50 | # CONFIG_NET_VENDOR_MARVELL is not set | ||
51 | # CONFIG_NET_VENDOR_MICREL is not set | ||
52 | # CONFIG_NET_VENDOR_NATSEMI is not set | ||
53 | # CONFIG_NET_VENDOR_SEEQ is not set | ||
54 | # CONFIG_NET_VENDOR_STMICRO is not set | ||
55 | # CONFIG_NET_VENDOR_VIA is not set | ||
56 | # CONFIG_NET_VENDOR_WIZNET is not set | ||
57 | # CONFIG_WLAN is not set | ||
58 | CONFIG_INPUT_EVDEV=y | ||
59 | CONFIG_MOUSE_PS2_TOUCHKIT=y | ||
60 | # CONFIG_SERIO_SERPORT is not set | ||
61 | CONFIG_SERIO_ARC_PS2=y | ||
62 | # CONFIG_LEGACY_PTYS is not set | ||
63 | # CONFIG_DEVKMEM is not set | ||
64 | CONFIG_SERIAL_8250=y | ||
65 | CONFIG_SERIAL_8250_CONSOLE=y | ||
66 | CONFIG_SERIAL_8250_NR_UARTS=1 | ||
67 | CONFIG_SERIAL_8250_RUNTIME_UARTS=1 | ||
68 | CONFIG_SERIAL_8250_DW=y | ||
69 | CONFIG_SERIAL_OF_PLATFORM=y | ||
70 | # CONFIG_HW_RANDOM is not set | ||
71 | # CONFIG_HWMON is not set | ||
72 | CONFIG_FB=y | ||
73 | CONFIG_FRAMEBUFFER_CONSOLE=y | ||
74 | CONFIG_LOGO=y | ||
75 | # CONFIG_HID is not set | ||
76 | # CONFIG_USB_SUPPORT is not set | ||
77 | # CONFIG_IOMMU_SUPPORT is not set | ||
78 | CONFIG_EXT2_FS=y | ||
79 | CONFIG_EXT2_FS_XATTR=y | ||
80 | CONFIG_TMPFS=y | ||
81 | # CONFIG_MISC_FILESYSTEMS is not set | ||
82 | CONFIG_NFS_FS=y | ||
83 | # CONFIG_ENABLE_WARN_DEPRECATED is not set | ||
84 | # CONFIG_ENABLE_MUST_CHECK is not set | ||
85 | CONFIG_DEBUG_MEMORY_INIT=y | ||
86 | # CONFIG_DEBUG_PREEMPT is not set | ||
diff --git a/arch/arc/configs/zebu_hs_smp_defconfig b/arch/arc/configs/zebu_hs_smp_defconfig new file mode 100644 index 000000000000..44e9693f4257 --- /dev/null +++ b/arch/arc/configs/zebu_hs_smp_defconfig | |||
@@ -0,0 +1,89 @@ | |||
1 | CONFIG_DEFAULT_HOSTNAME="ARCLinux" | ||
2 | # CONFIG_SWAP is not set | ||
3 | CONFIG_SYSVIPC=y | ||
4 | CONFIG_POSIX_MQUEUE=y | ||
5 | # CONFIG_CROSS_MEMORY_ATTACH is not set | ||
6 | CONFIG_NO_HZ_IDLE=y | ||
7 | CONFIG_HIGH_RES_TIMERS=y | ||
8 | CONFIG_IKCONFIG=y | ||
9 | CONFIG_IKCONFIG_PROC=y | ||
10 | CONFIG_NAMESPACES=y | ||
11 | # CONFIG_UTS_NS is not set | ||
12 | # CONFIG_PID_NS is not set | ||
13 | CONFIG_BLK_DEV_INITRD=y | ||
14 | CONFIG_INITRAMFS_SOURCE="../../arc_initramfs_hs/" | ||
15 | CONFIG_EMBEDDED=y | ||
16 | CONFIG_PERF_EVENTS=y | ||
17 | # CONFIG_VM_EVENT_COUNTERS is not set | ||
18 | # CONFIG_COMPAT_BRK is not set | ||
19 | CONFIG_SLAB=y | ||
20 | CONFIG_KPROBES=y | ||
21 | CONFIG_MODULES=y | ||
22 | # CONFIG_LBDAF is not set | ||
23 | # CONFIG_BLK_DEV_BSG is not set | ||
24 | # CONFIG_IOSCHED_DEADLINE is not set | ||
25 | # CONFIG_IOSCHED_CFQ is not set | ||
26 | CONFIG_ARC_PLAT_SIM=y | ||
27 | CONFIG_ISA_ARCV2=y | ||
28 | CONFIG_SMP=y | ||
29 | CONFIG_ARC_BUILTIN_DTB_NAME="zebu_hs_idu" | ||
30 | CONFIG_PREEMPT=y | ||
31 | # CONFIG_COMPACTION is not set | ||
32 | CONFIG_NET=y | ||
33 | CONFIG_PACKET=y | ||
34 | CONFIG_PACKET_DIAG=y | ||
35 | CONFIG_UNIX=y | ||
36 | CONFIG_UNIX_DIAG=y | ||
37 | CONFIG_NET_KEY=y | ||
38 | CONFIG_INET=y | ||
39 | # CONFIG_INET_XFRM_MODE_TRANSPORT is not set | ||
40 | # CONFIG_INET_XFRM_MODE_TUNNEL is not set | ||
41 | # CONFIG_INET_XFRM_MODE_BEET is not set | ||
42 | # CONFIG_IPV6 is not set | ||
43 | # CONFIG_WIRELESS is not set | ||
44 | CONFIG_DEVTMPFS=y | ||
45 | # CONFIG_STANDALONE is not set | ||
46 | # CONFIG_PREVENT_FIRMWARE_BUILD is not set | ||
47 | # CONFIG_FIRMWARE_IN_KERNEL is not set | ||
48 | # CONFIG_BLK_DEV is not set | ||
49 | CONFIG_NETDEVICES=y | ||
50 | # CONFIG_NET_VENDOR_ARC is not set | ||
51 | # CONFIG_NET_VENDOR_BROADCOM is not set | ||
52 | # CONFIG_NET_VENDOR_INTEL is not set | ||
53 | # CONFIG_NET_VENDOR_MARVELL is not set | ||
54 | # CONFIG_NET_VENDOR_MICREL is not set | ||
55 | # CONFIG_NET_VENDOR_NATSEMI is not set | ||
56 | # CONFIG_NET_VENDOR_SEEQ is not set | ||
57 | # CONFIG_NET_VENDOR_STMICRO is not set | ||
58 | # CONFIG_NET_VENDOR_VIA is not set | ||
59 | # CONFIG_NET_VENDOR_WIZNET is not set | ||
60 | # CONFIG_WLAN is not set | ||
61 | CONFIG_INPUT_EVDEV=y | ||
62 | CONFIG_MOUSE_PS2_TOUCHKIT=y | ||
63 | # CONFIG_SERIO_SERPORT is not set | ||
64 | CONFIG_SERIO_ARC_PS2=y | ||
65 | # CONFIG_LEGACY_PTYS is not set | ||
66 | # CONFIG_DEVKMEM is not set | ||
67 | CONFIG_SERIAL_8250=y | ||
68 | CONFIG_SERIAL_8250_CONSOLE=y | ||
69 | CONFIG_SERIAL_8250_NR_UARTS=1 | ||
70 | CONFIG_SERIAL_8250_RUNTIME_UARTS=1 | ||
71 | CONFIG_SERIAL_8250_DW=y | ||
72 | CONFIG_SERIAL_OF_PLATFORM=y | ||
73 | # CONFIG_HW_RANDOM is not set | ||
74 | # CONFIG_HWMON is not set | ||
75 | CONFIG_FB=y | ||
76 | CONFIG_FRAMEBUFFER_CONSOLE=y | ||
77 | CONFIG_LOGO=y | ||
78 | # CONFIG_HID is not set | ||
79 | # CONFIG_USB_SUPPORT is not set | ||
80 | # CONFIG_IOMMU_SUPPORT is not set | ||
81 | CONFIG_EXT2_FS=y | ||
82 | CONFIG_EXT2_FS_XATTR=y | ||
83 | CONFIG_TMPFS=y | ||
84 | # CONFIG_MISC_FILESYSTEMS is not set | ||
85 | CONFIG_NFS_FS=y | ||
86 | # CONFIG_ENABLE_WARN_DEPRECATED is not set | ||
87 | # CONFIG_ENABLE_MUST_CHECK is not set | ||
88 | CONFIG_LOCKUP_DETECTOR=y | ||
89 | # CONFIG_DEBUG_PREEMPT is not set | ||
diff --git a/arch/arc/plat-sim/platform.c b/arch/arc/plat-sim/platform.c index e4fe51456808..aea87389e44b 100644 --- a/arch/arc/plat-sim/platform.c +++ b/arch/arc/plat-sim/platform.c | |||
@@ -24,6 +24,7 @@ static const char *simulation_compat[] __initconst = { | |||
24 | "snps,nsim_hs", | 24 | "snps,nsim_hs", |
25 | "snps,nsimosci", | 25 | "snps,nsimosci", |
26 | "snps,nsimosci_hs", | 26 | "snps,nsimosci_hs", |
27 | "snps,zebu_hs", | ||
27 | NULL, | 28 | NULL, |
28 | }; | 29 | }; |
29 | 30 | ||