diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2019-02-13 20:31:47 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2019-02-13 20:31:47 +0100 |
commit | 314ad8e28161be580af1271bdaf05a4c6e7f6bd1 (patch) | |
tree | a98f1b35cddef99c60fc255bc1ae5408974fc19f /include | |
parent | 3fe0effd52c960dc3dce0b731ef266113f2d1893 (diff) | |
parent | 504ac299a531a0bd601e6db05dc1c2d3b86a9700 (diff) | |
download | barebox-314ad8e28161be580af1271bdaf05a4c6e7f6bd1.tar.gz barebox-314ad8e28161be580af1271bdaf05a4c6e7f6bd1.tar.xz |
Merge branch 'for-next/lseek'
Diffstat (limited to 'include')
-rw-r--r-- | include/driver.h | 7 | ||||
-rw-r--r-- | include/fs.h | 4 |
2 files changed, 3 insertions, 8 deletions
diff --git a/include/driver.h b/include/driver.h index 7da184d3ab..a8e046ed7f 100644 --- a/include/driver.h +++ b/include/driver.h @@ -360,11 +360,6 @@ int dummy_probe(struct device_d *); int generic_memmap_ro(struct cdev *dev, void **map, int flags); int generic_memmap_rw(struct cdev *dev, void **map, int flags); -static inline loff_t dev_lseek_default(struct cdev *cdev, loff_t ofs) -{ - return ofs; -} - static inline int dev_open_default(struct device_d *dev, struct filep *f) { return 0; @@ -439,7 +434,7 @@ struct cdev_operations { ssize_t (*write)(struct cdev*, const void* buf, size_t count, loff_t offset, ulong flags); int (*ioctl)(struct cdev*, int, void *); - loff_t (*lseek)(struct cdev*, loff_t); + int (*lseek)(struct cdev*, loff_t); int (*open)(struct cdev*, unsigned long flags); int (*close)(struct cdev*); int (*flush)(struct cdev*); diff --git a/include/fs.h b/include/fs.h index f1514afa92..38debfc41b 100644 --- a/include/fs.h +++ b/include/fs.h @@ -46,14 +46,14 @@ struct fs_driver_d { int (*unlink)(struct device_d *dev, const char *pathname); /* Truncate a file to given size */ - int (*truncate)(struct device_d *dev, FILE *f, ulong size); + int (*truncate)(struct device_d *dev, FILE *f, loff_t size); int (*open)(struct device_d *dev, FILE *f, const char *pathname); 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); int (*flush)(struct device_d *dev, FILE *f); - loff_t (*lseek)(struct device_d *dev, FILE *f, loff_t pos); + int (*lseek)(struct device_d *dev, FILE *f, loff_t pos); int (*ioctl)(struct device_d *dev, FILE *f, int request, void *buf); int (*erase)(struct device_d *dev, FILE *f, loff_t count, |