Rev 393 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 393 | Rev 394 | ||
---|---|---|---|
Line 161... | Line 161... | ||
161 | 161 | ||
Line 162... | Line 162... | ||
162 | ; CLEAR 0x280000 - HEAP_BASE |
162 | ; CLEAR 0x280000 - HEAP_BASE |
163 | 163 | ||
164 | xor eax,eax |
164 | xor eax,eax |
165 | mov edi,0x280000 |
165 | mov edi,0x280000 |
166 | mov ecx,(HEAP_BASE-0x280000) / 4 |
166 | mov ecx,(HEAP_BASE-OS_BASE-0x280000) / 4 |
Line 167... | Line 167... | ||
167 | cld |
167 | cld |
168 | rep stosd |
168 | rep stosd |
Line 200... | Line 200... | ||
200 | mov cr3, eax |
200 | mov cr3, eax |
Line 201... | Line 201... | ||
201 | 201 | ||
202 | mov eax,cr0 |
202 | mov eax,cr0 |
203 | or eax,CR0_PG |
203 | or eax,CR0_PG |
- | 204 | mov cr0,eax |
|
204 | mov cr0,eax |
205 | |
205 | lgdt [gdts] |
206 | lgdt [gdts] |
Line 206... | Line 207... | ||
206 | jmp pword os_code:high_code |
207 | jmp pword os_code:high_code |
207 | 208 | ||
208 | __DEBUG__ fix 1 |
209 | __DEBUG__ fix 1 |
Line 209... | Line 210... | ||
209 | __DEBUG_LEVEL__ fix 1 |
210 | __DEBUG_LEVEL__ fix 1 |
210 | include 'init.inc' |
- | |
Line 211... | Line 211... | ||
211 | 211 | include 'init.inc' |
|
212 | org OS_BASE+$ |
212 | |
213 | include 'fdo.inc' |
213 | org OS_BASE+$ |
214 | 214 | ||
Line 351... | Line 351... | ||
351 | mov [LFBSize], 0x800000 |
351 | mov [LFBSize], 0x800000 |
352 | call init_mtrr |
352 | call init_mtrr |
Line 353... | Line 353... | ||
353 | 353 | ||
354 | call init_LFB |
354 | call init_LFB |
355 | call init_fpu |
- | |
356 | 355 | call init_fpu |
|
Line 357... | Line 356... | ||
357 | call init_malloc |
356 | call init_malloc |
358 | 357 | ||
359 | stdcall alloc_kernel_space, 0x4F000 |
358 | stdcall alloc_kernel_space, 0x4F000 |
Line 380... | Line 379... | ||
380 | 379 | ||
381 | add eax, ebx |
380 | add eax, ebx |
Line 382... | Line 381... | ||
382 | mov [ipc_ptab], eax |
381 | mov [ipc_ptab], eax |
383 | - | ||
384 | call init_events |
382 | |
385 | 383 | call init_events |
|
386 | mov eax, srv.fd-SRV_FD_OFFSET |
384 | mov eax, srv.fd-SRV_FD_OFFSET |
Line 387... | Line 385... | ||
387 | mov [srv.fd], eax |
385 | mov [srv.fd], eax |
Line 729... | Line 727... | ||
729 | 727 | ||
Line 730... | Line 728... | ||
730 | ; Fly :) |
728 | ; Fly :) |
- | 729 | ||
Line 731... | Line 730... | ||
731 | 730 | ||
732 | 731 | include 'unpacker.inc' |
|
733 | include 'unpacker.inc' |
732 | include 'fdo.inc' |
Line 1291... | Line 1290... | ||
1291 | sub ecx,eax |
1290 | sub ecx,eax |
1292 | add ecx,esp |
1291 | add ecx,esp |
1293 | mov eax,[esp+64+32-8+4] |
1292 | mov eax,[esp+64+32-8+4] |
1294 | push edx ; add window start x & y |
1293 | push edx ; add window start x & y |
1295 | mov edx,[TASK_BASE] |
1294 | mov edx,[TASK_BASE] |
- | 1295 | ||
- | 1296 | mov edi,[CURRENT_TASK] |
|
- | 1297 | shl edi,8 |
|
- | 1298 | ||
1296 | mov ebx,[edx-twdw+WDATA.box.left] |
1299 | mov ebx,[edx-twdw+WDATA.box.left] |
1297 | add ebx, [(edx-CURRENT_TASK)*8+SLOT_BASE+APPDATA.wnd_clientbox.left] |
1300 | add ebx,[edi+SLOT_BASE+APPDATA.wnd_clientbox.left] |
1298 | shl ebx,16 |
1301 | shl ebx,16 |
1299 | add ebx,[edx-twdw+WDATA.box.top] |
1302 | add ebx,[edx-twdw+WDATA.box.top] |
1300 | add ebx, [(edx-CURRENT_TASK)*8+SLOT_BASE+APPDATA.wnd_clientbox.top] |
1303 | add ebx,[edi+SLOT_BASE+APPDATA.wnd_clientbox.top] |
1301 | add eax,ebx |
1304 | add eax,ebx |
1302 | pop edx |
1305 | pop edx |
1303 | mov ebx,[esp+64+32-12+4] |
1306 | mov ebx,[esp+64+32-12+4] |
1304 | and ebx, not 0x80000000 ; force counted string |
1307 | and ebx, not 0x80000000 ; force counted string |
1305 | mov esi, [esp+64+4+4] |
1308 | mov esi, [esp+64+4+4] |
Line 2474... | Line 2477... | ||
2474 | ; Window state |
2477 | ; Window state |
Line 2475... | Line 2478... | ||
2475 | 2478 | ||
2476 | mov esi,[esp] |
2479 | mov esi,[esp] |
2477 | shl esi,5 |
2480 | shl esi,5 |
2478 | add esi,window_data + WDATA.box |
2481 | add esi,window_data + WDATA.box |
2479 | mov al,[esi+window_data+WDATA.fl_wstate] |
2482 | mov al,[esi+WDATA.fl_wstate] |
Line 2480... | Line 2483... | ||
2480 | mov [edi],al |
2483 | mov [edi],al |
2481 | 2484 | ||
Line 2486... | Line 2489... | ||
2486 | 2489 | ||
2487 | mov eax,[TASK_COUNT] |
2490 | mov eax,[TASK_COUNT] |
2488 | mov [esp+36],eax |
2491 | mov [esp+36],eax |
Line 2489... | Line -... | ||
2489 | ret |
- | |
2490 | - | ||
2491 | - | ||
2492 | 2492 | ret |
|
2493 | 2493 | ||
2494 | align 4 |
2494 | align 4 |
2495 | sys_clock: |
2495 | sys_clock: |
2496 | cli |
2496 | cli |