《操作系统》的实验代码。
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

33 lines
914 B

12 years ago
12 years ago
  1. #ifndef __USER_LIBS_SYSCALL_H__
  2. #define __USER_LIBS_SYSCALL_H__
  3. int sys_exit(int error_code);
  4. int sys_fork(void);
  5. int sys_wait(int pid, int *store);
  6. int sys_exec(const char *name, int argc, const char **argv);
  7. int sys_yield(void);
  8. int sys_kill(int pid);
  9. int sys_getpid(void);
  10. int sys_putc(int c);
  11. int sys_pgdir(void);
  12. int sys_sleep(unsigned int time);
  13. int sys_gettime(void);
  14. struct stat;
  15. struct dirent;
  16. int sys_open(const char *path, uint32_t open_flags);
  17. int sys_close(int fd);
  18. int sys_read(int fd, void *base, size_t len);
  19. int sys_write(int fd, void *base, size_t len);
  20. int sys_seek(int fd, off_t pos, int whence);
  21. int sys_fstat(int fd, struct stat *stat);
  22. int sys_fsync(int fd);
  23. int sys_getcwd(char *buffer, size_t len);
  24. int sys_getdirentry(int fd, struct dirent *dirent);
  25. int sys_dup(int fd1, int fd2);
  26. void sys_lab6_set_priority(uint32_t priority); //only for lab6
  27. #endif /* !__USER_LIBS_SYSCALL_H__ */