[#4734] traps test case 19 for exception 0x2d fails
Submitted By: Mingquan Pan
Open Date
2008-12-21 23:37:44 Close Date
2009-02-10 01:30:49
Priority:
Medium High Assignee:
Bernd Schmidt
Robin Getz
Status:
Closed Fixed In Release:
N/A
Found In Release:
N/A Release:
Category:
N/A Board:
N/A
Processor:
ALL Silicon Revision:
Is this bug repeatable?:
Yes Resolution:
Fixed
Uboot version or rev.:
Toolchain version or rev.:
Nov 11
App binary format:
N/A
Summary: traps test case 19 for exception 0x2d fails
Details:
traps test case 19 for exception 0x2d fails on trunk,check in between svn 5855 to 5863 due to this.
Running test 19 for exception 0x2d: Instruction fetch multiple CPLB hits - Jump to zero
... Instruction fetch CPLB miss
- CPLB miss on an instruction fetch.
Deferred Exception context
CURRENT PROCESS:
COMM=traps_test PID=321
CPU = 0
TEXT = 0x00670040-0x00674660 DATA = 0x00674664-0x00676574
BSS = 0x00676574-0x00676814 USER-STACK = 0x00677f78
return address: [0x72742f2e]; contents of:
0x72742f00: ???? ???? ???? ???? ???? ???? ???? ????
0x72742f10: ???? ???? ???? ???? ???? ???? ???? ????
0x72742f20: ???? ???? ???? ???? ???? ???? ???? [????]
0x72742f30: ???? ???? ???? ???? ???? ???? ???? ????
SEQUENCER STATUS: Not tainted
SEQSTAT: 0006202c IPEND: 0030 SYSCFG: 0006
EXCAUSE : 0x2c
RETE: <0x00000000> /* Maybe null pointer? */
RETN: <0x03210000> /* kernel dynamic memory */
RETX: <0x00000480> /* Maybe fixed code section */
RETS: <0x00000000> /* Maybe null pointer? */
PC : <0x72742f2e> /* kernel dynamic memory */
DCPLB_FAULT_ADDR: <0x0320fffc> /* kernel dynamic memory */
ICPLB_FAULT_ADDR: <0x72742f2e> /* kernel dynamic memory */
PROCESSOR STATE:
R0 : 00417f7c R1 : 00000000 R2 : 004167f0 R3 : 00000002
R4 : 004103b4 R5 : 00000000 R6 : 00000000 R7 : 00000000
P0 : 00674638 P1 : 0067464a P2 : 00000000 P3 : 004167f0
P4 : 00000002 P5 : 00677f9c FP : 74736574 SP : 0320ff24
LB0: 00747365 LT0: 6172742e LC0: 6e696c3d
LB1: 00000001 LT1: 745f7370 LC1: 2e007875
B0 : 752f3a6e L0 : 2f3a6e69 M0 : 69622f3d I0 : 00393100
B1 : 732f7273 L1 : 2f727375 M1 : 68732f6e I1 : 454d4f48
B2 : 006e6962 L2 : 3a6e6962 M2 : 54415000 I2 : 53002f3d
B3 : 4d524554 L3 : 6962732f M3 : 622f3d48 I3 : 4c4c4548
A0.w: 00000000 A0.x: ffffffb3 A1.w: 00677fac A1.x: ffffffc1
USP : 00677fa9 ASTAT: 00677fe4
No trace since you do not have CONFIG_DEBUG_BFIN_NO_KERN_HWTRACE enabled
Userspace Stack
Stack info:
SP: [0x00677fa9] <0x00677fa9> [ traps_test + 0x7fa9 ]
Memory from 0x00677fa0 to 00678000
00677fa0: 5f737061 74736574 00393100 454d4f48 53002f3d 4c4c4548 69622f3d 68732f6e
00677fc0: 54415000 622f3d48 2f3a6e69 2f727375 3a6e6962 6962732f 752f3a6e 732f7273
00677fe0: 006e6962 4d524554 6e696c3d 2e007875 6172742f 745f7370 00747365 00000000
00678000: 69666b63
Return addresses in stack:
FAIL (test failed, but not with the right signal)
(We expected 11 'Segmentation fault' but instead we got 7 'Bus error')
Follow-ups
--- Mingquan Pan 2008-12-30 04:45:41
And also when this bug happens, the uclinux-dist checkins change from 7453 to
7458 (in Dec 12-13).
--- Robin Getz 2009-01-05 13:30:23
The test case:
void jump_to_zero(void)
{
int (*foo)(void);
int i;
i=0x0;
foo = (void *)i;
(*foo)();
}
should jump to zero, and cause a double icplb fault - but this is getting a not
installed error.
This makes sense on a MPU kernel - but on a noMMU kernel.
Can you print out /proc/cpuinfo and /proc/cplb
Thanks
--- Mingquan Pan 2009-01-14 03:54:08
It is:
root:/bin>
root:/bin> cat /proc/cpuinfo
processor : 0
vendor_id : Analog Devices
cpu family : 0x27c8
model name : ADSP-BF537 500(MHz CCLK) 100(MHz SCLK) (mpu off)
stepping : 2
cpu MHz : 500.000/100.000
bogomips : 995.32
Calibration : 497664000 loops
cache size : 16 KB(L1 icache) 32 KB(L1 dcache-wt) 0 KB(L2 cache)
dbank-A/B : cache/cache
icache setup : 4 Sub-banks/4 Ways, 32 Lines/Way
dcache setup : 2 Super-banks/4 Sub-banks/2 Ways, 64 Lines/Way
board name : ADI BF537-STAMP
board memory : 65536 kB (0x00000000 -> 0x04000000)
kernel memory : 57336 kB (0x00001000 -> 0x037ff000)
root:/bin> cat /proc/cplbinfo/cpu0/
/proc/cplbinfo/cpu0/dcplb /proc/cplbinfo/cpu0/icplb
root:/bin> cat /proc/cplbinfo/cpu0/dcplb
DCPLBs are enabled: 0x100f
Index Address Data Size U/RD U/WR S/WR Switch
0 0x00000000 00083 1K N N N N
1 0x00000000 3d09d 4M Y Y Y N
2 0x00400000 3d09d 4M Y Y Y N
3 0xff800000 3009f 4M Y Y Y N
4 0x00800000 3d09d 4M Y Y Y Y
5 0x03700000 2d09d 1M Y Y Y Y
6 0x03600000 2d09d 1M Y Y Y Y
7 0x03400000 2d09d 1M Y Y Y Y
8 0x03500000 2d09d 1M Y Y Y Y
9 0x03000000 3d09d 4M Y Y Y Y
10 0x03c00000 3009d 4M Y Y Y Y
11 0x00000000 00000 1K N N N Y
12 0x00000000 00000 1K N N N Y
13 0x00000000 00000 1K N N N Y
14 0x00000000 00000 1K N N N Y
15 0x00000000 00000 1K N N N Y
root:/bin> cat /proc/cplbinfo/cpu0/icplb
ICPLBs are enabled: 0x7
Index Address Data Size U/RD U/WR S/WR Switch
0 0x00000000 31205 4M Y N N N
1 0x00400000 31205 4M Y N N N
2 0xffa00000 30007 4M Y N N N
3 0x03000000 31205 4M Y N N Y
4 0x03700000 21205 1M Y N N Y
5 0x00000000 00000 1K N N N Y
6 0x00000000 00000 1K N N N Y
7 0x00000000 00000 1K N N N Y
8 0x00000000 00000 1K N N N Y
9 0x00000000 00000 1K N N N Y
10 0x00000000 00000 1K N N N Y
11 0x00000000 00000 1K N N N Y
12 0x00000000 00000 1K N N N Y
13 0x00000000 00000 1K N N N Y
14 0x00000000 00000 1K N N N Y
15 0x00000000 00000 1K N N N Y
root:/bin>
--- Robin Getz 2009-01-14 07:50:19
OK - this _is_ a MPU kernel, and there isn't a dup 1k CPLB installed at zero.
I'll check with Bernd to see if this is the correct setup.
-Robin
--- Robin Getz 2009-01-14 18:39:42
Bernd said - no -- this is not correct...
So, either he or I will fix.
--- Bernd Schmidt 2009-01-29 14:09:30
I've committed a fix, so closing.
Gforge requires me to fill in meaningless fields to close the bug. This is
annoying.
--- Sonic Zhang 2009-02-01 21:26:57
The "Found In Release:*" field should be filled in with current
release candicated "2009R1-RC1". The "Processor:" field
should be "ALL" for this bug.
From now on, all these information should be filled in when a new bug is
filed.
--- Mingquan Pan 2009-02-04 03:25:51
It is strange that this is fixed on one board of bf537 stamp. While on some
other 537 board and bf527 ezkit board, it would stuck at case 19 for quite a
while until 50 minutes timeout:
PASS (test failed as expected by signal 7: Bus error)^M
Pass_num is 18 .^M
Running test 19 for exception 0x2d: Instruction fetch multiple CPLB hits - Jump
to zero^M
... ^M
Running test 19 for exception 0x2d: Instruction fetch multiple CPLB hits - Jump
to zero^M
...
Case 1 ...FAIL
root:/bin> cat /proc/cpuinfo
processor : 0
vendor_id : Analog Devices
cpu family : 0x27c8
model name : ADSP-BF537 500(MHz CCLK) 100(MHz SCLK) (mpu off)
stepping : 2
cpu MHz : 500.000/100.000
bogomips : 995.32
Calibration : 497664000 loops
cache size : 16 KB(L1 icache) 32 KB(L1 dcache-wt) 0 KB(L2 cache)
dbank-A/B : cache/cache
icache setup : 4 Sub-banks/4 Ways, 32 Lines/Way
dcache setup : 2 Super-banks/4 Sub-banks/2 Ways, 64 Lines/Way
board name : ADI BF537-STAMP
board memory : 65536 kB (0x00000000 -> 0x04000000)
kernel memory : 57336 kB (0x00001000 -> 0x037ff000)
root:/bin> cd
root:/> cat /proc/cplbinfo/cpu0/dcplb
DCPLBs are enabled: 0x100f
Index Address Data Size U/RD U/WR S/WR Switch
0 0x00000000 00083 1K N N N N
1 0x00000000 3d09d 4M Y Y Y N
2 0x00400000 3d09d 4M Y Y Y N
3 0xff800000 3009f 4M Y Y Y N
4 0x00800000 3d09d 4M Y Y Y Y
5 0x03700000 2d09d 1M Y Y Y Y
6 0x03600000 2d09d 1M Y Y Y Y
7 0x03400000 2d09d 1M Y Y Y Y
8 0x03500000 2d09d 1M Y Y Y Y
9 0x03000000 3d09d 4M Y Y Y Y
10 0x03c00000 3009d 4M Y Y Y Y
11 0x00000000 00000 1K N N N Y
12 0x00000000 00000 1K N N N Y
13 0x00000000 00000 1K N N N Y
14 0x00000000 00000 1K N N N Y
15 0x00000000 00000 1K N N N Y
root:/> cat /proc/cplbinfo/cpu0/icplb
ICPLBs are enabled: 0x7
Index Address Data Size U/RD U/WR S/WR Switch
0 0x00000000 31205 4M Y N N N
1 0x00400000 31205 4M Y N N N
2 0xffa00000 30007 4M Y N N N
3 0x03000000 31205 4M Y N N Y
4 0x00800000 31205 4M Y N N Y
5 0x00000000 00000 1K N N N Y
6 0x00000000 00000 1K N N N Y
7 0x00000000 00000 1K N N N Y
8 0x00000000 00000 1K N N N Y
9 0x00000000 00000 1K N N N Y
10 0x00000000 00000 1K N N N Y
11 0x00000000 00000 1K N N N Y
12 0x00000000 00000 1K N N N Y
13 0x00000000 00000 1K N N N Y
14 0x00000000 00000 1K N N N Y
15 0x00000000 00000 1K N N N Y
root:/>
root:/> version
kernel: Linux release 2.6.28-ADI-2009R1-pre-svn6043, build #42 Tue Feb 3
05:03:24 CST 2009
toolchain: bfin-uclinux-gcc release gcc version 4.1.2 (ADI svn)
user-dist: release svn-7698, build #510 Tue Feb 3 05:00:34 CST 2009
While on bf548-ezkit, it outputs different:
Running test 19 for exception 0x2d: Instruction fetch multiple CPLB hits - Jump
to zero
...
Running test 19 for exception 0x2d: Instruction fetch multiple CPLB hits - Jump
to zero
... Undefined instruction
- May be used to emulate instructions that are not defined for
a particular processor implementation.
Deferred Exception context
CURRENT PROCESS:
COMM=traps_test PID=352
CPU = 0
TEXT = 0x008f8040-0x008fc640 DATA = 0x008fc644-0x008fe544
BSS = 0x008fe544-0x008fe7e4 USER-STACK = 0x008fff78
return address: [0x00000080]; contents of:
0x00000060: ???? ???? ???? ???? ???? ???? ???? ????
0x00000070: ???? ???? ???? ???? ???? ???? ???? ????
0x00000080: [????] ???? ???? ???? ???? ???? ???? ????
0x00000090: ???? ???? ???? ???? ???? ???? ???? ????
SEQUENCER STATUS: Not tainted
SEQSTAT: 00062021 IPEND: 0030 SYSCFG: 0006
EXCAUSE : 0x21
interrupts disabled
physical IVG5 asserted : <0xffa00b24> { _evt_ivhw + 0x0 }
RETE: <0x00000000> /* Maybe null pointer? */
RETN: <0x008d6000> /* kernel dynamic memory */
RETX: <0x00000480> /* Maybe fixed code section */
RETS: <0x008f82b4> [ traps_test + 0x274 ]
PC : <0x00000080> /* Maybe null pointer? */
DCPLB_FAULT_ADDR: <0x008ffeac> [ traps_test + 0x7eac ]
ICPLB_FAULT_ADDR: <0x00000080> /* Maybe null pointer? */
PROCESSOR STATE:
R0 : 00000000 R1 : 00000013 R2 : 008fdaf0 R3 : 00000008
R4 : 008f83b4 R5 : 00000002 R6 : 008fe7c0 R7 : 00000000
P0 : 000000a2 P1 : 0000001f P2 : 00000000 P3 : 008fff7c
P4 : 008fe540 P5 : 008fc644 FP : 008ffeb4 SP : 008d5f24
LB0: 008f98d3 LT0: 008f98d2 LC0: 00000000
LB1: 008fa1e7 LT1: 008fa1e0 LC1: 00000000
B0 : 00000000 L0 : 00000000 M0 : 00000000 I0 : 008ffc64
B1 : 00000000 L1 : 00000000 M1 : 00000000 I1 : 008b8004
B2 : 00000000 L2 : 00000000 M2 : 00000000 I2 : 00000000
B3 : 00000000 L3 : 00000000 M3 : 00000000 I3 : 00000000
A0.w: 00000000 A0.x: 00000000 A1.w: 00000000 A1.x: 00000000
USP : 008ffea0 ASTAT: 02002020
Hardware Trace:
0 Target : <0x00004abc> { _trap_c + 0x0 }
Source : <0xffa005e2> { _exception_to_level5 + 0x9e } CALL pcrel
1 Target : <0xffa00544> { _exception_to_level5 + 0x0 }
Source : <0xffa00416> { _bfin_return_from_exception + 0x6 } RTX
2 Target : <0xffa00410> { _bfin_return_from_exception + 0x0 }
Source : <0xffa0049e> { _ex_trap_c + 0x66 } JUMP.S
3 Target : <0xffa00438> { _ex_trap_c + 0x0 }
Source : <0xffa0066e> { _trap + 0x2a } JUMP (P4)
4 Target : <0xffa00644> { _trap + 0x0 }
Source : <0x0000007e> /* Maybe null pointer? */
5 Target : <0x00000000> /* Maybe null pointer? */
Source : <0x008f82b2> [ traps_test + 0x272 ] CALL (P2)
6 Target : <0x008f82a4> [ traps_test + 0x264 ]
Source : <0x008f84ea> [ traps_test + 0x4aa ] CALL (P2)
7 Target : <0x008f84cc> [ traps_test + 0x48c ]
Source : <0x008fa1ca> [ traps_test + 0x218a ] RTS
8 Target : <0x008fa1c4> [ traps_test + 0x2184 ]
Source : <0x008fa274> [ traps_test + 0x2234 ] JUMP.S
9 Target : <0x008fa272> [ traps_test + 0x2232 ]
Source : <0x008fa258> [ traps_test + 0x2218 ] IF !CC JUMP
10 Target : <0x008fa254> [ traps_test + 0x2214 ]
Source : <0x008fa55c> [ traps_test + 0x251c ] RTS
11 Target : <0x008fa548> [ traps_test + 0x2508 ]
Source : <0xffa00b22> { __common_int_entry + 0xca } RTI
12 Target : <0xffa00ac0> { __common_int_entry + 0x68 }
Source : <0xffa00ce4> { _evt_system_call + 0x64 } JUMP.S
13 Target : <0xffa00ce4> { _evt_system_call + 0x64 }
Source : <0xffa007f4> { _system_call + 0xb8 } RTS
14 Target : <0xffa007f0> { _system_call + 0xb4 }
Source : <0xffa007e0> { _system_call + 0xa4 } IF !CC JUMP
15 Target : <0xffa007da> { _system_call + 0x9e }
Source : <0xffa007ca> { _system_call + 0x8e } IF !CC JUMP
Userspace Stack
Stack info:
SP: [0x008ffea0] <0x008ffea0> [ traps_test + 0x7ea0 ]
FP: (0x008ffeb4)
Memory from 0x008ffea0 to 00900000
008ffea0:[00000001] 00000000 008fff1c 00000000 00000000
(008fff1c)<008f84ec> 00000000
008ffec0: 00000013 0000002d 008fe1d0 00008a3b 081c0300 01000415 1a131100
170f1200
008ffee0: 00000016 00000000 00000000 00000000 00000000 00000000 008fffab
00000013
008fff00:<008fb140> 0000002f 008fff9d 008fff24 <008fc618>
008fc644 008fc644 (008fff38)
008fff20:<008fa49c> 00000000 008fe7c0 00000002 008fff7c 00000000
(00000000)<008c0598>
008fff40: 008fc644 008c6540 008c7f7c 00000000 008c67c0 00000002 008c03b4
00000000
008fff60: 00000000 00000000 008fc60c 008fc61e 00000000 008c67c0 00000002
008fff9c
008fff80: 008fffa9 00000000 008fffac 008fffb3 008fffc1 008fffe4 00000000
72742f2e
008fffa0: 5f737061 74736574 00393100 454d4f48 53002f3d 4c4c4548 69622f3d
68732f6e
008fffc0: 54415000 622f3d48 2f3a6e69 2f727375 3a6e6962 6962732f 752f3a6e
732f7273
008fffe0: 006e6962 4d524554 6e696c3d 2e007875 6172742f 745f7370 00747365
00000000
00900000: 544c4662
Return addresses in stack:
frame 1 : <0x008f84ec> [ traps_test + 0x4ac ]
address : <0x008fb140> [ traps_test + 0x3100 ]
address : <0x008fc618> [ traps_test + 0x45d8 ]
frame 2 : <0x008fa49c> [ traps_test + 0x245c ]
frame 3 : <0x008c0598> [ traps_test + 0x598 ]
FAIL (test failed, but not with the right signal)
(We expected 11 'Segmentation fault' but instead we got 4 'Illegal
instruction')
root:/bin> cat /proc/cpuinfo
processor : 0
vendor_id : Analog Devices
cpu family : 0x27de
model name : ADSP-BF548 525(MHz CCLK) 131(MHz SCLK) (mpu off)
stepping : 1
cpu MHz : 525.000/131.250000
bogomips : 1044.48
Calibration : 522240000 loops
cache size : 16 KB(L1 icache) 32 KB(L1 dcache-wt) 0 KB(L2 cache)
dbank-A/B : cache/cache
icache setup : 4 Sub-banks/4 Ways, 32 Lines/Way
dcache setup : 2 Super-banks/4 Sub-banks/2 Ways, 64 Lines/Way
L2 SRAM : 128KB
board name : ADI BF548-EZKIT
board memory : 65536 kB (0x00000000 -> 0x04000000)
kernel memory : 63480 kB (0x00001000 -> 0x03dff000)
root:/bin> cat /proc/cplbinfo/cpu0/dcplb
DCPLBs are enabled: 0x100f
Index Address Data Size U/RD U/WR S/WR Switch
0 0x00000000 00083 1K N N N N
1 0x00000000 3d09d 4M Y Y Y N
2 0x00400000 3d09d 4M Y Y Y N
3 0x00800000 3d09d 4M Y Y Y N
4 0xff800000 3009f 4M Y Y Y N
5 0x20c00000 3009d 4M Y Y Y Y
6 0x03d00000 2d09d 1M Y Y Y Y
7 0x03e00000 2009d 1M Y Y Y Y
8 0x03f00000 2009d 1M Y Y Y Y
9 0x03c00000 2d09d 1M Y Y Y Y
10 0x03800000 3d09d 4M Y Y Y Y
11 0x00c00000 3d09d 4M Y Y Y Y
12 0x24000000 3009d 4M Y Y Y Y
13 0x21000000 3009d 4M Y Y Y Y
14 0x20400000 3009d 4M Y Y Y Y
15 0x20800000 3009d 4M Y Y Y Y
root:/bin> cat /proc/cplbinfo/cpu0/icplb
ICPLBs are enabled: 0x7
Index Address Data Size U/RD U/WR S/WR Switch
0 0x00000000 31205 4M Y N N N
1 0x00400000 31205 4M Y N N N
2 0x00800000 31205 4M Y N N N
3 0xffa00000 30007 4M Y N N N
4 0x00c00000 31205 4M Y N N Y
5 0x03d00000 21205 1M Y N N Y
6 0x00000000 00000 1K N N N Y
7 0x00000000 00000 1K N N N Y
8 0x00000000 00000 1K N N N Y
9 0x00000000 00000 1K N N N Y
10 0x00000000 00000 1K N N N Y
11 0x00000000 00000 1K N N N Y
12 0x00000000 00000 1K N N N Y
13 0x00000000 00000 1K N N N Y
14 0x00000000 00000 1K N N N Y
15 0x00000000 00000 1K N N N Y
root:/bin> version
kernel: Linux release 2.6.28-ADI-2009R1-pre-svn6041, build #18 Mon Feb 2
04:17:55 GMT 2009
toolchain: bfin-uclinux-gcc release gcc version 4.1.2 (ADI svn)
user-dist: release svn-7697, build #198 Mon Feb 2 04:16:19 GMT 2009
--- Bernd Schmidt 2009-02-04 09:14:58
This appears to be with MPU off. Is CONFIG_DEBUG_HUNT_FOR_ZERO set for both
kernels?
--- Mingquan Pan 2009-02-06 04:05:54
All the kernels are set CONFIG_DEBUG_HUNT_FOR_ZERO to yes. The config for linux
is the same which is attached.
CONFIG_DEBUG_HUNT_FOR_ZERO=y
CONFIG_DEBUG_BFIN_HWTRACE_ON=y
CONFIG_DEBUG_BFIN_HWTRACE_COMPRESSION_OFF=y
# CONFIG_DEBUG_BFIN_HWTRACE_COMPRESSION_ONE is not set
--- Bernd Schmidt 2009-02-09 11:01:11
Sorry. It should be fixed now.
--- Mingquan Pan 2009-02-10 01:30:48
Yes, it passed on all of those machines. Close.
Files
Changes
Commits
Dependencies
Duplicates
Associations
Tags
File Name File Type File Size Posted By
config.traps application/octet-stream 34822 Mingquan Pan