Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 393 → Rev 394

/kernel/branches/flat_kernel/core/malloc.inc
972,9 → 972,7
 
align 4
init_malloc:
 
stdcall kernel_alloc, 0x20000
 
mov [mst.top], eax
mov [mst.topsize], 128*1024
mov dword [eax+4], (128*1024) or 1
/kernel/branches/flat_kernel/core/memory.inc
476,19 → 476,17
mov ebx, [ebp-4]
 
cmp ebx, 0x80000000
jae .user_space
jae .kernel_space
 
cmp ebx, page_tabs+0x800
jae .tab_space
 
cmp ebx, app_page_tabs
jae .alloc
 
cmp ebx, page_tabs
jae .tab_space
 
cmp ebx, 0x7DC00000
jae .lfb_addr
 
jmp .kernel_space
 
.user_space:
shr ebx, 12
mov ecx, ebx
/kernel/branches/flat_kernel/core/taskman.inc
392,20 → 392,21
mov [dir_addr], eax
stdcall map_page,[tmp_task_pdir],eax,dword PG_SW
 
mov esi, sys_pgdir
mov edi, [tmp_task_pdir]
mov ecx, (page_tabs shr 20)/4
mov ecx, (LFB_BASE shr 20)/4 ;(page_tabs shr 20)/4
xor eax, eax
rep stosd
 
mov esi, sys_pgdir+(LFB_BASE shr 20) ;(OS_BASE shr 20)
mov ecx, (OS_BASE shr 20)/4
cld
rep movsd
 
mov edi, [tmp_task_pdir]
mov eax, [dir_addr]
or eax, PG_SW
stosd ; [(page_tabs shr 20)]= eax
mov [edi+(page_tabs shr 20)], eax
 
mov ecx, 0x800/4
xor eax, eax
rep stosd
 
mov eax, [dir_addr]
call set_cr3
 
471,7 → 472,6
add edx, 0x1000
dec [app_pages]
jnz .alloc
 
end if
 
.done:
557,8 → 557,7
and eax, not 0xFFF
stdcall map_page,[tmp_task_pdir],eax,dword PG_SW
mov esi, [tmp_task_pdir]
add esi, 0x800
mov edi, 0x800/4
mov edi, (LFB_BASE shr 20)/4
.destroy:
mov eax, [esi]
test eax, 1