CHDK_DE Vorschauversion  Trunk Rev. 5428
 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)
 

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 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 40 der Datei boot.c.

40  {
41 asm volatile (
42  "LDR R1, =0xC0410000 \n"
43  "MOV R0, #0 \n"
44  "STR R0, [R1] \n"
45  "MOV R1, #0x78 \n"
46  "MCR p15, 0, R1, c1, c0 \n"
47  "MOV R1, #0 \n"
48  "MCR p15, 0, R1, c7, c10, 4 \n"
49  "MCR p15, 0, R1, c7, c5 \n"
50  "MCR p15, 0, R1, c7, c6 \n"
51  "MOV R0, #0x3D \n"
52  "MCR p15, 0, R0, c6, c0 \n"
53  "MOV R0, #0xC000002F \n"
54  "MCR p15, 0, R0, c6, c1 \n"
55  "MOV R0, #0x33 \n"
56  "MCR p15, 0, R0, c6, c2 \n"
57  "MOV R0, #0x40000033 \n"
58  "MCR p15, 0, R0, c6, c3 \n"
59  "MOV R0, #0x80000017 \n"
60  "MCR p15, 0, R0, c6, c4 \n"
61  "LDR R0, =0xFF80002D \n"
62  "MCR p15, 0, R0, c6, c5 \n"
63  "MOV R0, #0x34 \n"
64  "MCR p15, 0, R0, c2, c0 \n"
65  "MOV R0, #0x34 \n"
66  "MCR p15, 0, R0, c2, c0, 1 \n"
67  "MOV R0, #0x34 \n"
68  "MCR p15, 0, R0, c3, c0 \n"
69  "LDR R0, =0x3333330 \n"
70  "MCR p15, 0, R0, c5, c0, 2 \n"
71  "LDR R0, =0x3333330 \n"
72  "MCR p15, 0, R0, c5, c0, 3 \n"
73  "MRC p15, 0, R0, c1, c0 \n"
74  "ORR R0, R0, #0x1000 \n"
75  "ORR R0, R0, #4 \n"
76  "ORR R0, R0, #1 \n"
77  "MCR p15, 0, R0, c1, c0 \n"
78  "MOV R1, #0x80000006 \n"
79  "MCR p15, 0, R1, c9, c1 \n"
80  "MOV R1, #6 \n"
81  "MCR p15, 0, R1, c9, c1, 1 \n"
82  "MRC p15, 0, R1, c1, c0 \n"
83  "ORR R1, R1, #0x50000 \n"
84  "MCR p15, 0, R1, c1, c0 \n"
85  "LDR R2, =0xC0200000 \n"
86  "MOV R1, #1 \n"
87  "STR R1, [R2, #0x10C] \n"
88  "MOV R1, #0xFF \n"
89  "STR R1, [R2, #0xC] \n"
90  "STR R1, [R2, #0x1C] \n"
91  "STR R1, [R2, #0x2C] \n"
92  "STR R1, [R2, #0x3C] \n"
93  "STR R1, [R2, #0x4C] \n"
94  "STR R1, [R2, #0x5C] \n"
95  "STR R1, [R2, #0x6C] \n"
96  "STR R1, [R2, #0x7C] \n"
97  "STR R1, [R2, #0x8C] \n"
98  "STR R1, [R2, #0x9C] \n"
99  "STR R1, [R2, #0xAC] \n"
100  "STR R1, [R2, #0xBC] \n"
101  "STR R1, [R2, #0xCC] \n"
102  "STR R1, [R2, #0xDC] \n"
103  "STR R1, [R2, #0xEC] \n"
104  "STR R1, [R2, #0xFC] \n"
105  "LDR R1, =0xC0400008 \n"
106  "LDR R2, =0x430005 \n"
107  "STR R2, [R1] \n"
108  "MOV R1, #1 \n"
109  "LDR R2, =0xC0243100 \n"
110  "STR R2, [R1] \n"
111  "LDR R2, =0xC0242010 \n"
112  "LDR R1, [R2] \n"
113  "ORR R1, R1, #1 \n"
114  "STR R1, [R2] \n"
115  "LDR R0, =0xFFC241C0 \n"
116  "LDR R1, =0x3F1000 \n"
117  "LDR R3, =0x400654 \n"
118 "loc_FF81013C:\n"
119  "CMP R1, R3 \n"
120  "LDRCC R2, [R0], #4 \n"
121  "STRCC R2, [R1], #4 \n"
122  "BCC loc_FF81013C \n"
123  "LDR R0, =0xFFC180A8 \n"
124  "LDR R1, =0x1900 \n"
125  "LDR R3, =0xDA18 \n"
126 "loc_FF810158:\n"
127  "CMP R1, R3 \n"
128  "LDRCC R2, [R0], #4 \n"
129  "STRCC R2, [R1], #4 \n"
130  "BCC loc_FF810158 \n"
131  "LDR R1, =0x15967C \n" //MEMISOSTART
132  "MOV R2, #0 \n"
133 "loc_FF810170:\n"
134  "CMP R3, R1 \n"
135  "STRCC R2, [R3], #4 \n"
136  "BCC loc_FF810170 \n"
137 // "B sub_FF810380 \n" //original
138  "B sub_FF810380_my \n" //patched
139  );
140 }
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 23 der Datei boot.c.

23  {
24 
25  task_t *tcb=(task_t*)((char*)context-offsetof(task_t, context));
26 
27  if(tcb->entry == (void*)task_PhySw) tcb->entry = (void*)mykbd_task;
28  if(tcb->entry == (void*)task_CaptSeq) tcb->entry = (void*)capt_seq_task;
29  if(tcb->entry == (void*)task_InitFileModules) tcb->entry = (void*)init_file_modules_task;
30  if(tcb->entry == (void*)task_MovieRecord) tcb->entry = (void*)movie_record_task;
31  if(tcb->entry == (void*)task_ExpDrv) tcb->entry = (void*)exp_drv_task;
32  if(tcb->entry == (void*)task_FileWrite) tcb->entry = (void*)filewritetask;
33 #if 0
34  if(tcb->entry == (void*)task_TouchPanel) tcb->entry = (void*)task_TouchPanel_my;
35 #endif
36 }

Variablen-Dokumentation

const char* const new_sa = &_end

Definiert in Zeile 7 der Datei boot.c.