Subversion Repositories Kolibri OS

Compare Revisions

No changes between revisions

Regard whitespace Rev 863 → Rev 864

/kernel/branches/kolibri_pe/boot/boot.asm
4,7 → 4,7
 
include '../macros.inc'
 
$Revision: 849 $
$Revision$
 
__REV__ = __REV
 
Property changes:
Added: svn:keywords
+Revision
\ No newline at end of property
/kernel/branches/kolibri_pe/core/dll.inc
585,12 → 585,15
test eax, eax
jnz .fail
 
mov eax, [file_size]
cmp eax, 1024*1024*16
mov ecx, [file_size]
cmp ecx, 1024*1024*16
ja .fail
 
stdcall kernel_alloc, [file_size]
mov edx, PG_SW
call @mem_alloc@8
mov [file], eax
test eax, eax
jz .fail
 
stdcall read_file, [file_name], eax, dword 0, [file_size]
cmp ebx, [file_size]
599,10 → 602,11
mov eax, [file]
cmp dword [eax], 0x4B43504B
jne .exit
mov ebx, [eax+4]
mov [file_size], ebx
stdcall kernel_alloc, ebx
 
mov ecx, [eax+4]
mov [file_size], ecx
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jz .cleanup
 
824,20 → 828,20
 
mov [coff], eax
 
movzx ecx, [eax+CFH.nSections]
xor ebx, ebx
 
movzx ebx, [eax+CFH.nSections]
lea edx, [eax+20]
xor ecx, ecx
@@:
add ebx, [edx+CFS.SizeOfRawData]
add ebx, 15
and ebx, not 15
add ecx, [edx+CFS.SizeOfRawData]
add ecx, 15
and ecx, not 15
add edx, COFF_SECTION_SIZE
dec ecx
dec ebx
jnz @B
mov [img_size], ebx
 
stdcall kernel_alloc, ebx
mov [img_size], ecx
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jz .fail
mov [img_base], eax
/kernel/branches/kolibri_pe/core/exports.inc
31,7 → 31,6
szPciWrite32 db 'PciWrite32',0
 
szAllocPage db 'AllocPage',0
szAllocPages db 'AllocPages',0
szFreePage db 'FreePage',0
szGetPgAddr db 'GetPgAddr',0
szMapPage db 'MapPage',0
42,7 → 41,7
 
szAllocKernelSpace db 'AllocKernelSpace',0
szFreeKernelSpace db 'FreeKernelSpace',0
szKernelAlloc db 'KernelAlloc',0
szHeapAlloc db 'HeapAlloc',0
szKernelFree db 'KernelFree',0
szUserAlloc db 'UserAlloc',0
szUserFree db 'UserFree',0
104,7 → 103,6
dd szPciWrite32 , pci_write32
 
dd szAllocPage , _alloc_page ;stdcall
dd szAllocPages , _alloc_pages ;stdcall
dd szFreePage , free_page
dd szMapPage , map_page ;stdcall
dd szMapSpace , map_space
113,9 → 111,8
dd szCommitPages , commit_pages ;not implemented
dd szReleasePages , release_pages
 
dd szAllocKernelSpace, alloc_kernel_space ;stdcall
dd szFreeKernelSpace , free_kernel_space ;stdcall
dd szKernelAlloc , kernel_alloc ;stdcall
dd szHeapAlloc , @heap_alloc@8 ;fastcall
dd szKernelFree , kernel_free ;stdcall
dd szUserAlloc , user_alloc ;stdcall
dd szUserFree , user_free ;stdcall
/kernel/branches/kolibri_pe/core/heap.c
335,10 → 335,7
return NULL;
};
 
void* __stdcall alloc_kernel_space(size_t size); //__asm__("alloc_kernel_space");
 
 
void* __stdcall alloc_kernel_space(size_t size)
void * __fastcall heap_alloc(size_t size, u32_t flags)
{
md_t *md;
 
346,16 → 343,36
 
md = find_small_md(size);
 
DBG("alloc_kernel_space: %x size %x\n\n",md->base, size);
if( md )
{
if( flags & PG_MAP )
{
count_t tmp = size >> 12;
addr_t *pte = &((addr_t*)page_tabs)[md->base>>12];
 
if( md )
while(tmp)
{
u32_t order;
addr_t frame;
size_t size;
 
asm volatile ("bsr %0, %1":"=&r"(order):"r"(tmp):"cc");
asm volatile ("btr %0, %1" :"=r"(tmp):"r"(order):"cc");
 
frame = core_alloc(order) | flags;
 
size = (1 << order);
while(size--)
{
*pte++ = frame;
frame+= 4096;
};
};
};
DBG("alloc_heap: %x size %x\n\n",md->base, size);
return (void*)md->base;
};
return NULL;
}
};
 
//void* __stdcall kernel_alloc(size_t size)
//{
//
// return NULL;
//}
//*/
 
/kernel/branches/kolibri_pe/core/heap.inc
45,81 → 45,7
ret
endp
 
align 4
proc kernel_alloc stdcall, size:dword
locals
lin_addr dd ?
pages_count dd ?
endl
 
push ebx
push edi
 
mov eax, [size]
add eax, 4095
and eax, not 4095;
mov [size], eax
test eax, eax
jz .err
 
mov ebx, eax
shr ebx, 12
mov [pages_count], ebx
 
stdcall alloc_kernel_space, eax
test eax, eax
jz .err
mov [lin_addr], eax
 
mov ecx, [pages_count]
mov edx, eax
mov ebx, ecx
 
shr ecx, 3
jz .next
 
and ebx, not 7
push ebx
stdcall _alloc_pages, ebx
pop ecx ; yes ecx!!!
test eax, eax
jz .err
 
mov edi, eax
mov edx, [lin_addr]
@@:
stdcall map_page,edx,edi,dword PG_SW
add edx, 0x1000
add edi, 0x1000
dec ecx
jnz @B
.next:
mov ecx, [pages_count]
and ecx, 7
jz .end
@@:
push ecx
call _alloc_page
pop ecx
test eax, eax
jz .err
 
stdcall map_page,edx,eax,dword PG_SW
add edx, 0x1000
dec ecx
jnz @B
.end:
mov eax, [lin_addr]
pop edi
pop ebx
ret
.err:
xor eax, eax
pop edi
pop ebx
ret
endp
 
align 4
proc kernel_free stdcall, base:dword
 
/kernel/branches/kolibri_pe/core/malloc.inc
983,7 → 983,9
align 4
init_malloc:
 
stdcall kernel_alloc, 0x40000
mov ecx, 6
call @core_alloc@4
add eax, OS_BASE
 
mov [mst.top], eax
mov [mst.topsize], 256*1024
/kernel/branches/kolibri_pe/core/memory.inc
37,42 → 37,37
 
proc map_io_mem stdcall, base:dword, size:dword, flags:dword
 
push ebx
push edi
mov eax, [size]
add eax, 4095
and eax, -4096
mov [size], eax
stdcall alloc_kernel_space, eax
 
mov ecx, [size]
add ecx, 4095
and ecx, -4096
mov [size], ecx
xor edx, edx
call @mem_alloc@8
test eax, eax
jz .fail
push eax
 
mov edi, 0x1000
mov ebx, eax
mov edx, eax
mov edi, eax
shr edi, 10
add edi, page_tabs
 
mov ecx,[size]
mov edx, [base]
shr eax, 12
shr ecx, 12
and edx, -4096
or edx, [flags]
mov eax, [base]
and eax, -4096
or eax, [flags]
@@:
mov [page_tabs+eax*4], edx
; push eax
; invlpg [ebx]
; pop eax
inc eax
add ebx, edi
add edx, edi
stosd
add eax, 0x1000
loop @B
 
pop eax
mov edx, [base]
and edx, 4095
mov eax, [base]
and eax, 4095
add eax, edx
.fail:
pop edi
pop ebx
ret
endp
 
194,8 → 189,9
cmp dword [LFBAddress], -1
jne @f
mov [BOOT_VAR+0x901c],byte 2
stdcall _alloc_pages, 0x280000 shr 12
add eax, OS_BASE
mov ecx, 0x280000
mov edx, PG_SW
call @mem_alloc@8
mov [LFBAddress], eax
ret
@@:
477,7 → 473,8
test edx, PG_MAP
jnz @F
 
call _alloc_page
xor ecx, ecx
call @core_alloc@4
test eax, eax
jz .fail
 
789,11 → 786,12
mov ecx, [ipc_tmp]
cmp esi, 0x40000-0x1000 ; size of [ipc_tmp] minus one page
jbe @f
push eax esi edi
add esi,0x1000
stdcall alloc_kernel_space,esi
push eax
lea ecx, [esi+0x1000]
xor edx, edx
call @mem_alloc@8
mov ecx, eax
pop edi esi eax
pop eax
@@:
mov [used_buf], ecx
stdcall map_mem, ecx, [SLOT_BASE+eax+0xB8],\
820,7 → 818,6
mov [edi+4], ecx
add edi, 8
mov esi, [msg_addr]
; add esi, new_app_base
cld
rep movsb
 
1154,54 → 1151,50
buf_ptr dd ?
endl
 
mov eax, [size]
test eax, eax
jz .fail
mov ecx, [size]
test ecx, 4095
jnz .fail
 
add eax, eax
stdcall alloc_kernel_space, eax
add ecx, ecx
xor edx, edx
call @mem_alloc@8
test eax, eax
mov [buf_ptr], eax
jz .fail
 
push ebx
 
mov [buf_ptr], eax
xor ecx, ecx
mov edx, [size]
shr edx, 12
mov ebx, edx
dec edx
bsr ecx, edx
inc ecx
 
mov ebx, [size]
shr ebx, 12
push ebx
 
stdcall _alloc_pages, ebx
pop ecx
 
call @core_alloc@4
test eax, eax
jz .mm_fail
 
push edi
 
or eax, [flags]
mov edi, [buf_ptr]
mov ebx, [buf_ptr]
mov edx, ecx
shl edx, 2
shr edi, 10
mov edx, [buf_ptr]
lea ecx, [ebx*4]
shr edx, 10
@@:
mov [page_tabs+edi], eax
mov [page_tabs+edi+edx], eax
mov [page_tabs+edx], eax
mov [page_tabs+edx+ecx], eax
add eax, 0x1000
add ebx, 0x1000
add edi, 4
dec ecx
add edx, 4
dec ebx
jnz @B
 
mov eax, [buf_ptr]
pop edi
pop ebx
ret
.mm_fail:
stdcall free_kernel_space, [buf_ptr]
;stdcall free_kernel_space, [buf_ptr]
pop ebx
xor eax, eax
pop ebx
.fail:
ret
endp
/kernel/branches/kolibri_pe/core/mm.c
559,7 → 559,7
v = zone_frame_alloc(&z_core, order);
spinlock_unlock(&z_core.lock);
safe_sti(efl);
 
DBG("core alloc: %x, size %x\n", v << FRAME_WIDTH, (1<<order)<<12);
return (v << FRAME_WIDTH);
};
 
593,29 → 593,6
return (v << FRAME_WIDTH);
};
 
addr_t __stdcall alloc_pages(count_t count) //obsolete
{
eflags_t efl;
u32_t edx;
pfn_t v;
 
count = (count+7)&~7;
 
edx = save_edx();
efl = safe_cli();
spinlock_lock(&z_core.lock);
v = zone_frame_alloc(&z_core, to_order(count));
spinlock_unlock(&z_core.lock);
safe_sti(efl);
 
DBG("alloc_pages: %x count %x\n", v << FRAME_WIDTH, count);
 
restore_edx(edx);
 
return (v << FRAME_WIDTH);
};
 
 
void __fastcall zone_free(zone_t *zone, pfn_t frame_idx)
{
frame_t *frame;
/kernel/branches/kolibri_pe/core/peload.inc
24,14 → 24,14
 
mov [image], eax
 
mov edx, [eax+60]
 
stdcall kernel_alloc, [eax+80+edx]
mov ebx, [eax+60]
mov ecx, [eax+80+edx]
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
mov [base], eax
jz .cleanup
 
mov [base], eax
 
stdcall map_PE, eax, [image]
 
mov [entry], eax
279,13 → 279,11
align 16
__exports:
export 'KERNEL', \
alloc_kernel_space, 'AllocKernelSpace', \ ; stdcall
commit_pages, 'CommitPages', \ ; eax, ebx, ecx
create_kernel_object, 'CreateObject', \
create_ring_buffer, 'CreateRingBuffer', \ ; stdcall
destroy_kernel_object, 'DestroyObject', \
free_kernel_space, 'FreeKernelSpace', \ ; stdcall
kernel_alloc, 'KernelAlloc', \ ; stdcall
kernel_free, 'KernelFree', \ ; stdcall
malloc, 'Kmalloc', \
free, 'Kfree', \
/kernel/branches/kolibri_pe/core/taskman.inc
955,7 → 955,8
pl0_stack dd ?
endl
 
stdcall _alloc_pages, (RING0_STACK_SIZE+512) shr 12
mov ecx, 1 ;(RING0_STACK_SIZE+512) shr 12
call @core_alloc@4
add eax, OS_BASE
mov [pl0_stack], eax
 
/kernel/branches/kolibri_pe/core/v86.inc
49,10 → 49,11
; first half (0x800 bytes) is page table for addresses 0 - 0x100000,
; second half is for V86-to-linear translation.
; Third and fourth are for I/O permission map.
push 8000h ; blocks less than 8 pages are discontinuous
call kernel_alloc
mov ecx, 2
call @core_alloc@4
test eax, eax
jz .fail2
add eax, OS_BASE
mov [ebx+V86_machine.pagedir], eax
push edi eax
mov edi, eax
/kernel/branches/kolibri_pe/detect/getcache.inc
91,7 → 91,9
and [esi+cache_ide0_search_start-cache_ide0],0
and [esi+cache_ide0_appl_search_start-cache_ide0],0
push ecx
stdcall kernel_alloc,[esi+cache_ide0_size-cache_ide0]
mov ecx, [esi+cache_ide0_size-cache_ide0]
mov edx, PG_SW
call @mem_alloc@8
mov [esi+cache_ide0_pointer-cache_ide0],eax
pop ecx
mov edx,eax
/kernel/branches/kolibri_pe/drivers/imports.inc
36,7 → 36,6
PciWrite32,\
\
AllocPage,\
AllocPages,\
FreePage,\
MapPage,\
MapSpace,\
45,9 → 44,8
CommitPages,\
ReleasePages,\
\
AllocKernelSpace,\
FreeKernelSpace,\
KernelAlloc,\
HeapAlloc,\
KernelFree,\
UserAlloc,\
UserFree,\
/kernel/branches/kolibri_pe/drivers/infinity.asm
81,7 → 81,9
jz .fail
mov [hSound], eax
 
stdcall KernelAlloc, 16*512
mov ecx, 16*512
mov edx, PG_SW
call HeapAlloc
test eax, eax
jz .out_of_mem
mov [mix_buff], eax
325,7 → 327,6
locals
str dd ?
ring_size dd ?
ring_pages dd ?
endl
 
mov eax, [format]
402,8 → 403,6
.waveout:
mov [ring_size], ebx
mov eax, ebx
shr ebx, 12
mov [ring_pages], ebx
 
stdcall CreateRingBuffer, eax, PG_SW
 
426,7 → 425,8
mov ecx, [size]
add ecx, 128 ;resampler required
mov [eax+STREAM.in_size], ecx
stdcall KernelAlloc, ecx
mov edx, PG_SW
call HeapAlloc
 
mov edi, [str]
mov [edi+STREAM.in_base], eax
440,7 → 440,7
mov [edi+STREAM.in_top], eax
 
.out_buff:
stdcall AllocKernelSpace, dword 128*1024
stdcall CreateRingBuffer, 64*1024, PG_SW
 
mov edi, [str]
mov [edi+STREAM.out_base], eax
450,21 → 450,6
add eax, 64*1024
mov [edi+STREAM.out_top], eax
 
stdcall AllocPages, dword 64/4
mov edi, [str]
mov ebx, [edi+STREAM.out_base]
mov ecx, 16
or eax, PG_SW
push eax
push ebx
call CommitPages ;eax, ebx, ecx
mov ecx, 16
pop ebx
pop eax
add ebx, 64*1024
call CommitPages ;double mapped
 
mov edi, [str]
mov ecx, [edi+STREAM.in_top]
mov edi, [edi+STREAM.in_base]
sub ecx, edi
/kernel/branches/kolibri_pe/drivers/sis.asm
32,6 → 32,8
 
CPU_FREQ equ 2600d
 
PG_SW equ 0x003
 
BIT0 EQU 0x00000001
BIT1 EQU 0x00000002
BIT2 EQU 0x00000004
507,7 → 509,9
align 4
proc create_primary_buff
 
stdcall KernelAlloc, 0x10000
mov ecx, 0x10000
mov edx, PG_SW
call HeapAlloc
mov [ctrl.buffer], eax
 
mov edi, eax
/kernel/branches/kolibri_pe/drivers/sound.asm
32,6 → 32,8
 
CPU_FREQ equ 2600d
 
PG_SW equ 0x003
 
BIT0 EQU 0x00000001
BIT1 EQU 0x00000002
BIT2 EQU 0x00000004
529,7 → 531,9
align 4
proc create_primary_buff
 
stdcall KernelAlloc, 0x10000
mov ecx, 0x10000
mov edx, PG_SW
call HeapAlloc
mov [ctrl.buffer], eax
 
mov edi, eax
/kernel/branches/kolibri_pe/fs/ntfs.inc
133,14 → 133,15
mov eax, 1
shl eax, cl
.4:
mov ecx, [ntfs_data.frs_size]
mov [ntfs_data.iab_size], eax
; allocate space for buffers
add eax, [ntfs_data.frs_size]
push eax
call kernel_alloc
add ecx, eax
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
mov [ntfs_data.frs_buffer], eax
jz problem_fat_dec_count
mov [ntfs_data.frs_buffer], eax
add eax, [ntfs_data.frs_size]
mov [ntfs_data.iab_buffer], eax
; read $MFT disposition
177,10 → 178,9
.mftok:
; read $MFT table retrieval information
; start with one page, increase if not enough (when MFT too fragmented)
push ebx
push 0x1000
call kernel_alloc
pop ebx
mov ecx, 0x1000
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jz .fail_free_frs
mov [ntfs_data.mft_retrieval], eax
225,11 → 225,12
; if they will be needed, they will be loaded later
 
mov [ntfs_data.cur_index_size], 0x1000/0x200
push 0x1000
call kernel_alloc
mov ecx, 0x1000
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
mov [ntfs_data.cur_index_buf], eax
jz .fail_free_mft
mov [ntfs_data.cur_index_buf], eax
 
popad
call free_hd_channel
241,11 → 242,12
mov eax, [ntfs_data.mft_retrieval_size]
cmp eax, [ntfs_data.mft_retrieval_alloc]
jnz .ok
add eax, 0x1000/8
mov [ntfs_data.mft_retrieval_alloc], eax
shl eax, 3
push eax
call kernel_alloc
 
lea ecx, [eax+0x1000/8]
mov [ntfs_data.mft_retrieval_alloc], ecx
shl ecx, 3
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jnz @f
popad
980,10 → 982,10
push eax
push [ntfs_data.cur_index_buf]
call kernel_free
pop eax
mov [ntfs_data.cur_index_size], eax
push eax
call kernel_alloc
pop ecx
mov [ntfs_data.cur_index_size], ecx
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jnz @f
and [ntfs_data.cur_index_size], 0
998,12 → 1000,13
shr ebp, 9
cmp ebp, [ntfs_data.cur_index_size]
jbe .ok2
push esi ebp
push ebp
call kernel_alloc
pop ebp esi
 
mov ecx, ebp
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jz .stc_ret
 
mov edi, eax
mov ecx, [ntfs_data.cur_index_size]
shl ecx, 9-2
1326,10 → 1329,10
push eax
push [ntfs_data.cur_index_buf]
call kernel_free
pop eax
mov [ntfs_data.cur_index_size], eax
push eax
call kernel_alloc
pop ecx
mov [ntfs_data.cur_index_size], ecx
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jnz @f
and [ntfs_data.cur_index_size], 0
1349,12 → 1352,13
shr ebp, 9
cmp ebp, [ntfs_data.cur_index_size]
jbe .ok2
push esi ebp
push ebp
call kernel_alloc
pop ebp esi
 
mov ecx, ebp
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
jz .nomem
 
mov edi, eax
mov ecx, [ntfs_data.cur_index_size]
shl ecx, 9-2
/kernel/branches/kolibri_pe/fs/parse_fn.inc
84,7 → 84,10
endp
 
proc load_file_parse_table
stdcall kernel_alloc,0x1000
 
xor eac, ecx
call @core_alloc@4
add eax, OS_BASE
mov [tmp_file_name_table],eax
mov edi,eax
mov esi,sysdir_name
/kernel/branches/kolibri_pe/gui/event.inc
10,7 → 10,11
 
align 4
init_events:
stdcall kernel_alloc, 512*EVENT_SIZE
 
mov ecx, 512*EVENT_SIZE
mov edx, PG_SW
call @mem_alloc@8
 
mov [events], eax
xor eax, eax
mov [event_uid], eax
/kernel/branches/kolibri_pe/include/mm.h
29,14 → 29,18
}phismem_t;
 
 
# define PA2KA(x) (((addr_t) (x)) + OS_BASE)
# define KA2PA(x) (((addr_t) (x)) - OS_BASE)
#define PG_MAP 1
 
 
#define PAGE_SIZE 4096
#define FRAME_WIDTH 12
 
#define BUDDY_SYSTEM_INNER_BLOCK 0xff
 
 
# define PA2KA(x) (((addr_t) (x)) + OS_BASE)
# define KA2PA(x) (((addr_t) (x)) - OS_BASE)
 
static inline count_t SIZE2FRAMES(size_t size)
{
if (!size)
66,3 → 70,5
 
void __fastcall frame_set_parent(pfn_t pfn, void *data);
void* __fastcall frame_get_parent(pfn_t pfn);
 
void* __fastcall heap_alloc(size_t size, u32_t flags) ;
/kernel/branches/kolibri_pe/kernel.asm
141,6 → 141,8
extrn _init
extrn _init_mm
 
extrn @core_alloc@4
 
extrn @init_heap@8
extrn @find_large_md@4
extrn @find_small_md@4
147,18 → 149,19
extrn @phis_alloc@4
extrn @mem_alloc@8
 
extrn _alloc_kernel_space@4
extrn @heap_alloc@8
 
extrn _slab_cache_init
extrn _alloc_pages
extrn _alloc_page
 
extrn _get_free_mem
 
alloc_kernel_space equ _alloc_kernel_space@4
 
extrn _bx_from_load
 
 
@mem_alloc@8 equ @heap_alloc@8
 
 
section '.flat' code readable align 4096
 
use32
555,7 → 558,9
call init_fpu
call init_malloc
 
stdcall alloc_kernel_space, 0x51000
mov ecx, 0x51000
xor edx, edx
call @mem_alloc@8
mov [default_io_map], eax
 
add eax, 0x2000
611,8 → 616,10
mov [BgrDrawMode],eax
mov [BgrDataWidth],eax
mov [BgrDataHeight],eax
mov ecx, 4095
mov edx, PG_SW
mov [mem_BACKGROUND],4095
stdcall kernel_alloc, [mem_BACKGROUND]
call @mem_alloc@8
mov [img_background], eax
 
mov [SLOT_BASE + 256 + APPDATA.dir_table], _sys_pdbr + (0x100000000-OS_BASE)
2290,10 → 2297,11
@@:
mov eax,[BgrDataWidth]
imul eax,[BgrDataHeight]
lea eax,[eax*3]
mov [mem_BACKGROUND],eax
lea ecx,[eax*3]
mov [mem_BACKGROUND],ecx
; get memory for new background
stdcall kernel_alloc, eax
mov edx, PG_SW
stdcall @mem_alloc@8
test eax, eax
jz .exit_mem
mov [img_background], eax
/kernel/branches/kolibri_pe/makefile
11,13 → 11,20
 
KERNEL_SRC:= \
kernel.asm \
data32.inc \
core/memory.inc \
core/heap.inc \
core/malloc.inc \
core/taskman.inc \
core/v86.inc \
core/sys32.inc \
core/dll.inc \
data32.inc
core/exports.inc \
fs/ntfs.inc \
gui/event.inc \
video/cursors.inc
 
 
PE_SRC:= \
init.c \
mm.c \
/kernel/branches/kolibri_pe/video/cursors.inc
313,13 → 313,14
mov [eax+CURSOR.hot_x], ebx
mov [eax+CURSOR.hot_y], ebx
 
stdcall kernel_alloc, 0x1000
mov edi, eax
mov ecx, 0x1000
mov edx, PG_SW
call @mem_alloc@8
test eax, eax
mov [edi+CURSOR.base], eax
jz .fail
 
mov edi, [.hcursor]
mov [edi+CURSOR.base], eax
 
mov esi, [.src]
mov ebx, [.flags]
cmp bx, LOAD_INDIRECT