/kernel/trunk/posix/futex.inc |
---|
81,7 → 81,7 |
.cmp_requeue: |
.wait_bitset: |
.wake_bitset: |
mov [esp + SYSCALL_STACK._eax], -1 |
mov [esp + SYSCALL_STACK.eax], -1 |
ret |
align 4 |
91,7 → 91,7 |
jz @F |
mov eax, [eax + FUTEX.handle] |
@@: |
mov [esp + SYSCALL_STACK._eax], eax |
mov [esp + SYSCALL_STACK.eax], eax |
ret |
align 4 |
101,7 → 101,7 |
.destroy: |
mov ecx, ebp |
call destroy_futex |
mov [esp + SYSCALL_STACK._eax], eax |
mov [esp + SYSCALL_STACK.eax], eax |
ret |
align 4 |
118,7 → 118,7 |
lock cmpxchg [ecx], edx |
je .wait_slow |
mov [esp + SYSCALL_STACK._eax], -2 |
mov [esp + SYSCALL_STACK.eax], -2 |
ret |
.wait_slow: |
143,7 → 143,7 |
add esp, sizeof.MUTEX_WAITER |
popfd |
mov [esp + SYSCALL_STACK._eax], 0 |
mov [esp + SYSCALL_STACK.eax], 0 |
ret |
align 4 |
159,7 → 159,7 |
lock cmpxchg [ecx], edx ;wait until old_value == new_value |
je .wait_slow_timeout |
mov [esp + SYSCALL_STACK._eax], -2 |
mov [esp + SYSCALL_STACK.eax], -2 |
ret |
align 4 |
200,7 → 200,7 |
add esp, sizeof.MUTEX_WAITER |
popfd |
mov [esp + SYSCALL_STACK._eax], 0 |
mov [esp + SYSCALL_STACK.eax], 0 |
ret |
.timeout: |
208,7 → 208,7 |
add esp, sizeof.MUTEX_WAITER |
popfd |
mov [esp + SYSCALL_STACK._eax], -1 |
mov [esp + SYSCALL_STACK.eax], -1 |
ret |
239,6 → 239,6 |
jb .again_wake |
.done: |
popfd |
mov [esp + SYSCALL_STACK._eax], ecx |
mov [esp + SYSCALL_STACK.eax], ecx |
ret |
/kernel/trunk/posix/pipe.inc |
---|
115,7 → 115,7 |
add esp, 5*4 |
pop ebp |
xor eax, eax |
mov [esp + SYSCALL_STACK._eax], eax |
mov [esp + SYSCALL_STACK.eax], eax |
ret |
.err_3: |
mov eax, ebp |
132,7 → 132,7 |
.fail: |
mov eax, ebp |
pop ebp |
mov [esp + SYSCALL_STACK._eax], eax |
mov [esp + SYSCALL_STACK.eax], eax |
ret |
purge .pipeflags |
169,7 → 169,7 |
.read: |
mov esi, [ebp + PIPE.buffer] |
add esi, [ebp + PIPE.read_end] |
mov [esp + SYSCALL_STACK._eax], ecx |
mov [esp + SYSCALL_STACK.eax], ecx |
sub [ebp + PIPE.count], ecx |
cld |
rep movsb |
223,7 → 223,7 |
jmp .again |
.eof: |
mov [esp + SYSCALL_STACK._eax], eax |
mov [esp + SYSCALL_STACK.eax], eax |
lea ecx, [ebp + PIPE.pipe_lock] |
call mutex_unlock |
ret |
297,7 → 297,7 |
jnz .again |
pop eax ; written |
mov [esp + SYSCALL_STACK._eax], eax |
mov [esp + SYSCALL_STACK.eax], eax |
ret |
.wait: |
330,10 → 330,10 |
call mutex_unlock |
add esp, 4 |
mov [esp + SYSCALL_STACK._eax], -EPIPE |
mov [esp + SYSCALL_STACK.eax], -EPIPE |
ret |
align 4 |
pipe_close: |
mov [esp + SYSCALL_STACK._eax], -EBADF |
mov [esp + SYSCALL_STACK.eax], -EBADF |
ret |
/kernel/trunk/posix/posix.inc |
---|
64,7 → 64,7 |
jmp dword [sys_posix_call + ebx*4] |
.fail: |
mov [esp + SYSCALL_STACK._eax], -EBADF |
mov [esp + SYSCALL_STACK.eax], -EBADF |
ret |
95,7 → 95,7 |
mov eax, [ebp] |
jmp dword [eax + FILEOP_READ*4] |
.fail: |
mov [esp + SYSCALL_STACK._eax], -EBADF |
mov [esp + SYSCALL_STACK.eax], -EBADF |
ret |
;ssize_t write(int fd, const void *buf, size_t count); |
124,6 → 124,6 |
mov eax, [ebp] |
jmp dword [eax + FILEOP_WRITE*4] |
.fail: |
mov [esp + SYSCALL_STACK._eax], -EBADF |
mov [esp + SYSCALL_STACK.eax], -EBADF |
ret |