diff options
author | Ahmad Fatoum <a.fatoum@pengutronix.de> | 2021-02-16 21:02:05 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2021-02-18 09:23:42 +0100 |
commit | 5504426f88f331f02c81a517a27b7618bbab2761 (patch) | |
tree | 2a88638a907bcbccf79997aa19e78461870f3f93 /fs/ext4/ext_barebox.c | |
parent | 45b31c4a25e140cf6c20cd1430b776d5ec26391e (diff) | |
download | barebox-5504426f88f331f02c81a517a27b7618bbab2761.tar.gz barebox-5504426f88f331f02c81a517a27b7618bbab2761.tar.xz |
fs: ext4: use sector_t and loff_t where appropriate
While the block API now supports 64-bit LBAs, file systems like ext4
still use 31- and 32-bit integers at a couple of places. Fix them up.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'fs/ext4/ext_barebox.c')
-rw-r--r-- | fs/ext4/ext_barebox.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ext4/ext_barebox.c b/fs/ext4/ext_barebox.c index 353ab44b29..a68a783e1c 100644 --- a/fs/ext4/ext_barebox.c +++ b/fs/ext4/ext_barebox.c @@ -27,15 +27,15 @@ #include <fcntl.h> #include "ext4_common.h" -int ext4fs_devread(struct ext_filesystem *fs, int __sector, int byte_offset, - int byte_len, char *buf) +ssize_t ext4fs_devread(struct ext_filesystem *fs, sector_t __sector, int byte_offset, + size_t byte_len, char *buf) { ssize_t size; uint64_t sector = __sector; size = cdev_read(fs->cdev, buf, byte_len, sector * SECTOR_SIZE + byte_offset, 0); if (size < 0) { - dev_err(fs->dev, "read error at sector %d: %s\n", __sector, + dev_err(fs->dev, "read error at sector %llu: %s\n", __sector, strerror(-size)); return size; } |