mirror-linux/fs/nilfs2
Jeff Layton 0b2600f81c
treewide: change inode->i_ino from unsigned long to u64
On 32-bit architectures, unsigned long is only 32 bits wide, which
causes 64-bit inode numbers to be silently truncated. Several
filesystems (NFS, XFS, BTRFS, etc.) can generate inode numbers that
exceed 32 bits, and this truncation can lead to inode number collisions
and other subtle bugs on 32-bit systems.

Change the type of inode->i_ino from unsigned long to u64 to ensure that
inode numbers are always represented as 64-bit values regardless of
architecture. Update all format specifiers treewide from %lu/%lx to
%llu/%llx to match the new type, along with corresponding local variable
types.

This is the bulk treewide conversion. Earlier patches in this series
handled trace events separately to allow trace field reordering for
better struct packing on 32-bit.

Signed-off-by: Jeff Layton <jlayton@kernel.org>
Link: https://patch.msgid.link/20260304-iino-u64-v3-12-2257ad83d372@kernel.org
Acked-by: Damien Le Moal <dlemoal@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Jan Kara <jack@suse.cz>
Reviewed-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
2026-03-06 14:31:28 +01:00
..
Kconfig fs: add CONFIG_BUFFER_HEAD 2023-08-02 09:13:09 -06:00
Makefile
alloc.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
alloc.h nilfs2: add missing return value kernel-doc descriptions 2025-01-24 22:47:25 -08:00
bmap.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
bmap.h nilfs2: use the BITS_PER_LONG macro 2024-09-01 20:43:42 -07:00
btnode.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
btnode.h fs/nilfs2: Use the enum req_op and blk_opf_t types 2022-07-14 12:14:33 -06:00
btree.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
btree.h nilfs2: add missing description of nilfs_btree_path structure 2024-09-01 20:43:36 -07:00
cpfile.c nilfs2: use the new ->i_state accessors 2025-10-20 20:22:27 +02:00
cpfile.h nilfs2: remove nilfs_cpfile_{get,put}_checkpoint() 2024-02-22 15:38:53 -08:00
dat.c nilfs2: use the new ->i_state accessors 2025-10-20 20:22:27 +02:00
dat.h
dir.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
direct.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
direct.h
export.h
file.c nilfs2: add setlease file operation 2026-01-12 10:55:46 +01:00
gcinode.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
ifile.c nilfs2: use the new ->i_state accessors 2025-10-20 20:22:27 +02:00
ifile.h nilfs2: convert inode file to be folio-based 2024-11-05 17:12:38 -08:00
inode.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
ioctl.c nilfs2: replace vmalloc + copy_from_user with vmemdup_user 2025-11-12 10:00:17 -08:00
mdt.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
mdt.h nilfs2: fix lockdep warnings during disk space reclamation 2022-04-01 11:46:09 -07:00
namei.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
nilfs.h fs: inline current_umask() and move it to fs_struct.h 2025-11-05 22:51:23 +01:00
page.c mm: introduce memdesc_flags_t 2025-09-13 16:55:07 -07:00
page.h nilfs2: convert nilfs_page_count_clean_buffers() to take a folio 2024-11-05 17:12:39 -08:00
recovery.c treewide: Replace kmalloc with kmalloc_obj for non-scalar types 2026-02-21 01:02:28 -08:00
segbuf.c nilfs2: correct return value kernel-doc descriptions for the rest 2025-01-24 22:47:25 -08:00
segbuf.h
segment.c treewide: change inode->i_ino from unsigned long to u64 2026-03-06 14:31:28 +01:00
segment.h nilfs2: remove wbc->for_reclaim handling 2025-05-21 10:48:23 -07:00
sufile.c nilfs2: Fix potential block overflow that cause system hang 2025-12-22 15:45:29 -08:00
sufile.h nilfs2: add missing return value kernel-doc descriptions 2025-01-24 22:47:25 -08:00
super.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
sysfs.c nilfs2: fix CFI failure when accessing /sys/fs/nilfs2/features/* 2025-09-13 13:05:38 -07:00
sysfs.h nilfs2: fix CFI failure when accessing /sys/fs/nilfs2/features/* 2025-09-13 13:05:38 -07:00
the_nilfs.c Convert 'alloc_obj' family to use the new default GFP_KERNEL argument 2026-02-21 17:09:51 -08:00
the_nilfs.h nilfs2: eliminate the shared counter and spinlock for i_generation 2024-09-01 20:43:43 -07:00