mirror-linux/fs/fuse
Arnd Bergmann b29a7a8eee fs: fuse: fix max() of incompatible types
The 'max()' value of a 'long long' and an 'unsigned int' is problematic
if the former is negative:

In function 'fuse_wr_pages',
    inlined from 'fuse_perform_write' at fs/fuse/file.c:1347:27:
include/linux/compiler_types.h:652:45: error: call to '__compiletime_assert_390' declared with attribute error: min(((pos + len - 1) >> 12) - (pos >> 12) + 1, max_pages) signedness error
  652 |         _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
      |                                             ^

Use a temporary variable to make it clearer what is going on here.

Fixes: 0f5bb0cfb0 ("fs: use min() or umin() instead of min_t()")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2026-02-09 15:19:43 -08:00
..
Kconfig fuse: fix references to fuse.rst -> fuse/fuse.rst 2025-09-02 11:14:15 +02:00
Makefile fuse: move CREATE_TRACE_POINTS to a separate file 2025-09-25 16:22:18 +02:00
acl.c posix_acl: make posix_acl_to_xattr() alloc the buffer 2026-01-16 10:51:12 +01:00
backing.c fuse: move the backing file idr and code into a new source file 2025-09-25 16:06:02 +02:00
control.c convert fuse_ctl 2025-11-16 01:35:03 -05:00
cuse.c
dax.c
dev.c fs: use min() or umin() instead of min_t() 2025-12-15 14:33:37 +01:00
dev_uring.c fuse update for 6.19 2025-12-05 15:25:13 -08:00
dev_uring_i.h
dir.c vfs-7.0-rc1.leases 2026-02-09 11:59:07 -08:00
file.c fs: fuse: fix max() of incompatible types 2026-02-09 15:19:43 -08:00
fuse_dev_i.h fuse: missing copy_finish in fuse-over-io-uring argument copies 2025-11-12 11:45:03 +01:00
fuse_i.h fuse update for 6.19 2025-12-05 15:25:13 -08:00
fuse_trace.h
inode.c fuse update for 6.19 2025-12-05 15:25:13 -08:00
ioctl.c Revert "fs: make vfs_fileattr_[get|set] return -EOPNOTSUPP" 2025-10-10 13:44:03 +02:00
iomode.c
passthrough.c fuse: move the backing file idr and code into a new source file 2025-09-25 16:06:02 +02:00
readdir.c
sysctl.c
trace.c fuse: move CREATE_TRACE_POINTS to a separate file 2025-09-25 16:22:18 +02:00
virtio_fs.c virtio-fs: fix incorrect check for fsvq->kobj 2025-11-05 14:00:16 +01:00
xattr.c