CHDK_DE Vorschauversion  Trunk Rev. 5279
 Alle Datenstrukturen Dateien Funktionen Variablen Typdefinitionen Aufzählungen Aufzählungswerte Makrodefinitionen
boot.c-Dateireferenz
#include "lolevel.h"
#include "platform.h"
#include "core.h"
#include "dryos31.h"
+ Include-Abhängigkeitsdiagramm für boot.c:

gehe zum Quellcode dieser Datei

Makrodefinitionen

#define offsetof(TYPE, MEMBER)   ((int) &((TYPE *)0)->MEMBER)
 
#define LED_GREEN   0xC0220120
 

Funktionen

void CreateTask_PhySw ()
 
void CreateTask_spytask ()
 
void task_CaptSeq ()
 
void task_InitFileModules ()
 
void task_MovieRecord ()
 
void task_ExpDrv ()
 
void task_PhySw ()
 
void task_FileWrite ()
 
void taskHook (context_t **context)
 
void __attribute__ ((naked, noinline))
 

Variablen

const char *const new_sa = &_end
 

Makro-Dokumentation

#define LED_GREEN   0xC0220120

Definiert in Zeile 31 der Datei boot.c.

#define offsetof (   TYPE,
  MEMBER 
)    ((int) &((TYPE *)0)->MEMBER)

Definiert in Zeile 5 der Datei boot.c.

Dokumentation der Funktionen

void __attribute__ ( (naked, noinline)  )

Definiert in Zeile 73 der Datei boot.c.

73  {
74 asm volatile (
75  "LDR R1, =0xC0410000 \n"
76  "MOV R0, #0 \n"
77  "STR R0, [R1] \n"
78  "MOV R1, #0x78 \n"
79  "MCR p15, 0, R1, c1, c0 \n"
80  "MOV R1, #0 \n"
81  "MCR p15, 0, R1, c7, c10, 4 \n"
82  "MCR p15, 0, R1, c7, c5 \n"
83  "MCR p15, 0, R1, c7, c6 \n"
84  "MOV R0, #0x3D \n"
85  "MCR p15, 0, R0, c6, c0 \n"
86  "MOV R0, #0xC000002F \n"
87  "MCR p15, 0, R0, c6, c1 \n"
88  "MOV R0, #0x33 \n"
89  "MCR p15, 0, R0, c6, c2 \n"
90  "MOV R0, #0x40000033 \n"
91  "MCR p15, 0, R0, c6, c3 \n"
92  "MOV R0, #0x80000017 \n"
93  "MCR p15, 0, R0, c6, c4 \n"
94  "LDR R0, =0xFF80002D \n"
95  "MCR p15, 0, R0, c6, c5 \n"
96  "MOV R0, #0x34 \n"
97  "MCR p15, 0, R0, c2, c0 \n"
98  "MOV R0, #0x34 \n"
99  "MCR p15, 0, R0, c2, c0, 1 \n"
100  "MOV R0, #0x34 \n"
101  "MCR p15, 0, R0, c3, c0 \n"
102  "LDR R0, =0x3333330 \n"
103  "MCR p15, 0, R0, c5, c0, 2 \n"
104  "LDR R0, =0x3333330 \n"
105  "MCR p15, 0, R0, c5, c0, 3 \n"
106  "MRC p15, 0, R0, c1, c0 \n"
107  "ORR R0, R0, #0x1000 \n"
108  "ORR R0, R0, #4 \n"
109  "ORR R0, R0, #1 \n"
110  "MCR p15, 0, R0, c1, c0 \n"
111  "MOV R1, #0x80000006 \n"
112  "MCR p15, 0, R1, c9, c1 \n"
113  "MOV R1, #6 \n"
114  "MCR p15, 0, R1, c9, c1, 1 \n"
115  "MRC p15, 0, R1, c1, c0 \n"
116  "ORR R1, R1, #0x50000 \n"
117  "MCR p15, 0, R1, c1, c0 \n"
118  "LDR R2, =0xC0200000 \n"
119  "MOV R1, #1 \n"
120  "STR R1, [R2, #0x10C] \n"
121  "MOV R1, #0xFF \n"
122  "STR R1, [R2, #0xC] \n"
123  "STR R1, [R2, #0x1C] \n"
124  "STR R1, [R2, #0x2C] \n"
125  "STR R1, [R2, #0x3C] \n"
126  "STR R1, [R2, #0x4C] \n"
127  "STR R1, [R2, #0x5C] \n"
128  "STR R1, [R2, #0x6C] \n"
129  "STR R1, [R2, #0x7C] \n"
130  "STR R1, [R2, #0x8C] \n"
131  "STR R1, [R2, #0x9C] \n"
132  "STR R1, [R2, #0xAC] \n"
133  "STR R1, [R2, #0xBC] \n"
134  "STR R1, [R2, #0xCC] \n"
135  "STR R1, [R2, #0xDC] \n"
136  "STR R1, [R2, #0xEC] \n"
137  "STR R1, [R2, #0xFC] \n"
138  "LDR R1, =0xC0400008 \n"
139  "LDR R2, =0x430005 \n"
140  "STR R2, [R1] \n"
141  "MOV R1, #1 \n"
142  "LDR R2, =0xC0243100 \n"
143  "STR R2, [R1] \n"
144  "LDR R2, =0xC0242010 \n"
145  "LDR R1, [R2] \n"
146  "ORR R1, R1, #1 \n"
147  "STR R1, [R2] \n"
148  "LDR R0, =0xFFC011A8 \n"
149  "LDR R1, =0x3F1000 \n"
150  "LDR R3, =0x4005D4 \n"
151 "loc_FF81013C:\n"
152  "CMP R1, R3 \n"
153  "LDRCC R2, [R0], #4 \n"
154  "STRCC R2, [R1], #4 \n"
155  "BCC loc_FF81013C \n"
156  "LDR R0, =0xFFBF5B08 \n"
157  "LDR R1, =0x1900 \n"
158  "LDR R3, =0xCFA0 \n"
159 "loc_FF810158:\n"
160  "CMP R1, R3 \n"
161  "LDRCC R2, [R0], #4 \n"
162  "STRCC R2, [R1], #4 \n"
163  "BCC loc_FF810158 \n"
164  "LDR R1, =0x1581D0 \n" //MEMISOSTART
165  "MOV R2, #0 \n"
166 "loc_FF810170:\n"
167  "CMP R3, R1 \n"
168  "STRCC R2, [R3], #4 \n"
169  "BCC loc_FF810170 \n"
170 // "B sub_FF810380 \n" //original
171  "B sub_FF810380_my \n" //patched
172  );
173 }
void CreateTask_PhySw ( )
void CreateTask_spytask ( )

Definiert in Zeile 34 der Datei boot.c.

34  {
35  _CreateTask("SpyTask", 0x19, 0x2000, core_spytask, 0);
36 };
void task_CaptSeq ( )
void task_ExpDrv ( )
void task_FileWrite ( )
void task_InitFileModules ( )
void task_MovieRecord ( )
void task_PhySw ( )
void taskHook ( context_t **  context)

Definiert in Zeile 19 der Datei boot.c.

19  {
20 
21  task_t *tcb=(task_t*)((char*)context-offsetof(task_t, context));
22 
23  if(tcb->entry == (void*)task_PhySw) tcb->entry = (void*)mykbd_task;
24  if(tcb->entry == (void*)task_CaptSeq) tcb->entry = (void*)capt_seq_task;
25  if(tcb->entry == (void*)task_InitFileModules) tcb->entry = (void*)init_file_modules_task;
26  if(tcb->entry == (void*)task_MovieRecord) tcb->entry = (void*)movie_record_task;
27  if(tcb->entry == (void*)task_ExpDrv) tcb->entry = (void*)exp_drv_task;
28  if(tcb->entry == (void*)task_FileWrite) tcb->entry = (void*)filewritetask;
29 }

Variablen-Dokumentation

const char* const new_sa = &_end

Definiert in Zeile 7 der Datei boot.c.