Rev 8985 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 8985 | Rev 8986 | ||
---|---|---|---|
Line 3... | Line 3... | ||
3 | ;; Copyright (C) KolibriOS team 2004-2021. All rights reserved. ;; |
3 | ;; Copyright (C) KolibriOS team 2004-2021. All rights reserved. ;; |
4 | ;; Distributed under terms of the GNU General Public License. ;; |
4 | ;; Distributed under terms of the GNU General Public License. ;; |
5 | ;; ;; |
5 | ;; ;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
6 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 7... | Line 7... | ||
7 | 7 | ||
Line 8... | Line 8... | ||
8 | $Revision: 8876 $ |
8 | $Revision: 8986 $ |
9 | 9 | ||
10 | align 4 ;3A08 |
10 | align 4 ;3A08 |
11 | build_interrupt_table: |
11 | build_interrupt_table: |
Line 365... | Line 365... | ||
365 | 365 | ||
Line 366... | Line 366... | ||
366 | ret |
366 | ret |
367 | 367 | ||
368 | ; sysfn 64 implementation |
368 | ; sysfn 64 implementation |
369 | align 4 |
369 | align 4 |
370 | sys_resize_app_memory: |
370 | syscall_resize_app_memory: |
371 | ; in: eax = 64 - function number |
371 | ; in: eax = 64 - function number |
372 | ; ebx = 1 - number of its only subfunction |
372 | ; ebx = 1 - number of its only subfunction |
373 | ; ecx = new amount of memory |
373 | ; ecx = new amount of memory |
Line 725... | Line 725... | ||
725 | jnz @f |
725 | jnz @f |
726 | and dword [ecx], 0 |
726 | and dword [ecx], 0 |
727 | pushad |
727 | pushad |
728 | xchg eax, ecx |
728 | xchg eax, ecx |
729 | mov ebx, 2 |
729 | mov ebx, 2 |
730 | call sys_system |
730 | call syscall_system |
731 | popad |
731 | popad |
732 | @@: |
732 | @@: |
733 | inc eax |
733 | inc eax |
734 | add ecx, 0x100 |
734 | add ecx, 0x100 |
735 | jmp .xd0 |
735 | jmp .xd0 |
Line 811... | Line 811... | ||
811 | mov edx, [current_slot] |
811 | mov edx, [current_slot] |
812 | ; Atomically decrement depth of critical areas. |
812 | ; Atomically decrement depth of critical areas. |
813 | lock dec [edx+APPDATA.terminate_protection] |
813 | lock dec [edx+APPDATA.terminate_protection] |
814 | ; If the result of decrement is zero, somebody has requested termination, |
814 | ; If the result of decrement is zero, somebody has requested termination, |
815 | ; but at that moment we were inside a critical area; terminate now. |
815 | ; but at that moment we were inside a critical area; terminate now. |
816 | jz sys_end |
816 | jz syscall_end |
817 | ; Otherwise, return to the caller. |
817 | ; Otherwise, return to the caller. |
818 | ret |
818 | ret |
819 | endp |
819 | endp |
Line 820... | Line 820... | ||
820 | 820 |