diff options
author | Robert Morris <[email protected]> | 2019-06-01 05:33:38 -0400 |
---|---|---|
committer | Robert Morris <[email protected]> | 2019-06-01 05:33:38 -0400 |
commit | 50cbc7510250a64674d619d13f5912edf08b767d (patch) | |
tree | 874895d11adb72fed959619d85596b062260276f /defs.h | |
parent | 7fd1f1eb0aab4d52852fc4f5e83eafc991f9a627 (diff) | |
download | xv6-labs-50cbc7510250a64674d619d13f5912edf08b767d.tar.gz xv6-labs-50cbc7510250a64674d619d13f5912edf08b767d.tar.bz2 xv6-labs-50cbc7510250a64674d619d13f5912edf08b767d.zip |
first shell prints $ prompt, though no console input yet
Diffstat (limited to 'defs.h')
-rw-r--r-- | defs.h | 14 |
1 files changed, 8 insertions, 6 deletions
@@ -31,9 +31,9 @@ struct file* filealloc(void); void fileclose(struct file*); struct file* filedup(struct file*); void fileinit(void); -int fileread(struct file*, char*, int n); -int filestat(struct file*, struct stat*); -int filewrite(struct file*, char*, int n); +int fileread(struct file*, uint64, int n); +int filestat(struct file*, uint64 addr); +int filewrite(struct file*, uint64, int n); // fs.c void readsb(int dev, struct superblock *sb); @@ -153,11 +153,11 @@ char* strncpy(char*, const char*, int); // syscall.c int argint(int, int*); -int argptr(int, char**, int); -int argstr(int, char**); +int argptr(int, uint64*, int); +int argstr(int, char*, int); int argaddr(int, uint64 *); int fetchint(uint64, int*); -int fetchstr(uint64, char**); +int fetchstr(uint64, char*, int); int fetchaddr(uint64, uint64*); void syscall(); @@ -188,6 +188,8 @@ void mappages(pagetable_t, uint64, uint64, uint64, int); void unmappages(pagetable_t, uint64, uint64, int); uint64 walkaddr(pagetable_t, uint64); int copyout(pagetable_t, uint64, char *, uint64); +int copyin(pagetable_t, char *, uint64, uint64); +int copyinstr(pagetable_t pagetable, char *dst, uint64 srcva, uint64 max); // number of elements in fixed-size array #define NELEM(x) (sizeof(x)/sizeof((x)[0])) |