aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-clps711x
diff options
context:
space:
mode:
authorAlexander Shiyan <shc_work@mail.ru>2012-10-10 11:45:33 -0400
committerArnd Bergmann <arnd@arndb.de>2012-10-25 11:22:53 -0400
commit2a5528912d15a4db760c5eb7fa3e1efdd5c87371 (patch)
treece16600893264c827e3bc3abc680ae9502bf25e5 /arch/arm/mach-clps711x
parent658b14627c2d948d3d3827ff651cef2737fe5005 (diff)
ARM: clps711x: merge files related to EDB7211-board into one
Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/arm/mach-clps711x')
-rw-r--r--arch/arm/mach-clps711x/Makefile2
-rw-r--r--arch/arm/mach-clps711x/edb7211-mm.c82
-rw-r--r--arch/arm/mach-clps711x/edb7211.c (renamed from arch/arm/mach-clps711x/edb7211-arch.c)58
3 files changed, 41 insertions, 101 deletions
diff --git a/arch/arm/mach-clps711x/Makefile b/arch/arm/mach-clps711x/Makefile
index 6da6940b3656..9cf2d1c6a548 100644
--- a/arch/arm/mach-clps711x/Makefile
+++ b/arch/arm/mach-clps711x/Makefile
@@ -12,6 +12,6 @@ obj- :=
12obj-$(CONFIG_ARCH_AUTCPU12) += autcpu12.o 12obj-$(CONFIG_ARCH_AUTCPU12) += autcpu12.o
13obj-$(CONFIG_ARCH_CDB89712) += cdb89712.o 13obj-$(CONFIG_ARCH_CDB89712) += cdb89712.o
14obj-$(CONFIG_ARCH_CLEP7312) += clep7312.o 14obj-$(CONFIG_ARCH_CLEP7312) += clep7312.o
15obj-$(CONFIG_ARCH_EDB7211) += edb7211-arch.o edb7211-mm.o 15obj-$(CONFIG_ARCH_EDB7211) += edb7211.o
16obj-$(CONFIG_ARCH_FORTUNET) += fortunet.o 16obj-$(CONFIG_ARCH_FORTUNET) += fortunet.o
17obj-$(CONFIG_ARCH_P720T) += p720t.o 17obj-$(CONFIG_ARCH_P720T) += p720t.o
diff --git a/arch/arm/mach-clps711x/edb7211-mm.c b/arch/arm/mach-clps711x/edb7211-mm.c
deleted file mode 100644
index 054eaa05f5c8..000000000000
--- a/arch/arm/mach-clps711x/edb7211-mm.c
+++ /dev/null
@@ -1,82 +0,0 @@
1/*
2 * linux/arch/arm/mach-clps711x/mm.c
3 *
4 * Extra MM routines for the EDB7211 board
5 *
6 * Copyright (C) 2000, 2001 Blue Mug, Inc. All Rights Reserved.
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program; if not, write to the Free Software
20 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21 */
22#include <linux/kernel.h>
23#include <linux/init.h>
24#include <linux/bug.h>
25
26#include <mach/hardware.h>
27#include <asm/page.h>
28#include <asm/sizes.h>
29
30#include <asm/mach/map.h>
31
32extern void clps711x_map_io(void);
33
34/*
35 * The on-chip registers are given a size of 1MB so that a section can
36 * be used to map them; this saves a page table. This is the place to
37 * add mappings for ROM, expansion memory, PCMCIA, etc. (if static
38 * mappings are chosen for those areas).
39 *
40 * Here is a physical memory map (to be fleshed out later):
41 *
42 * Physical Address Size Description
43 * ----------------- ----- ---------------------------------
44 * c0000000-c001ffff 128KB reserved for video RAM [1]
45 * c0020000-c0023fff 16KB parameters (see Documentation/arm/Setup)
46 * c0024000-c0027fff 16KB swapper_pg_dir (task 0 page directory)
47 * c0028000-... kernel image (TEXTADDR)
48 *
49 * [1] Unused pages should be given back to the VM; they are not yet.
50 * The parameter block should also be released (not sure if this
51 * happens).
52 */
53static struct map_desc edb7211_io_desc[] __initdata = {
54 { /* Memory-mapped extra keyboard row */
55 .virtual = IO_ADDRESS(EP7211_PHYS_EXTKBD),
56 .pfn = __phys_to_pfn(EP7211_PHYS_EXTKBD),
57 .length = SZ_1M,
58 .type = MT_DEVICE,
59 }, { /* CS8900A Ethernet chip */
60 .virtual = IO_ADDRESS(EP7211_PHYS_CS8900A),
61 .pfn = __phys_to_pfn(EP7211_PHYS_CS8900A),
62 .length = SZ_1M,
63 .type = MT_DEVICE,
64 }, { /* Flash bank 0 */
65 .virtual = IO_ADDRESS(EP7211_PHYS_FLASH1),
66 .pfn = __phys_to_pfn(EP7211_PHYS_FLASH1),
67 .length = SZ_8M,
68 .type = MT_DEVICE,
69 }, { /* Flash bank 1 */
70 .virtual = IO_ADDRESS(EP7211_PHYS_FLASH2),
71 .pfn = __phys_to_pfn(EP7211_PHYS_FLASH2),
72 .length = SZ_8M,
73 .type = MT_DEVICE,
74 }
75};
76
77void __init edb7211_map_io(void)
78{
79 clps711x_map_io();
80 iotable_init(edb7211_io_desc, ARRAY_SIZE(edb7211_io_desc));
81}
82
diff --git a/arch/arm/mach-clps711x/edb7211-arch.c b/arch/arm/mach-clps711x/edb7211.c
index 5fad0b4f40ad..88f46908de24 100644
--- a/arch/arm/mach-clps711x/edb7211-arch.c
+++ b/arch/arm/mach-clps711x/edb7211.c
@@ -1,39 +1,61 @@
1/* 1/*
2 * linux/arch/arm/mach-clps711x/arch-edb7211.c
3 *
4 * Copyright (C) 2000, 2001 Blue Mug, Inc. All Rights Reserved. 2 * Copyright (C) 2000, 2001 Blue Mug, Inc. All Rights Reserved.
5 * 3 *
6 * This program is free software; you can redistribute it and/or modify 4 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by 5 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or 6 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version. 7 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 */ 8 */
9
20#include <linux/init.h> 10#include <linux/init.h>
21#include <linux/memblock.h> 11#include <linux/memblock.h>
22#include <linux/types.h> 12#include <linux/types.h>
23#include <linux/string.h>
24 13
25#include <asm/setup.h> 14#include <asm/setup.h>
26#include <asm/mach-types.h> 15#include <asm/mach/map.h>
27#include <asm/mach/arch.h> 16#include <asm/mach/arch.h>
17#include <asm/mach-types.h>
18
19#include <mach/hardware.h>
28 20
29#include "common.h" 21#include "common.h"
30 22
31extern void edb7211_map_io(void); 23#define VIDEORAM_SIZE SZ_128K
24
25static struct map_desc edb7211_io_desc[] __initdata = {
26 { /* Memory-mapped extra keyboard row */
27 .virtual = IO_ADDRESS(EP7211_PHYS_EXTKBD),
28 .pfn = __phys_to_pfn(EP7211_PHYS_EXTKBD),
29 .length = SZ_1M,
30 .type = MT_DEVICE,
31 }, { /* CS8900A Ethernet chip */
32 .virtual = IO_ADDRESS(EP7211_PHYS_CS8900A),
33 .pfn = __phys_to_pfn(EP7211_PHYS_CS8900A),
34 .length = SZ_1M,
35 .type = MT_DEVICE,
36 }, { /* Flash bank 0 */
37 .virtual = IO_ADDRESS(EP7211_PHYS_FLASH1),
38 .pfn = __phys_to_pfn(EP7211_PHYS_FLASH1),
39 .length = SZ_8M,
40 .type = MT_DEVICE,
41 }, { /* Flash bank 1 */
42 .virtual = IO_ADDRESS(EP7211_PHYS_FLASH2),
43 .pfn = __phys_to_pfn(EP7211_PHYS_FLASH2),
44 .length = SZ_8M,
45 .type = MT_DEVICE,
46 },
47};
48
49void __init edb7211_map_io(void)
50{
51 clps711x_map_io();
52 iotable_init(edb7211_io_desc, ARRAY_SIZE(edb7211_io_desc));
53}
32 54
33/* Reserve screen memory region at the start of main system memory. */ 55/* Reserve screen memory region at the start of main system memory. */
34static void __init edb7211_reserve(void) 56static void __init edb7211_reserve(void)
35{ 57{
36 memblock_reserve(PHYS_OFFSET, 0x00020000); 58 memblock_reserve(PHYS_OFFSET, VIDEORAM_SIZE);
37} 59}
38 60
39static void __init 61static void __init
@@ -48,15 +70,15 @@ fixup_edb7211(struct tag *tags, char **cmdline, struct meminfo *mi)
48 * not using that information yet. 70 * not using that information yet.
49 */ 71 */
50 mi->bank[0].start = 0xc0000000; 72 mi->bank[0].start = 0xc0000000;
51 mi->bank[0].size = 8*1024*1024; 73 mi->bank[0].size = SZ_8M;
52 mi->bank[1].start = 0xc1000000; 74 mi->bank[1].start = 0xc1000000;
53 mi->bank[1].size = 8*1024*1024; 75 mi->bank[1].size = SZ_8M;
54 mi->nr_banks = 2; 76 mi->nr_banks = 2;
55} 77}
56 78
57MACHINE_START(EDB7211, "CL-EDB7211 (EP7211 eval board)") 79MACHINE_START(EDB7211, "CL-EDB7211 (EP7211 eval board)")
58 /* Maintainer: Jon McClintock */ 80 /* Maintainer: Jon McClintock */
59 .atag_offset = 0x20100, /* 0xc0000000 - 0xc001ffff can be video RAM */ 81 .atag_offset = VIDEORAM_SIZE + 0x100,
60 .fixup = fixup_edb7211, 82 .fixup = fixup_edb7211,
61 .map_io = edb7211_map_io, 83 .map_io = edb7211_map_io,
62 .reserve = edb7211_reserve, 84 .reserve = edb7211_reserve,