Changeset 3a6d6656 in mainline
- Timestamp:
- 2005-11-22T17:19:59Z (19 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 211bd8a5
- Parents:
- cc6f688
- Location:
- libc
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
libc/arch/ia32/src/syscall.c
rcc6f688 r3a6d6656 29 29 #include <libc.h> 30 30 31 unsigned int __syscall(const syscall_t id, const unsigned int p1, const unsigned int p2, const unsigned int p3)31 sysarg_t __syscall(const syscall_t id, const sysarg_t p1, const sysarg_t p2, const sysarg_t p3) 32 32 { 33 unsigned int ret;33 sysarg_t ret; 34 34 35 35 asm volatile ( -
libc/arch/mips32el/src/syscall.c
rcc6f688 r3a6d6656 29 29 #include <libc.h> 30 30 31 unsigned int __syscall(const syscall_t id, const unsigned int p1, const unsigned int p2, const unsigned int p3)31 sysarg_t __syscall(const syscall_t id, const sysarg_t p1, const sysarg_t p2, const sysarg_t p3) 32 32 { 33 register unsigned int __mips_reg_a0 asm("$4") = p1;34 register unsigned int __mips_reg_a1 asm("$5") = p2;35 register unsigned int __mips_reg_a2 asm("$6") = p3;36 register unsigned int __mips_reg_a3 asm("$7") = id;37 register unsigned int __mips_reg_v0 asm("$2");33 register sysarg_t __mips_reg_a0 asm("$4") = p1; 34 register sysarg_t __mips_reg_a1 asm("$5") = p2; 35 register sysarg_t __mips_reg_a2 asm("$6") = p3; 36 register sysarg_t __mips_reg_a3 asm("$7") = id; 37 register sysarg_t __mips_reg_v0 asm("$2"); 38 38 39 39 asm volatile ( -
libc/generic/io.c
rcc6f688 r3a6d6656 44 44 ssize_t write(int fd, const void * buf, size_t count) 45 45 { 46 return __syscall(SYS_IO, (sysarg_t) fd, (sysarg_t) buf, (sysarg_t) count);46 return (ssize_t) __syscall(SYS_IO, (sysarg_t) fd, (sysarg_t) buf, (sysarg_t) count); 47 47 } -
libc/include/libc.h
rcc6f688 r3a6d6656 41 41 extern void __main(void); 42 42 extern void __exit(void); 43 extern unsigned int __syscall(const syscall_t id, const sysarg_t p1, const sysarg_t p2, const sysarg_t p3);43 extern sysarg_t __syscall(const syscall_t id, const sysarg_t p1, const sysarg_t p2, const sysarg_t p3); 44 44 45 45
Note:
See TracChangeset
for help on using the changeset viewer.