From 27f9ff5ab47354f933348663af30b9a28435c11b Mon Sep 17 00:00:00 2001 From: Sascha Hauer Date: Thu, 5 Jul 2007 18:01:40 +0200 Subject: [PATCH] svn_rev_290 add lseek --- include/fs.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/include/fs.h b/include/fs.h index 523d2f2c0..2597784a0 100644 --- a/include/fs.h +++ b/include/fs.h @@ -5,6 +5,7 @@ #define FS_TYPE_CRAMFS 1 #define FS_TYPE_RAMFS 2 +#define FS_TYPE_DEVFS 3 #define PATH_MAX 1024 /* include/linux/limits.h */ @@ -28,6 +29,7 @@ typedef struct filep { struct device_d *dev; /* The device this FILE belongs to */ ulong pos; /* current position in stream */ ulong size; /* The size of this inode */ + ulong flags; /* the O_* flags from open */ void *inode; /* private to the filesystem driver */ @@ -78,7 +80,13 @@ int close(int fd); int stat(const char *filename, struct stat *s); int read(int fd, void *buf, size_t count); ssize_t write(int fd, const void *buf, size_t count); -int ls(const char *path); + +#define SEEK_SET 1 +#define SEEK_CUR 2 +#define SEEK_END 3 + +off_t lseek(int fildes, off_t offset, int whence); +int ls(const char *path, ulong flags); int mkdir (const char *pathname); int mount (struct device_d *dev, char *fsname, char *path); int umount(const char *pathname);