Last change
on this file since 553 was
232,
checked in by alain, 12 years ago
|
Introducing the elementary tests for a TSAR mono-cluster
mono-processor platform with MMU using the vci_cc_vcache_v4
such as the "tsarv4_mono_mmu".
(assemby level tests written by Manuel Bouyer)
|
File size:
913 bytes
|
Line | |
---|
1 | /* |
---|
2 | * coproc unusable exception test: 0x80000000 bit is set in cause register |
---|
3 | */ |
---|
4 | #include <registers.h> |
---|
5 | #include <misc.h> |
---|
6 | |
---|
7 | .text |
---|
8 | .globl _start |
---|
9 | _start: |
---|
10 | .set noreorder |
---|
11 | la k0, TTY_BASE |
---|
12 | la k1, EXIT_BASE |
---|
13 | la sp, 0x00400000 - 16 |
---|
14 | |
---|
15 | PRINT(startstr) |
---|
16 | |
---|
17 | /* reset cop0 status (keep BEV) */ |
---|
18 | lui a0, 0x0040; |
---|
19 | mtc0 a0, COP0_STATUS |
---|
20 | j 1f |
---|
21 | mtc1 t3,$f2 |
---|
22 | nop |
---|
23 | |
---|
24 | 1: |
---|
25 | /* we should not get there */ |
---|
26 | EXIT(1) |
---|
27 | |
---|
28 | .globl excep |
---|
29 | excep: |
---|
30 | .set noreorder |
---|
31 | PRINT(statusstr) |
---|
32 | mfc0 a0, COP0_STATUS |
---|
33 | PRINTX |
---|
34 | |
---|
35 | PRINT(causestr) |
---|
36 | mfc0 a0, COP0_CAUSE |
---|
37 | PRINTX |
---|
38 | |
---|
39 | PRINT(pcstr) |
---|
40 | mfc0 a0, COP0_EXPC |
---|
41 | PRINTX |
---|
42 | |
---|
43 | PRINT(badvastr) |
---|
44 | mfc0 a0, COP_0_BADVADDR |
---|
45 | PRINTX |
---|
46 | PUTCHAR('\n') |
---|
47 | |
---|
48 | EXIT(0) |
---|
49 | |
---|
50 | .rodata: |
---|
51 | statusstr: .ascii "status \0" |
---|
52 | causestr: .ascii " cause \0" |
---|
53 | pcstr: .ascii " pc \0" |
---|
54 | badvastr: .ascii " badva \0" |
---|
55 | startstr: .ascii "start\n\0" |
---|
56 | |
---|
57 | .org EXCEP_ADDRESS - BOOT_ADDRESS |
---|
58 | .globl evect |
---|
59 | evect: |
---|
60 | j excep |
---|
61 | nop |
---|
62 | .data |
---|
63 | .word MAGIC1 |
---|
64 | testval: |
---|
65 | .word MAGIC2 |
---|
Note: See
TracBrowser
for help on using the repository browser.