/*************************************************************** __CPU_SYSCALLS.H This file contains CPU SYSCALL operation functions & data declarations. PART OF : CPU - library . USAGE : Internal only . NOTE : Include "libmcpu.h" before this FILE . Copyright (C) 2026 by Andrew V.Kosteltsev. All Rights Reserved. ***************************************************************/ #ifndef __CPU_SYSCALLS_H #define __CPU_SYSCALLS_H #ifdef __cplusplus extern "C" { #endif typedef __mpu_uint64_t (*__cpu_syscall_handler_t)( __mpu_uint32_t sysno ); extern void __cpu_fd_context_init( void ); extern void __cpu_fd_context_free( void ); extern void __cpu_cwd_context_init( void ); extern void __cpu_cwd_context_free( void ); extern __mpu_uint64_t __cpu_SYS_brk( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_gettimeofday( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_clock_getres( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_clock_gettime( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_nanosleep( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_clock_nanosleep( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_open ( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_close( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_dup ( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_dup2 ( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_read ( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_write( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_lseek( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_chdir( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_fchdir( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_stat ( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_fstat( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_lstat( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_fcntl( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_SYS_pipe2( __mpu_uint32_t sysno ); extern __mpu_uint64_t __cpu_syscall_dispatch( void ); #ifdef __cplusplus } /* ... extern "C" */ #endif #endif /* __CPU_SYSCALLS_H */