4.115
Last change
on this file since 9b4422a2 was
9b4422a2,
checked in by Joel Sherrill <joel.sherrill@…>, on May 3, 2012 at 3:09:24 PM
|
Remove All CVS Id Strings Possible Using a Script
Script does what is expected and tries to do it as
smartly as possible.
+ remove occurrences of two blank comment lines
next to each other after Id string line removed.
+ remove entire comment blocks which only exited to
contain CVS Ids
+ If the processing left a blank line at the top of
a file, it was removed.
|
-
Property mode set to
100644
|
File size:
1.9 KB
|
Line | |
---|
1 | #include <libcpu/bf537.h> |
---|
2 | #include <libcpu/sicRegs.h> |
---|
3 | #include <libcpu/cecRegs.h> |
---|
4 | #include <libcpu/dmaRegs.h> |
---|
5 | #include <libcpu/coreTimerRegs.h> |
---|
6 | |
---|
7 | #ifndef LO |
---|
8 | #define LO(con32) ((con32) & 0xFFFF) |
---|
9 | #endif |
---|
10 | #ifndef HI |
---|
11 | #define HI(con32) (((con32) >> 16) & 0xFFFF) |
---|
12 | #endif |
---|
13 | |
---|
14 | |
---|
15 | .section .init |
---|
16 | .globl __init |
---|
17 | .type __init,@function |
---|
18 | __init: |
---|
19 | .section .fini |
---|
20 | .globl __fini |
---|
21 | .type __fini,@function |
---|
22 | __fini: |
---|
23 | |
---|
24 | |
---|
25 | .section .start |
---|
26 | .align 4 |
---|
27 | |
---|
28 | .global __start |
---|
29 | __start: |
---|
30 | cli r0; |
---|
31 | |
---|
32 | /* setup an initial stack */ |
---|
33 | sp.h = 0xFFB0; |
---|
34 | sp.l = 0x0F00; |
---|
35 | |
---|
36 | /* disable timer interrupts */ |
---|
37 | p0.h = HI(TCNTL); |
---|
38 | p0.l = LO(TCNTL); |
---|
39 | r0 = 0; |
---|
40 | [p0] = r0; |
---|
41 | |
---|
42 | /* disable all interrupts routed through sic */ |
---|
43 | p0.h = HI(SIC_IMASK); |
---|
44 | p0.l = LO(SIC_IMASK); |
---|
45 | [p0] = r0; |
---|
46 | |
---|
47 | /* clear any pending interrupts */ |
---|
48 | p0.h = HI(CEC_ILAT); |
---|
49 | p0.l = LO(CEC_ILAT); |
---|
50 | r0 = 0xffff (z); |
---|
51 | [p0] = r0; |
---|
52 | |
---|
53 | /* disable all dma channels */ |
---|
54 | p0.h = HI(DMA0_BASE_ADDRESS + DMA_CONFIG_OFFSET); |
---|
55 | p0.l = LO(DMA0_BASE_ADDRESS + DMA_CONFIG_OFFSET); |
---|
56 | p1 = DMA_PITCH; |
---|
57 | p2 = DMA_CHANNELS; |
---|
58 | r0 = ~DMA_CONFIG_DMAEN; |
---|
59 | lsetup(loop1,loop2) lc0 = p2; |
---|
60 | loop1: r1 = w[p0]; |
---|
61 | r1 = r0 & r1; |
---|
62 | loop2: w[p0 ++ p1] = r1.l; |
---|
63 | |
---|
64 | /* this is so we can stay in supervisor mode and still be able to |
---|
65 | accept interrupts later. */ |
---|
66 | p0.h = start; |
---|
67 | p0.l = start; |
---|
68 | p1.h = HI(CEC_EVT15); |
---|
69 | p1.l = LO(CEC_EVT15); |
---|
70 | |
---|
71 | [p1] = p0; |
---|
72 | |
---|
73 | r0 = 0x8000 (z); |
---|
74 | sti r0; |
---|
75 | |
---|
76 | raise 15; |
---|
77 | |
---|
78 | p0.h = wait; |
---|
79 | p0.l = wait; |
---|
80 | |
---|
81 | reti = p0; |
---|
82 | rti; |
---|
83 | |
---|
84 | /* wait for event 15 */ |
---|
85 | wait: |
---|
86 | jump wait; |
---|
87 | |
---|
88 | start: |
---|
89 | [--sp] = reti; /* allow us to process interrupts later */ |
---|
90 | |
---|
91 | /* mask interrupts for now */ |
---|
92 | cli r0; |
---|
93 | |
---|
94 | p0.h = _bss_start; |
---|
95 | p0.l = _bss_start; |
---|
96 | p1.h = _end; |
---|
97 | p1.l = _end; |
---|
98 | r0 = p0; |
---|
99 | r1 = p1; |
---|
100 | r1 = r1 - r0; |
---|
101 | p1 = r1; |
---|
102 | r0 = 0; |
---|
103 | |
---|
104 | /* Set _bss_start until _end to zero */ |
---|
105 | lsetup(loop3,loop4) lc0 = p1; |
---|
106 | loop3: b[p0] = r0; |
---|
107 | loop4: p0 +=1; |
---|
108 | |
---|
109 | l0 = 0; |
---|
110 | l1 = 0; |
---|
111 | l2 = 0; |
---|
112 | l3 = 0; |
---|
113 | sp += -12; |
---|
114 | /* r0 == const char *cmdline (currently null) */ |
---|
115 | p0.h = _boot_card; |
---|
116 | p0.l = _boot_card; |
---|
117 | call (p0); |
---|
118 | sp += 12; |
---|
119 | |
---|
120 | HLT |
---|
121 | p0.h = _exit; |
---|
122 | p0.l = _exit; |
---|
123 | jump (p0); |
---|
124 | |
---|
Note: See
TracBrowser
for help on using the repository browser.