From: axel.lin@ingics.com (Axel Lin)
To: linux-arm-kernel@lists.infradead.org
Subject: Question about debugging Bad mode in â handler detected
Date: Fri, 03 Jan 2014 22:46:25 +0800 [thread overview]
Message-ID: <1388760385.31617.2.camel@phoenix> (raw)
Hi list,
I hit a "Bad mode in ? handler detected" oops.
The first line of the message looks un-readable, so I print the reason index as well.
The reason index is "4", so it does not exist in the handler array.
static const char *handler[]= { "prefetch abort", "data abort", "address exception", "interrupt" };
I'd appreciate if someone can give me advices and comments to debug this.
I'm testing on Linus' tree + out-of-tree patches for this ARM7TDMI SoC.
BTW,
It seems I can hit his oops only when CONFIG_DEBUG_MUTEXES is not set.
If I set CONFIG_DEBUG_MUTEXES, the system can boot to busybox.
Below is the oops message:
Bad mode in ? handler detected reason=4
Internal error: Oops - bad mode: 0 [#1] PREEMPT ARM
Modules linked in:
CPU: 0 PID: 19 Comm: spi0 Not tainted 3.13.0-rc6-00247-g228432c-dirty #2347
task: 01e4efc0 ti: 01eec000 task.ti: 01eec000
PC is at 0xa04
LR is at gpl327xx_spi_transfer_one+0xb0/0x238
pc : [<00000a04>] lr : [<00127f94>] psr: 200000d2
sp : 01eedea8 ip : 0000131f fp : 001cf02c
r10: 01eec000 r9 : 00000000 r8 : 0000105e
r7 : 00000000 r6 : 000000f1 r5 : 01e7b570 r4 : 00000004
r3 : fffff104 r2 : c0080000 r1 : 00008000 r0 : 01e7b570
Flags: nzCv IRQs off FIQs off Mode IRQ_32 ISA ARM Segment kernel
Process spi0 (pid: 19, stack limit = 0x01eec1c0)
Stack: (0x01eedea8 to 0x01eee000)
dea0: 01e7b570 00008000 c0080000 fffff104 00000004 01e7b570
dec0: 000000f1 00000000 0000105e 00000000 01eec000 001cf02c 0000131f 01eedea8
dee0: 00127f94 00000a04 200000d2 ffffffff 01e35db8 00000000 01e7b400 01e35d90
df00: 00000001 00126cf0 00000000 01e7b540 0018de00 01e7b514 01e7b400 60000053
df20: 00000001 00000001 00000000 00000000 00000000 00126b28 01e4efc0 01e7b500
df40: 01e7b514 01eec000 00000000 00028f6c 00000000 01eeb0c0 00000000 01e7b500
df60: 00028eac 00000000 00000000 00029184 00000000 00000000 00000000 01e7b500
df80: 00000000 01eedf84 01eedf84 00000000 01eedf90 01eedf90 01eedfac 01eeb0c0
dfa0: 000290d4 00000000 00000000 000091f0 00000000 00000000 00000000 00000000
dfc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
dfe0: 00000000 00000000 00000000 00000000 00000013 00000000 00000000 00000000
[<00127f94>] (gpl327xx_spi_transfer_one+0xb0/0x238) from [<01e7b570>] (0x1e7b570)
Code: e7fddef1 e7fddef1 e7fddef1 e7fdf1f1 (e7fddef1)
---[ end trace 546fedf9b22de3f0 ]---
$ echo "Code: e7fddef1 e7fddef1 e7fddef1 e7fdf1f1 (e7fddef1)" |scripts/decodecode
Code: e7fddef1 e7fddef1 e7fddef1 e7fdf1f1 (e7fddef1)
All code
========
0: e7fddef1 ; <UNDEFINED> instruction: 0xe7fddef1
4: e7fddef1 ; <UNDEFINED> instruction: 0xe7fddef1
8: e7fddef1 ; <UNDEFINED> instruction: 0xe7fddef1
c: e7fdf1f1 ; <UNDEFINED> instruction: 0xe7fdf1f1
10: e7fddef1 ; <UNDEFINED> instruction:* 0xe7fddef1 <-- trapping instruction
Code starting with the faulting instruction
===========================================
0: e7fddef1 ; <UNDEFINED> instruction: 0xe7fddef1
next reply other threads:[~2014-01-03 14:46 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-03 14:46 Axel Lin [this message]
2014-01-03 14:58 ` Question about debugging Bad mode in â handler detected Russell King - ARM Linux
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1388760385.31617.2.camel@phoenix \
--to=axel.lin@ingics.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.