summaryrefslogtreecommitdiffstats
path: root/fs/ratpfs.c
Commit message (Collapse)AuthorAgeFilesLines
* Rename struct fs_driver_d to fs_driverSascha Hauer2023-01-101-1/+1
| | | | | | | | | Remove the meaningless '_d' suffix. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> Link: https://lore.barebox.org/20221214123512.189688-6-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Rename struct fs_device_d to fs_deviceSascha Hauer2023-01-101-1/+1
| | | | | | | | | Remove the meaningless '_d' suffix. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> Link: https://lore.barebox.org/20221214123512.189688-5-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Rename struct device_d to deviceSascha Hauer2023-01-101-22/+22
| | | | | | | | | | | | | The '_d' suffix was originally introduced in case we want to import Linux struct device as a separate struct into barebox. Over time it became clear that this won't happen, instead barebox struct device_d is basically the same as Linux struct device. Rename the struct name accordingly to make porting Linux code easier. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> Link: https://lore.barebox.org/20221214123512.189688-3-s.hauer@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: let truncate take a loff_t argumentSascha Hauer2019-02-061-1/+1
| | | | | | | loff_t is the correct type for file sizes. Use it to allow to truncate to sizes bigger than 32bit. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: Drop trivial .lseek() implementaitons in FS driversAndrey Smirnov2019-01-291-8/+0
| | | | | | | | | | | | | | | There are no FS drivers that do not implement .lseek callback in the codebase, so there doesn't seem to exist a use-case where lseek() would return -ENOSYS due to fsdrv->lseek being NULL. At the same time a large number of FS drivers implement only the most basic "always succeeds" custom .lseek() hook. Change the code of lseek() to treat absense of .lseek() to mean that no special actions needs to be taken by FS driver and seek is always successful and drop all of the trivial .lseek() implementations. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: Update FILE position in lseek()Andrey Smirnov2019-01-291-2/+1
| | | | | | | | | | Instead on relying on driver callbacks to update 'pos' in FILE, do it as a part of lseek() code. This allows us to drop a bit of repeating code as well as making lseek() implementation consistent with write() and read(). Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: Add RATP fs supportJan Luebbe2016-01-181-0/+476
This adds file transfer support over RATP. The host can export a directory using the bbremote tool which can then be mounted under barebox as a filesystem. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Tested-by: Andrey Smirnov <andrew.smirnov@gmail.com>