Skip to contentSkip to conversation

sparc32: implement proper LEON support in head_32 (before highmem)

PATCH In review Sam Ravnborg 1 participant 1 message May 26, 2012 SPARC + UltraSPARC (sparc/sparc64)

lore
Share & tools
lore
#0 lore raw

PATCH 2/15 sparc32: implement proper LEON support in head_32 (before highmem)

Use PSR to check if the CPU is LEON and jump to LEON specific code in this case.

Added a few constants to psr.h to increase readability.

Cc Daniel Hellstrom <[email protected]>
Cc Konrad Eisele <[email protected]>
---
 arch/sparc/include/asm/psr.h |    6 ++++
 arch/sparc/kernel/head_32.S  |   58 ++++++++++++++++++++++++++++++++++--------
 2 files changed, 53 insertions(+), 11 deletions(-)
arch/sparc/include/asm/psr.h +6 -0
index b8c0e5f..c02c735 100644
@@ -35,6 +35,12 @@
 #define PSR_VERS    0x0f000000         /* cpu-version field          */
 #define PSR_IMPL    0xf0000000         /* cpu-implementation field   */
 
+#define PSR_IMPL_SHIFT		28
+#define PSR_IMPL_SHIFTED_MASK	0xf
+
+#define PSR_IMPL_TI		0x4
+#define PSR_IMPL_LEON		0xf
+
 #ifdef __KERNEL__
 
 #ifndef __ASSEMBLY__
arch/sparc/kernel/head_32.S +47 -11

97 lines not on this page · raw message

Signature · 1 line
1.6.0.6