summaryrefslogtreecommitdiff
path: root/include/fs.h
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2008-06-06 09:25:13 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2008-06-06 09:30:48 +0200
commitee6d36a5405305f3bbdb0457948c219731b3d9cc (patch)
tree0a328bd96f2cf2f190372b654515e509c694930a /include/fs.h
parent3f73e61600f8fce0b6fa02e9a82124c1c89937c7 (diff)
downloadbarebox-ee6d36a5405305f3bbdb0457948c219731b3d9cc.tar.gz
- introduce ioctl call
- pass open/close/lseek through to drivers
Diffstat (limited to 'include/fs.h')
-rw-r--r--include/fs.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/fs.h b/include/fs.h
index 31243f399f..2500f14c54 100644
--- a/include/fs.h
+++ b/include/fs.h
@@ -58,12 +58,14 @@ struct fs_driver_d {
int (*close)(struct device_d *dev, FILE *f);
int (*read)(struct device_d *dev, FILE *f, void *buf, size_t size);
int (*write)(struct device_d *dev, FILE *f, const void *buf, size_t size);
+ off_t (*lseek)(struct device_d *dev, FILE *f, off_t pos);
struct dir* (*opendir)(struct device_d *dev, const char *pathname);
struct dirent* (*readdir)(struct device_d *dev, struct dir *dir);
int (*closedir)(struct device_d *dev, DIR *dir);
int (*stat)(struct device_d *dev, const char *file, struct stat *stat);
+ int (*ioctl)(struct device_d *dev, FILE *f, int request, void *buf);
int (*erase)(struct device_d *dev, FILE *f, size_t count,
unsigned long offset);
int (*protect)(struct device_d *dev, FILE *f, size_t count,
@@ -101,6 +103,7 @@ int unlink(const char *pathname);
int close(int fd);
int stat(const char *filename, struct stat *s);
int read(int fd, void *buf, size_t count);
+int ioctl(int fd, int request, void *buf);
ssize_t write(int fd, const void *buf, size_t count);
#define SEEK_SET 1