diff options
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/Kconfig | 2 | ||||
-rw-r--r-- | arch/arm/include/asm/ptrace.h | 8 | ||||
-rw-r--r-- | arch/arm/kernel/process.c | 9 |
3 files changed, 14 insertions, 5 deletions
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index e25419817791..41266af5dfc8 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
@@ -2270,7 +2270,7 @@ source "kernel/power/Kconfig" | |||
2270 | config ARCH_SUSPEND_POSSIBLE | 2270 | config ARCH_SUSPEND_POSSIBLE |
2271 | depends on !ARCH_S5PC100 | 2271 | depends on !ARCH_S5PC100 |
2272 | depends on CPU_ARM920T || CPU_ARM926T || CPU_FEROCEON || CPU_SA1100 || \ | 2272 | depends on CPU_ARM920T || CPU_ARM926T || CPU_FEROCEON || CPU_SA1100 || \ |
2273 | CPU_V6 || CPU_V6K || CPU_V7 || CPU_XSC3 || CPU_XSCALE || CPU_MOHAWK | 2273 | CPU_V6 || CPU_V6K || CPU_V7 || CPU_V7M || CPU_XSC3 || CPU_XSCALE || CPU_MOHAWK |
2274 | def_bool y | 2274 | def_bool y |
2275 | 2275 | ||
2276 | config ARM_CPU_SUSPEND | 2276 | config ARM_CPU_SUSPEND |
diff --git a/arch/arm/include/asm/ptrace.h b/arch/arm/include/asm/ptrace.h index 04c99f36ff7f..627a03ebb987 100644 --- a/arch/arm/include/asm/ptrace.h +++ b/arch/arm/include/asm/ptrace.h | |||
@@ -27,9 +27,13 @@ struct pt_regs { | |||
27 | #define thumb_mode(regs) (0) | 27 | #define thumb_mode(regs) (0) |
28 | #endif | 28 | #endif |
29 | 29 | ||
30 | #ifndef CONFIG_CPU_V7M | ||
30 | #define isa_mode(regs) \ | 31 | #define isa_mode(regs) \ |
31 | ((((regs)->ARM_cpsr & PSR_J_BIT) >> 23) | \ | 32 | ((((regs)->ARM_cpsr & PSR_J_BIT) >> (__ffs(PSR_J_BIT) - 1)) | \ |
32 | (((regs)->ARM_cpsr & PSR_T_BIT) >> 5)) | 33 | (((regs)->ARM_cpsr & PSR_T_BIT) >> (__ffs(PSR_T_BIT)))) |
34 | #else | ||
35 | #define isa_mode(regs) 1 /* Thumb */ | ||
36 | #endif | ||
33 | 37 | ||
34 | #define processor_mode(regs) \ | 38 | #define processor_mode(regs) \ |
35 | ((regs)->ARM_cpsr & MODE_MASK) | 39 | ((regs)->ARM_cpsr & MODE_MASK) |
diff --git a/arch/arm/kernel/process.c b/arch/arm/kernel/process.c index 92f7b15dd221..204f7d273319 100644 --- a/arch/arm/kernel/process.c +++ b/arch/arm/kernel/process.c | |||
@@ -48,14 +48,14 @@ unsigned long __stack_chk_guard __read_mostly; | |||
48 | EXPORT_SYMBOL(__stack_chk_guard); | 48 | EXPORT_SYMBOL(__stack_chk_guard); |
49 | #endif | 49 | #endif |
50 | 50 | ||
51 | static const char *processor_modes[] = { | 51 | static const char *processor_modes[] __maybe_unused = { |
52 | "USER_26", "FIQ_26" , "IRQ_26" , "SVC_26" , "UK4_26" , "UK5_26" , "UK6_26" , "UK7_26" , | 52 | "USER_26", "FIQ_26" , "IRQ_26" , "SVC_26" , "UK4_26" , "UK5_26" , "UK6_26" , "UK7_26" , |
53 | "UK8_26" , "UK9_26" , "UK10_26", "UK11_26", "UK12_26", "UK13_26", "UK14_26", "UK15_26", | 53 | "UK8_26" , "UK9_26" , "UK10_26", "UK11_26", "UK12_26", "UK13_26", "UK14_26", "UK15_26", |
54 | "USER_32", "FIQ_32" , "IRQ_32" , "SVC_32" , "UK4_32" , "UK5_32" , "UK6_32" , "ABT_32" , | 54 | "USER_32", "FIQ_32" , "IRQ_32" , "SVC_32" , "UK4_32" , "UK5_32" , "UK6_32" , "ABT_32" , |
55 | "UK8_32" , "UK9_32" , "UK10_32", "UND_32" , "UK12_32", "UK13_32", "UK14_32", "SYS_32" | 55 | "UK8_32" , "UK9_32" , "UK10_32", "UND_32" , "UK12_32", "UK13_32", "UK14_32", "SYS_32" |
56 | }; | 56 | }; |
57 | 57 | ||
58 | static const char *isa_modes[] = { | 58 | static const char *isa_modes[] __maybe_unused = { |
59 | "ARM" , "Thumb" , "Jazelle", "ThumbEE" | 59 | "ARM" , "Thumb" , "Jazelle", "ThumbEE" |
60 | }; | 60 | }; |
61 | 61 | ||
@@ -276,12 +276,17 @@ void __show_regs(struct pt_regs *regs) | |||
276 | buf[3] = flags & PSR_V_BIT ? 'V' : 'v'; | 276 | buf[3] = flags & PSR_V_BIT ? 'V' : 'v'; |
277 | buf[4] = '\0'; | 277 | buf[4] = '\0'; |
278 | 278 | ||
279 | #ifndef CONFIG_CPU_V7M | ||
279 | printk("Flags: %s IRQs o%s FIQs o%s Mode %s ISA %s Segment %s\n", | 280 | printk("Flags: %s IRQs o%s FIQs o%s Mode %s ISA %s Segment %s\n", |
280 | buf, interrupts_enabled(regs) ? "n" : "ff", | 281 | buf, interrupts_enabled(regs) ? "n" : "ff", |
281 | fast_interrupts_enabled(regs) ? "n" : "ff", | 282 | fast_interrupts_enabled(regs) ? "n" : "ff", |
282 | processor_modes[processor_mode(regs)], | 283 | processor_modes[processor_mode(regs)], |
283 | isa_modes[isa_mode(regs)], | 284 | isa_modes[isa_mode(regs)], |
284 | get_fs() == get_ds() ? "kernel" : "user"); | 285 | get_fs() == get_ds() ? "kernel" : "user"); |
286 | #else | ||
287 | printk("xPSR: %08lx\n", regs->ARM_cpsr); | ||
288 | #endif | ||
289 | |||
285 | #ifdef CONFIG_CPU_CP15 | 290 | #ifdef CONFIG_CPU_CP15 |
286 | { | 291 | { |
287 | unsigned int ctrl; | 292 | unsigned int ctrl; |