diff options
author | Greg Ungerer <gerg@uclinux.org> | 2010-11-08 19:12:29 -0500 |
---|---|---|
committer | Greg Ungerer <gerg@uclinux.org> | 2011-01-05 00:19:18 -0500 |
commit | a12cf0a8c6e2763ac865aa31f296557e07432b8a (patch) | |
tree | 5b44bfe7aca132e1a3f0cd2bd7bbe2291b56a663 | |
parent | 63e83c8a52031555b1e724f98a33f1838dee6345 (diff) |
m68knommu: create bit definitions for the version 2 ColdFire cache controller
The version 2 ColdFire CPU based cores all contain a similar cache
controller unit. Create a set of bit flag definitions for the supporting
registers.
Signed-off-by: Greg Ungerer <gerg@uclinux.org>
-rw-r--r-- | arch/m68k/include/asm/m5206sim.h | 2 | ||||
-rw-r--r-- | arch/m68k/include/asm/m520xsim.h | 5 | ||||
-rw-r--r-- | arch/m68k/include/asm/m523xsim.h | 2 | ||||
-rw-r--r-- | arch/m68k/include/asm/m5249sim.h | 2 | ||||
-rw-r--r-- | arch/m68k/include/asm/m5272sim.h | 2 | ||||
-rw-r--r-- | arch/m68k/include/asm/m527xsim.h | 1 | ||||
-rw-r--r-- | arch/m68k/include/asm/m528xsim.h | 2 | ||||
-rw-r--r-- | arch/m68k/include/asm/m52xxacr.h | 56 |
8 files changed, 72 insertions, 0 deletions
diff --git a/arch/m68k/include/asm/m5206sim.h b/arch/m68k/include/asm/m5206sim.h index aa7ee48d5059..561b03b5ddf8 100644 --- a/arch/m68k/include/asm/m5206sim.h +++ b/arch/m68k/include/asm/m5206sim.h | |||
@@ -15,6 +15,8 @@ | |||
15 | #define CPU_NAME "COLDFIRE(m5206)" | 15 | #define CPU_NAME "COLDFIRE(m5206)" |
16 | #define CPU_INSTR_PER_JIFFY 3 | 16 | #define CPU_INSTR_PER_JIFFY 3 |
17 | 17 | ||
18 | #include <asm/m52xxacr.h> | ||
19 | |||
18 | /* | 20 | /* |
19 | * Define the 5206 SIM register set addresses. | 21 | * Define the 5206 SIM register set addresses. |
20 | */ | 22 | */ |
diff --git a/arch/m68k/include/asm/m520xsim.h b/arch/m68k/include/asm/m520xsim.h index 8cd8bce38594..88ed8239fe4e 100644 --- a/arch/m68k/include/asm/m520xsim.h +++ b/arch/m68k/include/asm/m520xsim.h | |||
@@ -14,6 +14,8 @@ | |||
14 | #define CPU_NAME "COLDFIRE(m520x)" | 14 | #define CPU_NAME "COLDFIRE(m520x)" |
15 | #define CPU_INSTR_PER_JIFFY 3 | 15 | #define CPU_INSTR_PER_JIFFY 3 |
16 | 16 | ||
17 | #include <asm/m52xxacr.h> | ||
18 | |||
17 | /* | 19 | /* |
18 | * Define the 520x SIM register set addresses. | 20 | * Define the 520x SIM register set addresses. |
19 | */ | 21 | */ |
@@ -57,6 +59,9 @@ | |||
57 | #define MCFSIM_SDCS0 0x000a8110 /* SDRAM Chip Select 0 Configuration */ | 59 | #define MCFSIM_SDCS0 0x000a8110 /* SDRAM Chip Select 0 Configuration */ |
58 | #define MCFSIM_SDCS1 0x000a8114 /* SDRAM Chip Select 1 Configuration */ | 60 | #define MCFSIM_SDCS1 0x000a8114 /* SDRAM Chip Select 1 Configuration */ |
59 | 61 | ||
62 | /* | ||
63 | * EPORT and GPIO registers. | ||
64 | */ | ||
60 | #define MCFEPORT_EPDDR 0xFC088002 | 65 | #define MCFEPORT_EPDDR 0xFC088002 |
61 | #define MCFEPORT_EPDR 0xFC088004 | 66 | #define MCFEPORT_EPDR 0xFC088004 |
62 | #define MCFEPORT_EPPDR 0xFC088005 | 67 | #define MCFEPORT_EPPDR 0xFC088005 |
diff --git a/arch/m68k/include/asm/m523xsim.h b/arch/m68k/include/asm/m523xsim.h index 4ec0f93a7ece..4ad7a00257a8 100644 --- a/arch/m68k/include/asm/m523xsim.h +++ b/arch/m68k/include/asm/m523xsim.h | |||
@@ -14,6 +14,8 @@ | |||
14 | #define CPU_NAME "COLDFIRE(m523x)" | 14 | #define CPU_NAME "COLDFIRE(m523x)" |
15 | #define CPU_INSTR_PER_JIFFY 3 | 15 | #define CPU_INSTR_PER_JIFFY 3 |
16 | 16 | ||
17 | #include <asm/m52xxacr.h> | ||
18 | |||
17 | /* | 19 | /* |
18 | * Define the 523x SIM register set addresses. | 20 | * Define the 523x SIM register set addresses. |
19 | */ | 21 | */ |
diff --git a/arch/m68k/include/asm/m5249sim.h b/arch/m68k/include/asm/m5249sim.h index 21d0bbfbc0c9..4908b118f2fd 100644 --- a/arch/m68k/include/asm/m5249sim.h +++ b/arch/m68k/include/asm/m5249sim.h | |||
@@ -14,6 +14,8 @@ | |||
14 | #define CPU_NAME "COLDFIRE(m5249)" | 14 | #define CPU_NAME "COLDFIRE(m5249)" |
15 | #define CPU_INSTR_PER_JIFFY 3 | 15 | #define CPU_INSTR_PER_JIFFY 3 |
16 | 16 | ||
17 | #include <asm/m52xxacr.h> | ||
18 | |||
17 | /* | 19 | /* |
18 | * Define the 5249 SIM register set addresses. | 20 | * Define the 5249 SIM register set addresses. |
19 | */ | 21 | */ |
diff --git a/arch/m68k/include/asm/m5272sim.h b/arch/m68k/include/asm/m5272sim.h index 974c448c098e..b7cc50abc831 100644 --- a/arch/m68k/include/asm/m5272sim.h +++ b/arch/m68k/include/asm/m5272sim.h | |||
@@ -15,6 +15,8 @@ | |||
15 | #define CPU_NAME "COLDFIRE(m5272)" | 15 | #define CPU_NAME "COLDFIRE(m5272)" |
16 | #define CPU_INSTR_PER_JIFFY 3 | 16 | #define CPU_INSTR_PER_JIFFY 3 |
17 | 17 | ||
18 | #include <asm/m52xxacr.h> | ||
19 | |||
18 | /* | 20 | /* |
19 | * Define the 5272 SIM register set addresses. | 21 | * Define the 5272 SIM register set addresses. |
20 | */ | 22 | */ |
diff --git a/arch/m68k/include/asm/m527xsim.h b/arch/m68k/include/asm/m527xsim.h index 8a5a1ab57d01..e8042e8bc003 100644 --- a/arch/m68k/include/asm/m527xsim.h +++ b/arch/m68k/include/asm/m527xsim.h | |||
@@ -14,6 +14,7 @@ | |||
14 | #define CPU_NAME "COLDFIRE(m527x)" | 14 | #define CPU_NAME "COLDFIRE(m527x)" |
15 | #define CPU_INSTR_PER_JIFFY 3 | 15 | #define CPU_INSTR_PER_JIFFY 3 |
16 | 16 | ||
17 | #include <asm/m52xxacr.h> | ||
17 | 18 | ||
18 | /* | 19 | /* |
19 | * Define the 5270/5271 SIM register set addresses. | 20 | * Define the 5270/5271 SIM register set addresses. |
diff --git a/arch/m68k/include/asm/m528xsim.h b/arch/m68k/include/asm/m528xsim.h index 47c851ef78d3..a6d2f4d9aaa0 100644 --- a/arch/m68k/include/asm/m528xsim.h +++ b/arch/m68k/include/asm/m528xsim.h | |||
@@ -14,6 +14,8 @@ | |||
14 | #define CPU_NAME "COLDFIRE(m528x)" | 14 | #define CPU_NAME "COLDFIRE(m528x)" |
15 | #define CPU_INSTR_PER_JIFFY 3 | 15 | #define CPU_INSTR_PER_JIFFY 3 |
16 | 16 | ||
17 | #include <asm/m52xxacr.h> | ||
18 | |||
17 | /* | 19 | /* |
18 | * Define the 5280/5282 SIM register set addresses. | 20 | * Define the 5280/5282 SIM register set addresses. |
19 | */ | 21 | */ |
diff --git a/arch/m68k/include/asm/m52xxacr.h b/arch/m68k/include/asm/m52xxacr.h new file mode 100644 index 000000000000..4c92d999ee01 --- /dev/null +++ b/arch/m68k/include/asm/m52xxacr.h | |||
@@ -0,0 +1,56 @@ | |||
1 | /****************************************************************************/ | ||
2 | |||
3 | /* | ||
4 | * m52xxacr.h -- ColdFire version 2 core cache support | ||
5 | * | ||
6 | * (C) Copyright 2010, Greg Ungerer <gerg@snapgear.com> | ||
7 | */ | ||
8 | |||
9 | /****************************************************************************/ | ||
10 | #ifndef m52xxacr_h | ||
11 | #define m52xxacr_h | ||
12 | /****************************************************************************/ | ||
13 | |||
14 | /* | ||
15 | * All varients of the ColdFire using version 2 cores have a similar | ||
16 | * cache setup. Although not absolutely identical the cache register | ||
17 | * definitions are compatible for all of them. Mostly they support a | ||
18 | * configurable cache memory that can be instruction only, data only, | ||
19 | * or split instruction and data. The exception is the very old version 2 | ||
20 | * core based parts, like the 5206(e), 5249 and 5272, which are instruction | ||
21 | * cache only. Cache size varies from 2k up to 16k. | ||
22 | */ | ||
23 | |||
24 | /* | ||
25 | * Define the Cache Control register flags. | ||
26 | */ | ||
27 | #define CACR_CENB 0x80000000 /* Enable cache */ | ||
28 | #define CACR_CDPI 0x10000000 /* Disable invalidation by CPUSHL */ | ||
29 | #define CACR_CFRZ 0x08000000 /* Cache freeze mode */ | ||
30 | #define CACR_CINV 0x01000000 /* Invalidate cache */ | ||
31 | #define CACR_DISI 0x00800000 /* Disable instruction cache */ | ||
32 | #define CACR_DISD 0x00400000 /* Disable data cache */ | ||
33 | #define CACR_INVI 0x00200000 /* Invalidate instruction cache */ | ||
34 | #define CACR_INVD 0x00100000 /* Invalidate data cache */ | ||
35 | #define CACR_CEIB 0x00000400 /* Non-cachable instruction burst */ | ||
36 | #define CACR_DCM 0x00000200 /* Default cache mode */ | ||
37 | #define CACR_DBWE 0x00000100 /* Buffered write enable */ | ||
38 | #define CACR_DWP 0x00000020 /* Write protection */ | ||
39 | #define CACR_EUSP 0x00000010 /* Enable separate user a7 */ | ||
40 | |||
41 | /* | ||
42 | * Define the Access Control register flags. | ||
43 | */ | ||
44 | #define ACR_BASE_POS 24 /* Address Base (upper 8 bits) */ | ||
45 | #define ACR_MASK_POS 16 /* Address Mask (next 8 bits) */ | ||
46 | #define ACR_ENABLE 0x00008000 /* Enable this ACR */ | ||
47 | #define ACR_USER 0x00000000 /* Allow only user accesses */ | ||
48 | #define ACR_SUPER 0x00002000 /* Allow supervisor access only */ | ||
49 | #define ACR_ANY 0x00004000 /* Allow any access type */ | ||
50 | #define ACR_CENB 0x00000000 /* Caching of region enabled */ | ||
51 | #define ACR_CDIS 0x00000040 /* Caching of region disabled */ | ||
52 | #define ACR_BWE 0x00000020 /* Write buffer enabled */ | ||
53 | #define ACR_WPROTECT 0x00000004 /* Write protect region */ | ||
54 | |||
55 | /****************************************************************************/ | ||
56 | #endif /* m52xxsim_h */ | ||