vfs: change inode->i_ino from unsigned long to u64
Subsystems (69)
Jeff Layton
maintainercover vfs: change inode->i_ino from unsigned long to u64
Christian said [1] to "just do it" when I proposed this, so here we are!
For historical reasons, the inode->i_ino field is an unsigned long, which means that it's 32 bits on 32 bit architectures. This has caused a number of filesystems to implement hacks to hash a 64-bit identifier into a 32-bit field, and deprives us of a universal identifier field for an inode.
This patchset changes the inode->i_ino field from an unsigned long to a u64. This shouldn't make any material difference on 64-bit hosts, but 32-bit hosts will see struct inode grow by at least 4 bytes. This could have effects on slabcache sizes and field alignment.
The bulk of the changes are to format strings and tracepoints, since the kernel itself doesn't care that much about the i_ino field. The first patch changes some vfs function arguments, so check that one out carefully.
With this change, we may be able to shrink some inode structures. For instance, struct nfs_inode has a fileid field that holds the 64-bit inode number. With this set of changes, that field could be eliminated. I'd rather leave that sort of cleanups for later just to keep this simple.
Much of this set was generated by LLM, but I attributed it to myself since I consider this to be in the "menial tasks" category of LLM usage.
[1]: https://lore.kernel.org/linux-fsdevel/20260219-portrait-winkt-959070cee42f@brauner/
---
Jeff Layton (61):
vfs: widen inode hash/lookup functions to u64
vfs: change i_ino from unsigned long to u64
trace: update VFS-layer trace events for u64 i_ino
ext4: update for u64 i_ino
jbd2: update format strings for u64 i_ino
f2fs: update for u64 i_ino
lockd: update format strings for u64 i_ino
nfs: update for u64 i_ino
nfs: remove nfs_fattr_to_ino_t() and nfs_fileid_to_ino_t()
nfs: remove nfs_compat_user_ino64()
nfs: remove enable_ino64 module parameter
nfsd: update format strings for u64 i_ino
smb: store full 64-bit uniqueid in i_ino
smb: remove cifs_uniqueid_to_ino_t()
locks: update /proc/locks format for u64 i_ino
proc: update /proc/PID/maps for u64 i_ino
nilfs2: update for u64 i_ino
9p: update format strings for u64 i_ino
affs: update format strings for u64 i_ino
afs: update format strings for u64 i_ino
autofs: update format strings for u64 i_ino
befs: update format strings for u64 i_ino
bfs: update format strings for u64 i_ino
cachefiles: update format strings for u64 i_ino
ceph: update format strings for u64 i_ino
coda: update format strings for u64 i_ino
cramfs: update format strings for u64 i_ino
ecryptfs: update format strings for u64 i_ino
efs: update format strings for u64 i_ino
exportfs: update format strings for u64 i_ino
ext2: update format strings for u64 i_ino
freevxfs: update format strings for u64 i_ino
hfs: update format strings for u64 i_ino
hfsplus: update format strings for u64 i_ino
hpfs: update format strings for u64 i_ino
isofs: update format strings for u64 i_ino
jffs2: update format strings for u64 i_ino
jfs: update format strings for u64 i_ino
minix: update format strings for u64 i_ino
nsfs: update format strings for u64 i_ino
ntfs3: update format strings for u64 i_ino
ocfs2: update format strings for u64 i_ino
orangefs: update format strings for u64 i_ino
overlayfs: update format strings for u64 i_ino
qnx4: update format strings for u64 i_ino
qnx6: update format strings for u64 i_ino
ubifs: update format strings for u64 i_ino
udf: update format strings for u64 i_ino
ufs: update format strings for u64 i_ino
zonefs: update format strings for u64 i_ino
security: update audit format strings for u64 i_ino drm/amdgpu: update for u64 i_ino
fsnotify: update fdinfo format strings for u64 i_ino
net: update socket dname format for u64 i_ino
uprobes: update format strings for u64 i_ino
dma-buf: update format string for u64 i_ino
fscrypt: update format strings for u64 i_ino
fsverity: update format string for u64 i_ino
iomap: update format string for u64 i_ino
net: update legacy protocol format strings for u64 i_ino
vfs: update core format strings for u64 i_ino
drivers/dma-buf/dma-buf.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 4 +- fs/9p/vfs_addr.c | 4 +- fs/9p/vfs_inode.c | 6 +- fs/9p/vfs_inode_dotl.c | 6 +- fs/affs/amigaffs.c | 8 +- fs/affs/bitmap.c | 2 +- fs/affs/dir.c | 2 +- fs/affs/file.c | 20 +- fs/affs/inode.c | 12 +- fs/affs/namei.c | 14 +- fs/affs/symlink.c | 2 +- fs/afs/dir.c | 10 +- fs/afs/dir_search.c | 2 +- fs/afs/dynroot.c | 2 +- fs/afs/inode.c | 2 +- fs/autofs/inode.c | 2 +- fs/befs/linuxvfs.c | 28 +- fs/bfs/dir.c | 4 +- fs/cachefiles/io.c | 6 +- fs/cachefiles/namei.c | 12 +- fs/cachefiles/xattr.c | 2 +- fs/ceph/crypto.c | 4 +- fs/coda/dir.c | 2 +- fs/coda/inode.c | 2 +- fs/cramfs/inode.c | 2 +- fs/crypto/crypto.c | 2 +- fs/crypto/hooks.c | 2 +- fs/crypto/keysetup.c | 2 +- fs/dcache.c | 4 +- fs/ecryptfs/crypto.c | 6 +- fs/ecryptfs/file.c | 2 +- fs/efs/inode.c | 6 +- fs/eventpoll.c | 2 +- fs/exportfs/expfs.c | 4 +- fs/ext2/dir.c | 10 +- fs/ext2/ialloc.c | 9 +- fs/ext2/inode.c | 2 +- fs/ext2/xattr.c | 14 +- fs/ext4/dir.c | 2 +- fs/ext4/ext4.h | 4 +- fs/ext4/extents.c | 8 +- fs/ext4/extents_status.c | 28 +- fs/ext4/fast_commit.c | 8 +- fs/ext4/ialloc.c | 10 +- fs/ext4/indirect.c | 2 +- fs/ext4/inline.c | 14 +- fs/ext4/inode.c | 22 +- fs/ext4/ioctl.c | 4 +- fs/ext4/mballoc.c | 6 +- fs/ext4/migrate.c | 2 +- fs/ext4/move_extent.c | 20 +- fs/ext4/namei.c | 10 +- fs/ext4/orphan.c | 16 +- fs/ext4/page-io.c | 10 +- fs/ext4/super.c | 22 +- fs/ext4/xattr.c | 10 +- fs/f2fs/compress.c | 4 +- fs/f2fs/dir.c | 2 +- fs/f2fs/extent_cache.c | 8 +- fs/f2fs/f2fs.h | 6 +- fs/f2fs/file.c | 12 +- fs/f2fs/gc.c | 2 +- fs/f2fs/inline.c | 4 +- fs/f2fs/inode.c | 48 ++-- fs/f2fs/namei.c | 8 +- fs/f2fs/node.c | 12 +- fs/f2fs/recovery.c | 10 +- fs/f2fs/xattr.c | 10 +- fs/freevxfs/vxfs_bmap.c | 4 +- fs/fserror.c | 2 +- fs/hfs/catalog.c | 2 +- fs/hfs/extent.c | 4 +- fs/hfs/inode.c | 4 +- fs/hfsplus/attributes.c | 10 +- fs/hfsplus/catalog.c | 2 +- fs/hfsplus/dir.c | 6 +- fs/hfsplus/extents.c | 6 +- fs/hfsplus/inode.c | 8 +- fs/hfsplus/super.c | 6 +- fs/hfsplus/xattr.c | 10 +- fs/hpfs/dir.c | 4 +- fs/hpfs/dnode.c | 4 +- fs/hpfs/ea.c | 4 +- fs/hpfs/inode.c | 4 +- fs/inode.c | 46 ++-- fs/iomap/ioend.c | 2 +- fs/isofs/compress.c | 2 +- fs/isofs/dir.c | 2 +- fs/isofs/inode.c | 6 +- fs/isofs/namei.c | 2 +- fs/jbd2/journal.c | 4 +- fs/jbd2/transaction.c | 2 +- fs/jffs2/dir.c | 4 +- fs/jffs2/file.c | 4 +- fs/jffs2/fs.c | 18 +- fs/jfs/inode.c | 2 +- fs/jfs/jfs_imap.c | 2 +- fs/jfs/jfs_metapage.c | 2 +- fs/lockd/svclock.c | 8 +- fs/lockd/svcsubs.c | 2 +- fs/locks.c | 6 +- fs/minix/inode.c | 10 +- fs/nfs/dir.c | 22 +- fs/nfs/file.c | 8 +- fs/nfs/filelayout/filelayout.c | 8 +- fs/nfs/flexfilelayout/flexfilelayout.c | 8 +- fs/nfs/inode.c | 54 +--- fs/nfs/nfs4proc.c | 4 +- fs/nfs/pnfs.c | 12 +- fs/nfsd/export.c | 2 +- fs/nfsd/nfs4state.c | 4 +- fs/nfsd/nfsfh.c | 4 +- fs/nfsd/vfs.c | 2 +- fs/nilfs2/alloc.c | 10 +- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/btnode.c | 2 +- fs/nilfs2/btree.c | 12 +- fs/nilfs2/dir.c | 12 +- fs/nilfs2/direct.c | 4 +- fs/nilfs2/gcinode.c | 2 +- fs/nilfs2/inode.c | 8 +- fs/nilfs2/mdt.c | 2 +- fs/nilfs2/namei.c | 2 +- fs/nilfs2/segment.c | 2 +- fs/notify/fdinfo.c | 4 +- fs/nsfs.c | 4 +- fs/ntfs3/super.c | 2 +- fs/ocfs2/alloc.c | 2 +- fs/ocfs2/aops.c | 4 +- fs/ocfs2/dir.c | 8 +- fs/ocfs2/dlmfs/dlmfs.c | 10 +- fs/ocfs2/extent_map.c | 12 +- fs/ocfs2/inode.c | 2 +- fs/ocfs2/quota_local.c | 2 +- fs/ocfs2/refcounttree.c | 10 +- fs/ocfs2/xattr.c | 4 +- fs/orangefs/inode.c | 2 +- fs/overlayfs/export.c | 2 +- fs/overlayfs/namei.c | 4 +- fs/overlayfs/util.c | 2 +- fs/pipe.c | 2 +- fs/proc/fd.c | 2 +- fs/proc/task_mmu.c | 4 +- fs/qnx4/inode.c | 4 +- fs/qnx6/inode.c | 2 +- fs/smb/client/cifsfs.h | 17 -- fs/smb/client/inode.c | 6 +- fs/smb/client/readdir.c | 2 +- fs/ubifs/debug.c | 8 +- fs/ubifs/dir.c | 28 +- fs/ubifs/file.c | 28 +- fs/ubifs/journal.c | 6 +- fs/ubifs/super.c | 16 +- fs/ubifs/tnc.c | 4 +- fs/ubifs/xattr.c | 14 +- fs/udf/directory.c | 18 +- fs/udf/file.c | 2 +- fs/udf/inode.c | 12 +- fs/udf/namei.c | 8 +- fs/udf/super.c | 2 +- fs/ufs/balloc.c | 6 +- fs/ufs/dir.c | 10 +- fs/ufs/ialloc.c | 6 +- fs/ufs/inode.c | 18 +- fs/ufs/ufs_fs.h | 6 +- fs/ufs/util.c | 2 +- fs/verity/init.c | 2 +- fs/zonefs/super.c | 8 +- include/linux/fs.h | 28 +- include/linux/nfs_fs.h | 10 - include/trace/events/cachefiles.h | 18 +- include/trace/events/ext4.h | 427 +++++++++++++++-------------- include/trace/events/f2fs.h | 172 ++++++------ include/trace/events/filelock.h | 16 +- include/trace/events/filemap.h | 20 +- include/trace/events/fs_dax.h | 20 +- include/trace/events/fsverity.h | 30 +- include/trace/events/hugetlbfs.h | 28 +- include/trace/events/netfs.h | 4 +- include/trace/events/nilfs2.h | 12 +- include/trace/events/readahead.h | 12 +- include/trace/events/timestamp.h | 12 +- include/trace/events/writeback.h | 148 +++++----- kernel/events/uprobes.c | 4 +- net/netrom/af_netrom.c | 4 +- net/rose/af_rose.c | 4 +- net/socket.c | 2 +- net/x25/x25_proc.c | 4 +- security/apparmor/apparmorfs.c | 4 +- security/integrity/integrity_audit.c | 2 +- security/ipe/audit.c | 2 +- security/lsm_audit.c | 10 +- security/selinux/hooks.c | 4 +- security/smack/smack_lsm.c | 12 +- 195 files changed, 1101 insertions(+), 1166 deletions(-)
---
base-commit: 2bf35e96cf6c6c3a290b69b777d34be15888e364
change-id: 20260224-iino-u64-b44a3a72543c
Best regards,
Signature · 1 line
Jeff Layton <[email protected]>
Jeff Layton
maintainerPATCH 1/61 vfs: widen inode hash/lookup functions to u64
Change the inode hash/lookup VFS API functions to accept u64 parameters instead of unsigned long for inode numbers and hash values. This is preparation for widening i_ino itself to u64, which will allow filesystems to store full 64-bit inode numbers on 32-bit architectures.
Since unsigned long implicitly widens to u64 on all architectures, this change is backward-compatible with all existing callers.
Functions updated:
- hash(), find_inode_fast(), find_inode_by_ino_rcu(), test_inode_iunique()
- __insert_inode_hash(), iget_locked(), iget5_locked(), iget5_locked_rcu()
- ilookup(), ilookup5(), ilookup5_nowait()
- find_inode_nowait(), find_inode_rcu()
- inode_insert5(), insert_inode_locked4()
- insert_inode_locked() (local variable)
- dump_mapping() (local variable and format string)
--- fs/inode.c | 46 +++++++++++++++++++++++----------------------- include/linux/fs.h | 26 +++++++++++++------------- 2 files changed, 36 insertions(+), 36 deletions(-)
fs/inode.c +23 -23
@@ -672,7 +672,7 @@ static inline void inode_sb_list_del(struct inode *inode) } } -static unsigned long hash (struct super_block *sb,unsigned long hashval) +static unsigned long hash (struct super_block *sb,u64 hashval) {unsigned long tmp;
@@ -685,12 +685,12 @@ static unsigned long hash(struct super_block *sb, unsigned long hashval)/** * __insert_inode_hash - hash an inode * @inode: unhashed inode -* @hashval: unsigned long value used to locate this object in the +* @hashval: u64 value used to locate this object in the * inode_hashtable. * * Add an inode to the inode hash for this superblock. */ -void __insert_inode_hash (struct inode *inode,unsigned long hashval) +void __insert_inode_hash (struct inode *inode,u64 hashval) {struct hlist_head *b = inode_hashtable +hash (inode->i_sb, hashval);
@@ -726,7 +726,7 @@ void dump_mapping(const struct address_space *mapping)struct dentry *dentry_ptr;struct dentry dentry;char fname[64 ] = {}; -unsigned long ino; +u64 ino;/* * If mapping is an invalid pointer, we don't want to crash
@@ -750,14 +750,14 @@ void dump_mapping(const struct address_space *mapping) }if (!dentry_first) { -pr_warn ("aops:%ps ino:%lx\n" , a_ops, ino); +pr_warn ("aops:%ps ino:%llx\n" , a_ops, ino);return ; } dentry_ptr = container_of(dentry_first, struct dentry, d_u.d_alias);if (get_kernel_nofault (dentry, dentry_ptr) || !dentry.d_parent || !dentry.d_name.name) { -pr_warn ("aops:%ps ino:%lx invalid dentry:%px\n" , +pr_warn ("aops:%ps ino:%llx invalid dentry:%px\n" , a_ops, ino, dentry_ptr);return ; }
@@ -768,7 +768,7 @@ void dump_mapping(const struct address_space *mapping)* Even if strncpy_from_kernel_nofault() succeeded, * the fname could be unreliable */ -pr_warn ("aops:%ps ino:%lx dentry name(?):\"%s\"\n" , +pr_warn ("aops:%ps ino:%llx dentry name(?):\"%s\"\n" , a_ops, ino, fname); }
@@ -1087,7 +1087,7 @@ static struct inode *find_inode(struct super_block *sb,* iget_locked for details. */ static struct inode *find_inode_fast (struct super_block *sb, -struct hlist_head *head,unsigned long ino, +struct hlist_head *head,u64 ino,bool hash_locked,bool *isnew) {struct inode *inode =NULL ;
@@ -1301,7 +1301,7 @@ EXPORT_SYMBOL(unlock_two_nondirectories);* Note that both @test and @set are called with the inode_hash_lock held, so * they can't sleep. */ -struct inode *inode_insert5 (struct inode *inode,unsigned long hashval, +struct inode *inode_insert5 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data) {
@@ -1378,7 +1378,7 @@ EXPORT_SYMBOL(inode_insert5);* Note that both @test and @set are called with the inode_hash_lock held, so * they can't sleep. */ -struct inode *iget5_locked (struct super_block *sb,unsigned long hashval, +struct inode *iget5_locked (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data) {
@@ -1408,7 +1408,7 @@ EXPORT_SYMBOL(iget5_locked);* This is equivalent to iget5_locked, except the @test callback must * tolerate the inode not being stable, including being mid-teardown. */ -struct inode *iget5_locked_rcu (struct super_block *sb,unsigned long hashval, +struct inode *iget5_locked_rcu (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data) {
@@ -1455,7 +1455,7 @@ EXPORT_SYMBOL_GPL(iget5_locked_rcu);* hashed, and with the I_NEW flag set. The file system gets to fill it in * before unlocking it via unlock_new_inode(). */ -struct inode *iget_locked (struct super_block *sb,unsigned long ino) +struct inode *iget_locked (struct super_block *sb,u64 ino) {struct hlist_head *head = inode_hashtable +hash (sb, ino);struct inode *inode;
@@ -1527,7 +1527,7 @@ EXPORT_SYMBOL(iget_locked);* * Returns 1 if the inode number is unique, 0 if it is not. */ -static int test_inode_iunique (struct super_block *sb,unsigned long ino) +static int test_inode_iunique (struct super_block *sb,u64 ino) {struct hlist_head *b = inode_hashtable +hash (sb, ino);struct inode *inode;
@@ -1616,7 +1616,7 @@ EXPORT_SYMBOL(igrab);* * Note2: @test is called with the inode_hash_lock held, so can't sleep. */ -struct inode *ilookup5_nowait (struct super_block *sb,unsigned long hashval, +struct inode *ilookup5_nowait (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data,bool *isnew) {struct hlist_head *head = inode_hashtable +hash (sb, hashval);
@@ -1647,7 +1647,7 @@ EXPORT_SYMBOL(ilookup5_nowait);* * Note: @test is called with the inode_hash_lock held, so can't sleep. */ -struct inode *ilookup5 (struct super_block *sb,unsigned long hashval, +struct inode *ilookup5 (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct inode *inode;
@@ -1677,7 +1677,7 @@ EXPORT_SYMBOL(ilookup5);* Search for the inode @ino in the inode cache, and if the inode is in the * cache, the inode is returned with an incremented reference count. */ -struct inode *ilookup (struct super_block *sb,unsigned long ino) +struct inode *ilookup (struct super_block *sb,u64 ino) {struct hlist_head *head = inode_hashtable +hash (sb, ino);struct inode *inode;
@@ -1726,8 +1726,8 @@ EXPORT_SYMBOL(ilookup);* very carefully implemented. */ struct inode *find_inode_nowait (struct super_block *sb, -unsigned long hashval, -int (*match)(struct inode *,unsigned long , +u64 hashval, +int (*match)(struct inode *,u64 ,void *),void *data) {
@@ -1773,7 +1773,7 @@ EXPORT_SYMBOL(find_inode_nowait);* * The caller must hold the RCU read lock. */ -struct inode *find_inode_rcu (struct super_block *sb,unsigned long hashval, +struct inode *find_inode_rcu (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct hlist_head *head = inode_hashtable +hash (sb, hashval);
@@ -1812,7 +1812,7 @@ EXPORT_SYMBOL(find_inode_rcu);* The caller must hold the RCU read lock. */ struct inode *find_inode_by_ino_rcu (struct super_block *sb, -unsigned long ino) +u64 ino) {struct hlist_head *head = inode_hashtable +hash (sb, ino);struct inode *inode;
@@ -1833,7 +1833,7 @@ EXPORT_SYMBOL(find_inode_by_ino_rcu);int insert_inode_locked (struct inode *inode) {struct super_block *sb = inode->i_sb; -ino_t ino = inode->i_ino; +u64 ino = inode->i_ino;struct hlist_head *head = inode_hashtable +hash (sb, ino);bool isnew;
@@ -1884,7 +1884,7 @@ int insert_inode_locked(struct inode *inode) }EXPORT_SYMBOL (insert_inode_locked); -int insert_inode_locked4 (struct inode *inode,unsigned long hashval, +int insert_inode_locked4 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct inode *old;
@@ -2642,7 +2642,7 @@ void init_special_inode(struct inode *inode, umode_t mode, dev_t rdev)break ;default :printk (KERN_DEBUG "init_special_inode: bogus i_mode (%o) for" -" inode %s:%lu\n" , mode, inode->i_sb->s_id, +" inode %s:%llu\n" , mode, inode->i_sb->s_id, inode->i_ino);break ; }
include/linux/fs.h +13 -13
@@ -2935,32 +2935,32 @@ static inline int inode_generic_drop(struct inode *inode)extern void d_mark_dontcache (struct inode *inode);extern struct inode *ilookup5_nowait (struct super_block *sb, -unsigned long hashval,int (*test)(struct inode *,void *), +u64 hashval,int (*test)(struct inode *,void *),void *data,bool *isnew); -extern struct inode *ilookup5 (struct super_block *sb,unsigned long hashval, +extern struct inode *ilookup5 (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data); -extern struct inode *ilookup (struct super_block *sb,unsigned long ino); +extern struct inode *ilookup (struct super_block *sb,u64 ino); -extern struct inode *inode_insert5 (struct inode *inode,unsigned long hashval, +extern struct inode *inode_insert5 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data); -struct inode *iget5_locked (struct super_block *,unsigned long , +struct inode *iget5_locked (struct super_block *,u64 ,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *); -struct inode *iget5_locked_rcu (struct super_block *,unsigned long , +struct inode *iget5_locked_rcu (struct super_block *,u64 ,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *); -extern struct inode *iget_locked (struct super_block *,unsigned long ); +extern struct inode *iget_locked (struct super_block *,u64 );extern struct inode *find_inode_nowait (struct super_block *, -unsigned long , +u64 ,int (*match)(struct inode *, -unsigned long ,void *), +u64 ,void *),void *data); -extern struct inode *find_inode_rcu (struct super_block *,unsigned long , +extern struct inode *find_inode_rcu (struct super_block *,u64 ,int (*)(struct inode *,void *),void *); -extern struct inode *find_inode_by_ino_rcu (struct super_block *,unsigned long ); -extern int insert_inode_locked4 (struct inode *,unsigned long ,int (*test)(struct inode *,void *),void *); +extern struct inode *find_inode_by_ino_rcu (struct super_block *,u64 ); +extern int insert_inode_locked4 (struct inode *,u64 ,int (*test)(struct inode *,void *),void *);extern int insert_inode_locked (struct inode *);#ifdef CONFIG_DEBUG_LOCK_ALLOC extern void lockdep_annotate_inode_mutex_key (struct inode *inode);
@@ -3015,7 +3015,7 @@ int setattr_should_drop_sgid(struct mnt_idmap *idmap,*/ #define alloc_inode_sb (_sb, _cache, _gfp) kmem_cache_alloc_lru(_cache, &_sb->s_inode_lru, _gfp) -extern void __insert_inode_hash (struct inode *,unsigned long hashval); +extern void __insert_inode_hash (struct inode *,u64 hashval);static inline void insert_inode_hash (struct inode *inode) {__insert_inode_hash (inode, inode->i_ino);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 2/61 vfs: change i_ino from unsigned long to u64
In reply to Jeff LaytonChange the type of i_ino in struct inode from unsigned long to u64.
On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens i_ino from 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.
The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (__u64). The existing overflow checks in cp_new_stat(), cp_old_stat(), and cp_compat_stat() handle narrowing to 32-bit st_ino with -EOVERFLOW, so userspace ABI is preserved.
struct inode will grow by 4 bytes on 32-bit architectures.
--- include/linux/fs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/fs.h +1 -1
@@ -783,7 +783,7 @@ struct inode {#endif /* Stat data, not accessed from path walking */ -unsigned long i_ino; +u64 i_ino;/* * Filesystems may only read i_nlink directly. They shall use the * following functions for modification:
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 3/61 trace: update VFS-layer trace events for u64 i_ino
In reply to Jeff LaytonUpdate trace event definitions in VFS-layer trace headers to use u64 instead of ino_t/unsigned long for inode number fields, and change format strings from %lu/%lx to %llu/%llx to match.
This is needed because i_ino is now u64. Changing trace event field types changes the binary trace format, but the self-describing format metadata handles this transparently for modern trace-cmd and perf.
Files updated:
- cachefiles.h, filelock.h, filemap.h, fs_dax.h, fsverity.h, hugetlbfs.h, netfs.h, readahead.h, timestamp.h, writeback.h
--- include/trace/events/cachefiles.h | 18 ++--- include/trace/events/filelock.h | 16 ++--- include/trace/events/filemap.h | 20 +++--- include/trace/events/fs_dax.h | 20 +++--- include/trace/events/fsverity.h | 30 ++++---- include/trace/events/hugetlbfs.h | 28 ++++---- include/trace/events/netfs.h | 4 +- include/trace/events/readahead.h | 12 ++-- include/trace/events/timestamp.h | 12 ++-- include/trace/events/writeback.h | 148 +++++++++++++++++++------------------- 10 files changed, 154 insertions(+), 154 deletions(-)
include/trace/events/cachefiles.h +9 -9
@@ -251,8 +251,8 @@ TRACE_EVENT(cachefiles_lookup,TP_STRUCT__entry (__field (unsigned int ,obj )__field (short, error) - __field(unsigned long, dino) - __field(unsigned long, ino) +__field (u64, dino) +__field (u64, ino) ), TP_fast_assign(
@@ -263,7 +263,7 @@ TRACE_EVENT(cachefiles_lookup, __entry->error =IS_ERR (de) ?PTR_ERR (de) :0 ; ), -TP_printk ("o=%08x dB=%lx B=%lx e=%d" , +TP_printk ("o=%08x dB=%llx B=%llx e=%d" , __entry->obj, __entry->dino, __entry->ino, __entry->error) );
@@ -579,7 +579,7 @@ TRACE_EVENT(cachefiles_mark_active,/* Note that obj may be NULL */ TP_STRUCT__entry (__field (unsigned int ,obj ) -__field (ino_t, inode) +__field (u64, inode) ), TP_fast_assign(
@@ -587,7 +587,7 @@ TRACE_EVENT(cachefiles_mark_active, __entry->inode = inode->i_ino; ), -TP_printk ("o=%08x B=%lx" , +TP_printk ("o=%08x B=%llx" , __entry->obj, __entry->inode) );
@@ -600,7 +600,7 @@ TRACE_EVENT(cachefiles_mark_failed,/* Note that obj may be NULL */ TP_STRUCT__entry (__field (unsigned int ,obj ) -__field (ino_t, inode) +__field (u64, inode) ), TP_fast_assign(
@@ -608,7 +608,7 @@ TRACE_EVENT(cachefiles_mark_failed, __entry->inode = inode->i_ino; ), -TP_printk ("o=%08x B=%lx" , +TP_printk ("o=%08x B=%llx" , __entry->obj, __entry->inode) );
@@ -621,7 +621,7 @@ TRACE_EVENT(cachefiles_mark_inactive,/* Note that obj may be NULL */ TP_STRUCT__entry (__field (unsigned int ,obj ) -__field (ino_t, inode) +__field (u64, inode) ), TP_fast_assign(
@@ -629,7 +629,7 @@ TRACE_EVENT(cachefiles_mark_inactive, __entry->inode = inode->i_ino; ), -TP_printk ("o=%08x B=%lx" , +TP_printk ("o=%08x B=%llx" , __entry->obj, __entry->inode) );
include/trace/events/filelock.h +8 -8
@@ -42,7 +42,7 @@ TRACE_EVENT(locks_get_lock_context, TP_ARGS(inode, type, ctx),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev) __field(unsigned char, type) __field(struct file_lock_context *, ctx)
@@ -55,7 +55,7 @@ TRACE_EVENT(locks_get_lock_context, __entry->ctx = ctx; ), -TP_printk ("dev=0x%x:0x%x ino=0x%lx type=%s ctx=%p" , +TP_printk ("dev=0x%x:0x%x ino=0x%llx type=%s ctx=%p" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino,show_fl_type (__entry->type), __entry->ctx) );
@@ -67,7 +67,7 @@ DECLARE_EVENT_CLASS(filelock_lock,TP_STRUCT__entry (__field (struct file_lock *,fl ) - __field(unsigned long, i_ino) +__field (u64, i_ino)__field (dev_t, s_dev) __field(struct file_lock_core *, blocker) __field(fl_owner_t, owner)
@@ -93,7 +93,7 @@ DECLARE_EVENT_CLASS(filelock_lock, __entry->ret = ret; ), - TP_printk("fl=%p dev=0x%x:0x%x ino=0x%lx fl_blocker=%p fl_owner=%p fl_pid=%u fl_flags=%s fl_type=%s fl_start=%lld fl_end=%lld ret=%d", + TP_printk("fl=%p dev=0x%x:0x%x ino=0x%llx fl_blocker=%p fl_owner=%p fl_pid=%u fl_flags=%s fl_type=%s fl_start=%lld fl_end=%lld ret=%d", __entry->fl, MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->blocker, __entry->owner, __entry->pid, show_fl_flags(__entry->flags),
@@ -124,7 +124,7 @@ DECLARE_EVENT_CLASS(filelock_lease,TP_STRUCT__entry (__field (struct file_lease *,fl ) - __field(unsigned long, i_ino) +__field (u64, i_ino)__field (dev_t, s_dev) __field(struct file_lock_core *, blocker) __field(fl_owner_t, owner)
@@ -146,7 +146,7 @@ DECLARE_EVENT_CLASS(filelock_lease, __entry->downgrade_time = fl ? fl->fl_downgrade_time :0 ; ), - TP_printk("fl=%p dev=0x%x:0x%x ino=0x%lx fl_blocker=%p fl_owner=%p fl_flags=%s fl_type=%s fl_break_time=%lu fl_downgrade_time=%lu", + TP_printk("fl=%p dev=0x%x:0x%x ino=0x%llx fl_blocker=%p fl_owner=%p fl_flags=%s fl_type=%s fl_break_time=%lu fl_downgrade_time=%lu", __entry->fl, MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->blocker, __entry->owner, show_fl_flags(__entry->flags),
@@ -175,7 +175,7 @@ TRACE_EVENT(generic_add_lease,TP_ARGS (inode, fl),TP_STRUCT__entry ( - __field(unsigned long, i_ino) + __field(u64, i_ino) __field(int, wcount) __field(int, rcount) __field(int, icount)
@@ -196,7 +196,7 @@ TRACE_EVENT(generic_add_lease, __entry->type = fl->c.flc_type; ), - TP_printk("dev=0x%x:0x%x ino=0x%lx wcount=%d rcount=%d icount=%d fl_owner=%p fl_flags=%s fl_type=%s", + TP_printk("dev=0x%x:0x%x ino=0x%llx wcount=%d rcount=%d icount=%d fl_owner=%p fl_flags=%s fl_type=%s", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->wcount, __entry->rcount, __entry->icount, __entry->owner,
include/trace/events/filemap.h +10 -10
@@ -21,7 +21,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache,TP_STRUCT__entry (__field (unsigned long ,pfn ) - __field(unsigned long, i_ino) +__field (u64, i_ino) __field(unsigned long, index)__field (dev_t, s_dev) __field(unsigned char, order)
@@ -38,7 +38,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache, __entry->order =folio_order (folio); ), - TP_printk("dev %d:%d ino %lx pfn=0x%lx ofs=%lu order=%u", + TP_printk("dev %d:%d ino %llx pfn=0x%lx ofs=%lu order=%u", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->pfn,
@@ -67,7 +67,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache_range, TP_ARGS(mapping, index, last_index),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev) __field(unsigned long, index) __field(unsigned long, last_index)
@@ -85,7 +85,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache_range, ), TP_printk( - "dev=%d:%d ino=%lx ofs=%lld-%lld", + "dev=%d:%d ino=%llx ofs=%lld-%lld", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, ((loff_t)__entry->index) << PAGE_SHIFT,
@@ -117,7 +117,7 @@ TRACE_EVENT(mm_filemap_fault, TP_ARGS(mapping, index),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev) __field(unsigned long, index) ),
@@ -133,7 +133,7 @@ TRACE_EVENT(mm_filemap_fault, ),TP_printk ( -"dev=%d:%d ino=%lx ofs=%lld" , +"dev=%d:%d ino=%llx ofs=%lld" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, ((loff_t)__entry->index) << PAGE_SHIFT
@@ -146,7 +146,7 @@ TRACE_EVENT(filemap_set_wb_err, TP_ARGS(mapping, eseq),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev)__field (errseq_t, errseq) ),
@@ -160,7 +160,7 @@ TRACE_EVENT(filemap_set_wb_err, __entry->s_dev = mapping->host->i_rdev; ), -TP_printk ("dev=%d:%d ino=0x%lx errseq=0x%x" , +TP_printk ("dev=%d:%d ino=0x%llx errseq=0x%x" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, __entry->errseq) );
@@ -172,7 +172,7 @@ TRACE_EVENT(file_check_and_advance_wb_err,TP_STRUCT__entry (__field (struct file *,file ) - __field(unsigned long, i_ino) +__field (u64, i_ino)__field (dev_t, s_dev)__field (errseq_t, old) __field(errseq_t, new)
@@ -191,7 +191,7 @@ TRACE_EVENT(file_check_and_advance_wb_err, __entry->new = file->f_wb_err; ), -TP_printk ("file=%p dev=%d:%d ino=0x%lx old=0x%x new=0x%x" , +TP_printk ("file=%p dev=%d:%d ino=0x%llx old=0x%x new=0x%x" , __entry->file,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, __entry->old, __entry->new)
include/trace/events/fs_dax.h +10 -10
@@ -12,7 +12,7 @@ DECLARE_EVENT_CLASS(dax_pmd_fault_class, pgoff_t max_pgoff, int result),TP_ARGS (inode ,vmf ,max_pgoff ,result ),TP_STRUCT__entry ( - __field(unsigned long, ino) + __field(u64, ino)__field (unsigned long ,vm_start ) __field(unsigned long, vm_end) __field(vm_flags_t, vm_flags)
@@ -35,7 +35,7 @@ DECLARE_EVENT_CLASS(dax_pmd_fault_class, __entry->max_pgoff = max_pgoff; __entry->result = result; ), - TP_printk("dev %d:%d ino %#lx %s %s address %#lx vm_start " + TP_printk("dev %d:%d ino %#llx %s %s address %#lx vm_start " "%#lx vm_end %#lx pgoff %#lx max_pgoff %#lx %s", MAJOR(__entry->dev), MINOR(__entry->dev),
@@ -66,7 +66,7 @@ DECLARE_EVENT_CLASS(dax_pmd_load_hole_class, void *radix_entry),TP_ARGS (inode ,vmf ,zero_folio ,radix_entry ),TP_STRUCT__entry ( - __field(unsigned long, ino) + __field(u64, ino)__field (vm_flags_t ,vm_flags ) __field(unsigned long, address) __field(struct folio *, zero_folio)
@@ -81,7 +81,7 @@ DECLARE_EVENT_CLASS(dax_pmd_load_hole_class, __entry->zero_folio = zero_folio; __entry->radix_entry = radix_entry; ), - TP_printk("dev %d:%d ino %#lx %s address %#lx zero_folio %p " + TP_printk("dev %d:%d ino %#llx %s address %#lx zero_folio %p " "radix_entry %#lx", MAJOR(__entry->dev), MINOR(__entry->dev),
@@ -106,7 +106,7 @@ DECLARE_EVENT_CLASS(dax_pte_fault_class, TP_PROTO(struct inode *inode, struct vm_fault *vmf, int result), TP_ARGS(inode, vmf, result), TP_STRUCT__entry( - __field(unsigned long, ino) + __field(u64, ino) __field(vm_flags_t, vm_flags) __field(unsigned long, address) __field(pgoff_t, pgoff)
@@ -123,7 +123,7 @@ DECLARE_EVENT_CLASS(dax_pte_fault_class, __entry->pgoff = vmf->pgoff; __entry->result = result; ), - TP_printk("dev %d:%d ino %#lx %s %s address %#lx pgoff %#lx %s", + TP_printk("dev %d:%d ino %#llx %s %s address %#lx pgoff %#lx %s", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino,
@@ -150,7 +150,7 @@ DECLARE_EVENT_CLASS(dax_writeback_range_class, TP_PROTO(struct inode *inode, pgoff_t start_index, pgoff_t end_index), TP_ARGS(inode, start_index, end_index), TP_STRUCT__entry( - __field(unsigned long, ino) + __field(u64, ino) __field(pgoff_t, start_index) __field(pgoff_t, end_index) __field(dev_t, dev)
@@ -161,7 +161,7 @@ DECLARE_EVENT_CLASS(dax_writeback_range_class, __entry->start_index = start_index; __entry->end_index = end_index; ), - TP_printk("dev %d:%d ino %#lx pgoff %#lx-%#lx", + TP_printk("dev %d:%d ino %#llx pgoff %#lx-%#lx", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino,
@@ -182,7 +182,7 @@ TRACE_EVENT(dax_writeback_one, TP_PROTO(struct inode *inode, pgoff_t pgoff, pgoff_t pglen), TP_ARGS(inode, pgoff, pglen), TP_STRUCT__entry( - __field(unsigned long, ino) + __field(u64, ino) __field(pgoff_t, pgoff) __field(pgoff_t, pglen) __field(dev_t, dev)
@@ -193,7 +193,7 @@ TRACE_EVENT(dax_writeback_one, __entry->pgoff = pgoff; __entry->pglen = pglen; ), - TP_printk("dev %d:%d ino %#lx pgoff %#lx pglen %#lx", + TP_printk("dev %d:%d ino %#llx pgoff %#lx pglen %#lx", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino,
include/trace/events/fsverity.h +15 -15
@@ -16,7 +16,7 @@ TRACE_EVENT(fsverity_enable, const struct merkle_tree_params *params),TP_ARGS (inode ,params ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (u64 ,data_size )__field (u64, tree_size) __field(unsigned int, merkle_block)
@@ -29,8 +29,8 @@ TRACE_EVENT(fsverity_enable, __entry->merkle_block = params->block_size; __entry->num_levels = params->num_levels; ), - TP_printk("ino %lu data_size %llu tree_size %llu merkle_block %u levels %u", - (unsigned long) __entry->ino, + TP_printk("ino %llu data_size %llu tree_size %llu merkle_block %u levels %u", + __entry->ino, __entry->data_size, __entry->tree_size, __entry->merkle_block,
@@ -42,7 +42,7 @@ TRACE_EVENT(fsverity_tree_done, const struct merkle_tree_params *params),TP_ARGS (inode ,vi ,params ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (u64 ,data_size )__field (u64, tree_size) __field(unsigned int, merkle_block)
@@ -59,8 +59,8 @@ TRACE_EVENT(fsverity_tree_done,memcpy (__get_dynamic_array (root_hash), vi->root_hash,__get_dynamic_array_len (root_hash));memcpy (__get_dynamic_array (file_digest), vi->file_digest,__get_dynamic_array_len (file_digest)); ), - TP_printk("ino %lu data_size %llu tree_size %lld merkle_block %u levels %u root_hash %s digest %s", - (unsigned long) __entry->ino, + TP_printk("ino %llu data_size %llu tree_size %lld merkle_block %u levels %u root_hash %s digest %s", + __entry->ino, __entry->data_size, __entry->tree_size, __entry->merkle_block,
@@ -75,7 +75,7 @@ TRACE_EVENT(fsverity_verify_data_block, u64 data_pos),TP_ARGS (inode ,params ,data_pos ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (u64 ,data_pos ) __field(unsigned int, merkle_block) ),
@@ -84,8 +84,8 @@ TRACE_EVENT(fsverity_verify_data_block, __entry->data_pos = data_pos; __entry->merkle_block = params->block_size; ), -TP_printk ("ino %lu data_pos %llu merkle_block %u" , - (unsigned long ) __entry->ino, +TP_printk ("ino %llu data_pos %llu merkle_block %u" , + __entry->ino, __entry->data_pos, __entry->merkle_block) );
@@ -96,7 +96,7 @@ TRACE_EVENT(fsverity_merkle_hit, unsigned int hidx),TP_ARGS (inode ,data_pos ,hblock_idx ,level ,hidx ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (u64 ,data_pos ) __field(unsigned long, hblock_idx) __field(unsigned int, level)
@@ -109,8 +109,8 @@ TRACE_EVENT(fsverity_merkle_hit, __entry->level = level; __entry->hidx = hidx; ), - TP_printk("ino %lu data_pos %llu hblock_idx %lu level %u hidx %u", - (unsigned long) __entry->ino, + TP_printk("ino %llu data_pos %llu hblock_idx %lu level %u hidx %u", + __entry->ino, __entry->data_pos, __entry->hblock_idx, __entry->level,
@@ -122,7 +122,7 @@ TRACE_EVENT(fsverity_verify_merkle_block, unsigned int level, unsigned int hidx),TP_ARGS (inode ,hblock_idx ,level ,hidx ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (unsigned long ,hblock_idx ) __field(unsigned int, level) __field(unsigned int, hidx)
@@ -133,8 +133,8 @@ TRACE_EVENT(fsverity_verify_merkle_block, __entry->level = level; __entry->hidx = hidx; ), -TP_printk ("ino %lu hblock_idx %lu level %u hidx %u" , - (unsigned long ) __entry->ino, +TP_printk ("ino %llu hblock_idx %lu level %u hidx %u" , + __entry->ino, __entry->hblock_idx, __entry->level, __entry->hidx)
include/trace/events/hugetlbfs.h +14 -14
@@ -15,8 +15,8 @@ TRACE_EVENT(hugetlbfs_alloc_inode,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) -__field (ino_t, dir) +__field (u64, ino) +__field (u64, dir)__field (__u16, mode) ),
@@ -27,10 +27,10 @@ TRACE_EVENT(hugetlbfs_alloc_inode, __entry->mode = mode; ), -TP_printk ("dev %d,%d ino %lu dir %lu mode 0%o" , +TP_printk ("dev %d,%d ino %llu dir %llu mode 0%o" ,MAJOR (__entry->dev),MINOR (__entry->dev), - (unsigned long ) __entry->ino, - (unsigned long ) __entry->dir, __entry->mode) + __entry->ino, + __entry->dir, __entry->mode) ); DECLARE_EVENT_CLASS(hugetlbfs__inode,
@@ -41,7 +41,7 @@ DECLARE_EVENT_CLASS(hugetlbfs__inode,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) +__field (u64, ino)__field (__u16, mode)__field (loff_t, size) __field(unsigned int, nlink)
@@ -59,8 +59,8 @@ DECLARE_EVENT_CLASS(hugetlbfs__inode, __entry->blocks = inode->i_blocks; ), -TP_printk ("dev %d,%d ino %lu mode 0%o size %lld nlink %u seals %u blocks %llu" , -MAJOR (__entry->dev),MINOR (__entry->dev), (unsigned long ) __entry->ino, +TP_printk ("dev %d,%d ino %llu mode 0%o size %lld nlink %u seals %u blocks %llu" , +MAJOR (__entry->dev),MINOR (__entry->dev), __entry->ino, __entry->mode, __entry->size, __entry->nlink, __entry->seals, (unsigned long long )__entry->blocks) );
@@ -88,7 +88,7 @@ TRACE_EVENT(hugetlbfs_setattr,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) +__field (u64, ino) __field(unsigned int, d_len) __string(d_name, dentry->d_name.name) __field(unsigned int, ia_valid)
@@ -108,8 +108,8 @@ TRACE_EVENT(hugetlbfs_setattr, __entry->ia_size = attr->ia_size; ), -TP_printk ("dev %d,%d ino %lu name %.*s valid %#x mode 0%o old_size %lld size %lld" , -MAJOR (__entry->dev),MINOR (__entry->dev), (unsigned long )__entry->ino, +TP_printk ("dev %d,%d ino %llu name %.*s valid %#x mode 0%o old_size %lld size %lld" , +MAJOR (__entry->dev),MINOR (__entry->dev), __entry->ino, __entry->d_len,__get_str (d_name), __entry->ia_valid, __entry->ia_mode, __entry->old_size, __entry->ia_size) );
@@ -123,7 +123,7 @@ TRACE_EVENT(hugetlbfs_fallocate,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) +__field (u64, ino)__field (int, mode)__field (loff_t, offset) __field(loff_t, len)
@@ -141,9 +141,9 @@ TRACE_EVENT(hugetlbfs_fallocate, __entry->ret = ret; ), - TP_printk("dev %d,%d ino %lu mode 0%o offset %lld len %lld size %lld ret %d", + TP_printk("dev %d,%d ino %llu mode 0%o offset %lld len %lld size %lld ret %d", MAJOR(__entry->dev), MINOR(__entry->dev), - (unsigned long)__entry->ino, __entry->mode, + __entry->ino, __entry->mode, (unsigned long long)__entry->offset, (unsigned long long)__entry->len, (unsigned long long)__entry->size,
include/trace/events/netfs.h +2 -2
@@ -484,7 +484,7 @@ TRACE_EVENT(netfs_folio, TP_ARGS(folio, why),TP_STRUCT__entry ( -__field (ino_t ,ino ) +__field (u64 ,ino )__field (pgoff_t, index) __field(unsigned int, nr) __field(enum netfs_folio_trace, why)
@@ -498,7 +498,7 @@ TRACE_EVENT(netfs_folio, __entry->nr =folio_nr_pages (folio); ), -TP_printk ("i=%05lx ix=%05lx-%05lx %s" , +TP_printk ("i=%05llx ix=%05lx-%05lx %s" , __entry->ino, __entry->index, __entry->index + __entry->nr -1 ,__print_symbolic (__entry->why, netfs_folio_traces)) );
include/trace/events/readahead.h +6 -6
@@ -18,7 +18,7 @@ TRACE_EVENT(page_cache_ra_unbounded,TP_ARGS (inode, index, nr_to_read, lookahead_size),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) + __field(u64, i_ino) __field(dev_t, s_dev) __field(pgoff_t, index) __field(unsigned long, nr_to_read)
@@ -34,7 +34,7 @@ TRACE_EVENT(page_cache_ra_unbounded, ),TP_printk ( -"dev=%d:%d ino=%lx index=%lu nr_to_read=%lu lookahead_size=%lu" , +"dev=%d:%d ino=%llx index=%lu nr_to_read=%lu lookahead_size=%lu" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, __entry->index, __entry->nr_to_read, __entry->lookahead_size )
@@ -46,7 +46,7 @@ TRACE_EVENT(page_cache_ra_order,TP_ARGS (inode, index, ra),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) + __field(u64, i_ino) __field(dev_t, s_dev) __field(pgoff_t, index) __field(unsigned int, order)
@@ -66,7 +66,7 @@ TRACE_EVENT(page_cache_ra_order, ),TP_printk ( -"dev=%d:%d ino=%lx index=%lu order=%u size=%u async_size=%u ra_pages=%u" , +"dev=%d:%d ino=%llx index=%lu order=%u size=%u async_size=%u ra_pages=%u" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, __entry->index, __entry->order, __entry->size, __entry->async_size, __entry->ra_pages
@@ -80,7 +80,7 @@ DECLARE_EVENT_CLASS(page_cache_ra_op,TP_ARGS (inode, index, ra, req_count),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) + __field(u64, i_ino) __field(dev_t, s_dev) __field(pgoff_t, index) __field(unsigned int, order)
@@ -106,7 +106,7 @@ DECLARE_EVENT_CLASS(page_cache_ra_op, ), TP_printk( - "dev=%d:%d ino=%lx index=%lu req_count=%lu order=%u size=%u async_size=%u ra_pages=%u mmap_miss=%u prev_pos=%lld", + "dev=%d:%d ino=%llx index=%lu req_count=%lu order=%u size=%u async_size=%u ra_pages=%u mmap_miss=%u prev_pos=%lld", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->index, __entry->req_count, __entry->order, __entry->size, __entry->async_size, __entry->ra_pages,
include/trace/events/timestamp.h +6 -6
@@ -19,7 +19,7 @@ DECLARE_EVENT_CLASS(ctime,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) +__field (u64, ino)__field (time64_t, ctime_s)__field (u32, ctime_ns) __field(u32, gen)
@@ -33,7 +33,7 @@ DECLARE_EVENT_CLASS(ctime, __entry->ctime_ns = ctime->tv_nsec; ), -TP_printk ("ino=%d:%d:%ld:%u ctime=%lld.%u" , +TP_printk ("ino=%d:%d:%llu:%u ctime=%lld.%u" ,MAJOR (__entry->dev),MINOR (__entry->dev), __entry->ino, __entry->gen, __entry->ctime_s, __entry->ctime_ns )
@@ -59,7 +59,7 @@ TRACE_EVENT(ctime_ns_xchg,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) +__field (u64, ino)__field (u32, gen)__field (u32, old) __field(u32, new)
@@ -75,7 +75,7 @@ TRACE_EVENT(ctime_ns_xchg, __entry->cur = cur; ), - TP_printk("ino=%d:%d:%ld:%u old=%u:%s new=%u cur=%u:%s", + TP_printk("ino=%d:%d:%llu:%u old=%u:%s new=%u cur=%u:%s", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino, __entry->gen, __entry->old & ~I_CTIME_QUERIED, __print_flags(__entry->old & I_CTIME_QUERIED, "|", CTIME_QUERIED_FLAGS),
@@ -94,7 +94,7 @@ TRACE_EVENT(fill_mg_cmtime,TP_STRUCT__entry (__field (dev_t ,dev ) -__field (ino_t, ino) +__field (u64, ino)__field (time64_t, ctime_s)__field (time64_t, mtime_s) __field(u32, ctime_ns)
@@ -112,7 +112,7 @@ TRACE_EVENT(fill_mg_cmtime, __entry->mtime_ns = mtime->tv_nsec; ), -TP_printk ("ino=%d:%d:%ld:%u ctime=%lld.%u mtime=%lld.%u" , +TP_printk ("ino=%d:%d:%llu:%u ctime=%lld.%u mtime=%lld.%u" ,MAJOR (__entry->dev),MINOR (__entry->dev), __entry->ino, __entry->gen, __entry->ctime_s, __entry->ctime_ns, __entry->mtime_s, __entry->mtime_ns
include/trace/events/writeback.h +74 -74
433 lines not on this page · raw message
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 4/61 ext4: update for u64 i_ino
In reply to Jeff LaytonUpdate ext4 trace events and filesystem code for u64 i_ino:
- Change __field(ino_t, ...) to __field(u64, ...) in trace events
- Update all %lu format strings to %llu for inode numbers
- Cast to (unsigned long long) where needed in TP_printk
- Update __ext4_grp_locked_error() ino parameter to u64
- Update ext_debug() format string
--- fs/ext4/dir.c | 2 +- fs/ext4/ext4.h | 4 +- fs/ext4/extents.c | 8 +- fs/ext4/extents_status.c | 28 +-- fs/ext4/fast_commit.c | 8 +- fs/ext4/ialloc.c | 10 +- fs/ext4/indirect.c | 2 +- fs/ext4/inline.c | 14 +- fs/ext4/inode.c | 22 +-- fs/ext4/ioctl.c | 4 +- fs/ext4/mballoc.c | 6 +- fs/ext4/migrate.c | 2 +- fs/ext4/move_extent.c | 20 +-- fs/ext4/namei.c | 10 +- fs/ext4/orphan.c | 16 +- fs/ext4/page-io.c | 10 +- fs/ext4/super.c | 22 +-- fs/ext4/xattr.c | 10 +- include/trace/events/ext4.h | 427 ++++++++++++++++++++++---------------------- 19 files changed, 313 insertions(+), 312 deletions(-)
fs/ext4/dir.c +1 -1
@@ -535,7 +535,7 @@ static int call_filldir(struct file *file, struct dir_context *ctx,struct super_block *sb = inode->i_sb;if (!fname) { -ext4_msg (sb,KERN_ERR ,"%s:%d: inode #%lu: comm %s: " +ext4_msg (sb,KERN_ERR ,"%s:%d: inode #%llu: comm %s: " "called with null fname?!?" , __func__, __LINE__, inode->i_ino, current->comm);return 0 ;
fs/ext4/ext4.h +2 -2
@@ -92,7 +92,7 @@*/ #ifdef CONFIG_EXT4_DEBUG #define ext_debug (ino, fmt, ...) \ - pr_debug("[%s/%d] EXT4-fs (%s): ino %lu: (%s, %d): %s:" fmt, \ + pr_debug("[%s/%d] EXT4-fs (%s): ino %llu: (%s, %d): %s:" fmt, \ current->comm, task_pid_nr(current), \ ino->i_sb->s_id, ino->i_ino, __FILE__, __LINE__, \ __func__, ##__VA_ARGS__)
@@ -3229,7 +3229,7 @@ extern void __dump_mmp_msg(struct super_block *, struct mmp_struct *mmp, extern __printf(7, 8) void __ext4_grp_locked_error(const char *, unsigned int, struct super_block *, ext4_group_t, - unsigned long, ext4_fsblk_t, + u64, ext4_fsblk_t, const char *, ...); #define EXT4_ERROR_INODE(inode, fmt, a...) \
fs/ext4/extents.c +4 -4
@@ -4603,7 +4603,7 @@ static int ext4_alloc_file_blocks(struct file *file, ext4_lblk_t offset, } ret =ext4_map_blocks (handle, inode, &map, flags);if (ret <=0 ) { -ext4_debug ("inode #%lu: block %u: len %u: " +ext4_debug ("inode #%llu: block %u: len %u: " "ext4_ext_map_blocks returned %d" , inode->i_ino, map.m_lblk, map.m_len, ret);
@@ -4955,7 +4955,7 @@ int ext4_convert_unwritten_extents_atomic(handle_t *handle, struct inode *inode, ret =ext4_map_blocks (handle, inode, &map, flags);if (ret != max_blocks) ext4_msg(inode->i_sb, KERN_INFO, - "inode #%lu: block %u: len %u: " + "inode #%llu: block %u: len %u: " "split block mapping found for atomic write, " "ret = %d", inode->i_ino, map.m_lblk,
@@ -4974,7 +4974,7 @@ int ext4_convert_unwritten_extents_atomic(handle_t *handle, struct inode *inode,if (ret <=0 || ret2)ext4_warning (inode->i_sb, -"inode #%lu: block %u: len %u: " +"inode #%llu: block %u: len %u: " "returned %d or %d" , inode->i_ino, map.m_lblk, map.m_len, ret, ret2);
@@ -5031,7 +5031,7 @@ int ext4_convert_unwritten_extents(handle_t *handle, struct inode *inode, EXT4_EX_NOCACHE);if (ret <=0 )ext4_warning (inode->i_sb, -"inode #%lu: block %u: len %u: " +"inode #%llu: block %u: len %u: " "ext4_ext_map_blocks returned %d" , inode->i_ino, map.m_lblk, map.m_len, ret);
fs/ext4/extents_status.c +14 -14
@@ -214,7 +214,7 @@ static void ext4_es_print_tree(struct inode *inode)struct ext4_es_tree *tree;struct rb_node *node; -printk (KERN_DEBUG "status extents for inode %lu:" , inode->i_ino); +printk (KERN_DEBUG "status extents for inode %llu:" , inode->i_ino); tree = &EXT4_I (inode)->i_es_tree; node =rb_first (&tree->root);while (node) {
@@ -703,7 +703,7 @@ static void ext4_es_insert_extent_ext_check(struct inode *inode,if (!ext4_es_is_written (es) && !ext4_es_is_unwritten (es)) {if (in_range (es->es_lblk, ee_block, ee_len)) { pr_warn("ES insert assertion failed for " - "inode: %lu we can find an extent " + "inode: %llu we can find an extent " "at block [%d/%d/%llu/%c], but we " "want to add a delayed/hole extent " "[%d/%d/%llu/%x]\n",
@@ -721,7 +721,7 @@ static void ext4_es_insert_extent_ext_check(struct inode *inode,*/ if (es->es_lblk < ee_block ||ext4_es_pblock (es) != ee_start + es->es_lblk - ee_block) { - pr_warn("ES insert assertion failed for inode: %lu " + pr_warn("ES insert assertion failed for inode: %llu " "ex_status [%d/%d/%llu/%c] != " "es_status [%d/%d/%llu/%c]\n", inode->i_ino, ee_block, ee_len, ee_start,
@@ -731,7 +731,7 @@ static void ext4_es_insert_extent_ext_check(struct inode *inode, }if (ee_status ^ es_status) { - pr_warn("ES insert assertion failed for inode: %lu " + pr_warn("ES insert assertion failed for inode: %llu " "ex_status [%d/%d/%llu/%c] != " "es_status [%d/%d/%llu/%c]\n", inode->i_ino, ee_block, ee_len, ee_start,
@@ -744,7 +744,7 @@ static void ext4_es_insert_extent_ext_check(struct inode *inode,* that we don't want to add an written/unwritten extent. */ if (!ext4_es_is_delayed (es) && !ext4_es_is_hole (es)) { - pr_warn("ES insert assertion failed for inode: %lu " + pr_warn("ES insert assertion failed for inode: %llu " "can't find an extent at block %d but we want " "to add a written/unwritten extent " "[%d/%d/%llu/%x]\n", inode->i_ino,
@@ -779,7 +779,7 @@ static void ext4_es_insert_extent_ind_check(struct inode *inode,* We want to add a delayed/hole extent but this * block has been allocated. */ - pr_warn("ES insert assertion failed for inode: %lu " + pr_warn("ES insert assertion failed for inode: %llu " "We can find blocks but we want to add a " "delayed/hole extent [%d/%d/%llu/%x]\n", inode->i_ino, es->es_lblk, es->es_len,
@@ -788,13 +788,13 @@ static void ext4_es_insert_extent_ind_check(struct inode *inode, }else if (ext4_es_is_written (es)) {if (retval != es->es_len) {pr_warn ("ES insert assertion failed for " -"inode: %lu retval %d != es_len %d\n" , +"inode: %llu retval %d != es_len %d\n" , inode->i_ino, retval, es->es_len);return ; }if (map.m_pblk !=ext4_es_pblock (es)) {pr_warn ("ES insert assertion failed for " -"inode: %lu m_pblk %llu != " +"inode: %llu m_pblk %llu != " "es_pblk %llu\n" , inode->i_ino, map.m_pblk,ext4_es_pblock (es));
@@ -809,7 +809,7 @@ static void ext4_es_insert_extent_ind_check(struct inode *inode, } }else if (retval ==0 ) {if (ext4_es_is_written (es)) { - pr_warn("ES insert assertion failed for inode: %lu " + pr_warn("ES insert assertion failed for inode: %llu " "We can't find the block but we want to add " "a written extent [%d/%d/%llu/%x]\n", inode->i_ino, es->es_lblk, es->es_len,
@@ -919,7 +919,7 @@ void ext4_es_insert_extent(struct inode *inode, ext4_lblk_t lblk,if (EXT4_SB (inode->i_sb)->s_mount_state &EXT4_FC_REPLAY )return ; -es_debug ("add [%u/%u) %llu %x %d to extent status tree of inode %lu\n" , +es_debug ("add [%u/%u) %llu %x %d to extent status tree of inode %llu\n" , lblk, len, pblk, status, delalloc_reserve_used, inode->i_ino);if (!len)
@@ -1631,7 +1631,7 @@ void ext4_es_remove_extent(struct inode *inode, ext4_lblk_t lblk,if (EXT4_SB (inode->i_sb)->s_mount_state &EXT4_FC_REPLAY )return ; -es_debug ("remove [%u/%u) from extent status tree of inode %lu\n" , +es_debug ("remove [%u/%u) from extent status tree of inode %llu\n" , lblk, len, inode->i_ino);if (!len)
@@ -1821,7 +1821,7 @@ int ext4_seq_es_shrinker_info_show(struct seq_file *seq, void *v)seq_printf (seq," %lu shrunk objects\n" , es_stats->es_stats_shrunk);if (inode_cnt)seq_printf (seq, -"maximum:\n %lu inode (%u objects, %u reclaimable)\n" +"maximum:\n %llu inode (%u objects, %u reclaimable)\n" " %llu us max scan time\n" , max->vfs_inode.i_ino, max->i_es_all_nr, max->i_es_shk_nr,div_u64 (es_stats->es_stats_max_scan_time,1000 ));
@@ -1998,7 +1998,7 @@ static void ext4_print_pending_tree(struct inode *inode)struct rb_node *node;struct pending_reservation *pr; -printk (KERN_DEBUG "pending reservations for inode %lu:" , inode->i_ino); +printk (KERN_DEBUG "pending reservations for inode %llu:" , inode->i_ino); tree = &EXT4_I (inode)->i_pending_tree; node =rb_first (&tree->root);while (node) {
@@ -2214,7 +2214,7 @@ void ext4_es_insert_delayed_extent(struct inode *inode, ext4_lblk_t lblk,if (EXT4_SB (inode->i_sb)->s_mount_state &EXT4_FC_REPLAY )return ; -es_debug ("add [%u/%u) delayed to extent status tree of inode %lu\n" , +es_debug ("add [%u/%u) delayed to extent status tree of inode %llu\n" , lblk, len, inode->i_ino);if (!len)return ;
fs/ext4/fast_commit.c +4 -4
@@ -616,7 +616,7 @@ static int __track_range(handle_t *handle, struct inode *inode, void *arg, (struct __track_range_args *)arg;if (inode->i_ino <EXT4_FIRST_INO (inode->i_sb)) { -ext4_debug ("Special inode %ld being modified\n" , inode->i_ino); +ext4_debug ("Special inode %llu being modified\n" , inode->i_ino);return -ECANCELED ; }
@@ -914,7 +914,7 @@ static int ext4_fc_write_inode_data(struct inode *inode, u32 *crc)spin_unlock (&ei->i_fc_lock); cur_lblk_off = old_blk_size; -ext4_debug ("will try writing %d to %d for inode %ld\n" , +ext4_debug ("will try writing %d to %d for inode %llu\n" , cur_lblk_off, new_blk_size, inode->i_ino);while (cur_lblk_off <= new_blk_size) {
@@ -1792,7 +1792,7 @@ static int ext4_fc_replay_add_range(struct super_block *sb, cur = start; remaining = len; -ext4_debug ("ADD_RANGE, lblk %d, pblk %lld, len %d, unwritten %d, inode %ld\n" , +ext4_debug ("ADD_RANGE, lblk %d, pblk %lld, len %d, unwritten %d, inode %llu\n" , start, start_pblk, len,ext4_ext_is_unwritten (ex), inode->i_ino);
@@ -1903,7 +1903,7 @@ ext4_fc_replay_del_range(struct super_block *sb,if (ret) goto out; -ext4_debug ("DEL_RANGE, inode %ld, lblk %d, len %d\n" , +ext4_debug ("DEL_RANGE, inode %llu, lblk %d, len %d\n" , inode->i_ino,le32_to_cpu (lrange.fc_lblk),le32_to_cpu (lrange.fc_len));while (remaining >0 ) {
fs/ext4/ialloc.c +5 -5
@@ -253,13 +253,13 @@ void ext4_free_inode(handle_t *handle, struct inode *inode)return ; }if (icount_read (inode) >1 ) { -ext4_msg (sb,KERN_ERR ,"%s:%d: inode #%lu: count=%d" , +ext4_msg (sb,KERN_ERR ,"%s:%d: inode #%llu: count=%d" , __func__, __LINE__, inode->i_ino,icount_read (inode));return ; }if (inode->i_nlink) { -ext4_msg (sb,KERN_ERR ,"%s:%d: inode #%lu: nlink=%d\n" , +ext4_msg (sb,KERN_ERR ,"%s:%d: inode #%llu: nlink=%d\n" , __func__, __LINE__, inode->i_ino, inode->i_nlink);return ; }
@@ -631,7 +631,7 @@ static int find_group_other(struct super_block *sb, struct inode *parent,* * So add our directory's i_ino into the starting point for the hash. */ - *group = (*group + parent->i_ino) % ngroups; + *group = (*group + (unsigned int )parent->i_ino) % ngroups;/* * Use a quadratic hash to find a group with a free inode and some free
@@ -1275,7 +1275,7 @@ struct inode *__ext4_new_inode(struct mnt_idmap *idmap,* twice. */ err = -EIO ; -ext4_error (sb,"failed to insert inode %lu: doubly allocated?" , +ext4_error (sb,"failed to insert inode %llu: doubly allocated?" , inode->i_ino);ext4_mark_group_bitmap_corrupted (sb, group,EXT4_GROUP_INFO_IBITMAP_CORRUPT );
@@ -1344,7 +1344,7 @@ struct inode *__ext4_new_inode(struct mnt_idmap *idmap, goto fail_free_drop; } -ext4_debug ("allocating inode %lu\n" , inode->i_ino); +ext4_debug ("allocating inode %llu\n" , inode->i_ino);trace_ext4_allocate_inode (inode, dir, mode);brelse (inode_bitmap_bh);return ret;
fs/ext4/indirect.c +1 -1
@@ -102,7 +102,7 @@ static int ext4_block_to_path(struct inode *inode, offsets[n++] = i_block & (ptrs -1 ); final = ptrs; }else { -ext4_warning (inode->i_sb,"block %lu > max in inode %lu" , +ext4_warning (inode->i_sb,"block %lu > max in inode %llu" , i_block + direct_blocks + indirect_blocks + double_blocks, inode->i_ino); }
fs/ext4/inline.c +7 -7
@@ -119,7 +119,7 @@ int ext4_get_max_inline_size(struct inode *inode) error =ext4_get_inode_loc (inode, &iloc);if (error) {ext4_error_inode_err (inode, __func__, __LINE__,0 , -error, -"can't get inode location %lu" , +"can't get inode location %llu" , inode->i_ino);return 0 ; }
@@ -512,7 +512,7 @@ static int ext4_read_inline_folio(struct inode *inode, struct folio *folio)BUG_ON (folio->index);if (!EXT4_I (inode)->i_inline_off) { -ext4_warning (inode->i_sb,"inode %lu doesn't have inline data." , +ext4_warning (inode->i_sb,"inode %llu doesn't have inline data." , inode->i_ino); goto out; }
@@ -934,7 +934,7 @@ void ext4_show_inline_dir(struct inode *dir, struct buffer_head *bh,struct ext4_dir_entry_2 *de = inline_start;void *dlimit = inline_start + inline_size; -trace_printk ("inode %lu\n" , dir->i_ino); +trace_printk ("inode %llu\n" , dir->i_ino); offset =0 ;while ((void *)de < dlimit) { de_len =ext4_rec_len_from_disk (de->rec_len, inline_size);
@@ -1071,7 +1071,7 @@ static void ext4_restore_inline_data(handle_t *handle, struct inode *inode, ret =ext4_create_inline_data (handle, inode, inline_size);if (ret) {ext4_msg (inode->i_sb,KERN_EMERG , -"error restoring inline_data for inode -- potential data loss! (inode %lu, error %d)" , +"error restoring inline_data for inode -- potential data loss! (inode %llu, error %d)" , inode->i_ino, ret);return ; }
@@ -1740,7 +1740,7 @@ bool empty_inline_dir(struct inode *dir, int *has_inline_data) err =ext4_get_inode_loc (dir, &iloc);if (err) {EXT4_ERROR_INODE_ERR (dir, -err, -"error %d getting inode %lu block" , +"error %d getting inode %llu block" , err, dir->i_ino);return false; }
@@ -1755,7 +1755,7 @@ bool empty_inline_dir(struct inode *dir, int *has_inline_data) de = (struct ext4_dir_entry_2 *)ext4_raw_inode (&iloc)->i_block;if (!le32_to_cpu (de->inode)) {ext4_warning (dir->i_sb, -"bad inline directory (dir #%lu) - no `..'" , +"bad inline directory (dir #%llu) - no `..'" , dir->i_ino); goto out; }
@@ -1769,7 +1769,7 @@ bool empty_inline_dir(struct inode *dir, int *has_inline_data) iloc.bh, inline_pos, inline_size, offset)) { ext4_warning(dir->i_sb, - "bad inline directory (dir #%lu) - " + "bad inline directory (dir #%llu) - " "inode %u, rec_len %u, name_len %d" "inline size %d", dir->i_ino, le32_to_cpu(de->inode),
fs/ext4/inode.c +11 -11
@@ -262,7 +262,7 @@ void ext4_evict_inode(struct inode *inode) err =ext4_truncate (inode);if (err) {ext4_error_err (inode->i_sb, -err, -"couldn't truncate inode %lu (err %d)" , +"couldn't truncate inode %llu (err %d)" , inode->i_ino, err); goto stop_handle; }
@@ -342,7 +342,7 @@ void ext4_da_update_reserve_space(struct inode *inode,spin_lock (&ei->i_block_reservation_lock);trace_ext4_da_update_reserve_space (inode, used, quota_claim);if (unlikely (used > ei->i_reserved_data_blocks)) { -ext4_warning (inode->i_sb,"%s: ino %lu, used %d " +ext4_warning (inode->i_sb,"%s: ino %llu, used %d " "with only %d reserved data blocks" , __func__, inode->i_ino, used, ei->i_reserved_data_blocks);
@@ -475,7 +475,7 @@ static void ext4_map_blocks_es_recheck(handle_t *handle,if (es_map->m_lblk != map->m_lblk || es_map->m_flags != map->m_flags || es_map->m_pblk != map->m_pblk) { - printk("ES cache assertion failed for inode: %lu " + printk("ES cache assertion failed for inode: %llu " "es_cached ex [%d/%d/%llu/%x] != " "found ex [%d/%d/%llu/%x] retval %d flags %x\n", inode->i_ino, es_map->m_lblk, es_map->m_len,
@@ -515,7 +515,7 @@ static int ext4_map_query_blocks_next_in_leaf(handle_t *handle,if (unlikely (retval != map2.m_len)) {ext4_warning (inode->i_sb,"ES len assertion failed for inode " -"%lu: retval %d != map->m_len %d" , +"%llu: retval %d != map->m_len %d" , inode->i_ino, retval, map2.m_len);WARN_ON (1 ); }
@@ -563,7 +563,7 @@ int ext4_map_query_blocks(handle_t *handle, struct inode *inode,if (unlikely (retval != map->m_len)) {ext4_warning (inode->i_sb,"ES len assertion failed for inode " -"%lu: retval %d != map->m_len %d" , +"%llu: retval %d != map->m_len %d" , inode->i_ino, retval, map->m_len);WARN_ON (1 ); }
@@ -630,7 +630,7 @@ int ext4_map_create_blocks(handle_t *handle, struct inode *inode,if (unlikely (retval != map->m_len)) {ext4_warning (inode->i_sb, -"ES len assertion failed for inode %lu: " +"ES len assertion failed for inode %llu: " "retval %d != map->m_len %d" , inode->i_ino, retval, map->m_len);WARN_ON (1 );
@@ -937,7 +937,7 @@ int ext4_get_block_unwritten(struct inode *inode, sector_t iblock, {int ret =0 ; -ext4_debug ("ext4_get_block_unwritten: inode %lu, create flag %d\n" , +ext4_debug ("ext4_get_block_unwritten: inode %llu, create flag %d\n" , inode->i_ino, create); ret =_ext4_get_block (inode, iblock, bh_result,EXT4_GET_BLOCKS_CREATE_UNWRIT_EXT );
@@ -1659,7 +1659,7 @@ void ext4_da_release_space(struct inode *inode, int to_free)* harmless to return without any action. */ ext4_warning (inode->i_sb,"ext4_da_release_space: " -"ino %lu, to_free %d with only %d reserved " +"ino %llu, to_free %d with only %d reserved " "data blocks" , inode->i_ino, to_free, ei->i_reserved_data_blocks);WARN_ON (1 );
@@ -2491,7 +2491,7 @@ static int mpage_map_and_submit_extent(handle_t *handle, } ext4_msg(sb, KERN_CRIT, "Delayed block allocation failed for " - "inode %lu at logical offset %llu with" + "inode %llu at logical offset %llu with" " max blocks %u with error %d", inode->i_ino, (unsigned long long)map->m_lblk,
@@ -2535,7 +2535,7 @@ static int mpage_map_and_submit_extent(handle_t *handle, err2 =ext4_mark_inode_dirty (handle, inode);if (err2) {ext4_error_err (inode->i_sb, -err2, -"Failed to mark inode %lu dirty" , +"Failed to mark inode %llu dirty" , inode->i_ino); }if (!err)
@@ -2909,7 +2909,7 @@ static int ext4_do_writepages(struct mpage_da_data *mpd)if (IS_ERR (handle)) { ret =PTR_ERR (handle);ext4_msg (inode->i_sb,KERN_CRIT ,"%s: jbd2_start: " -"%ld pages, ino %lu; err %d" , __func__, +"%ld pages, ino %llu; err %d" , __func__, wbc->nr_to_write, inode->i_ino, ret);/* Release allocated io_end */ ext4_put_io_end (mpd->io_submit.io_end);
fs/ext4/ioctl.c +2 -2
@@ -477,7 +477,7 @@ static long swap_inode_boot_loader(struct super_block *sb,if (err <0 ) {/* No need to update quota information. */ ext4_warning (inode->i_sb, -"couldn't mark inode #%lu dirty (err %d)" , +"couldn't mark inode #%llu dirty (err %d)" , inode->i_ino, err);/* Revert all changes: */ swap_inode_data (inode, inode_bl);
@@ -493,7 +493,7 @@ static long swap_inode_boot_loader(struct super_block *sb,if (err <0 ) {/* No need to update quota information. */ ext4_warning (inode_bl->i_sb, -"couldn't mark inode #%lu dirty (err %d)" , +"couldn't mark inode #%llu dirty (err %d)" , inode_bl->i_ino, err); goto revert; }
fs/ext4/mballoc.c +3 -3
@@ -2266,7 +2266,7 @@ static void ext4_mb_use_best_found(struct ext4_allocation_context *ac,folio_get (ac->ac_buddy_folio);/* store last allocated for subsequent stream allocation */ if (ac->ac_flags &EXT4_MB_STREAM_ALLOC ) { -int hash = ac->ac_inode->i_ino % sbi->s_mb_nr_global_goals; +int hash = (unsigned int )ac->ac_inode->i_ino % sbi->s_mb_nr_global_goals;WRITE_ONCE (sbi->s_mb_last_groups[hash], ac->ac_f_ex.fe_group); }
@@ -3032,7 +3032,7 @@ ext4_mb_regular_allocator(struct ext4_allocation_context *ac)/* if stream allocation is enabled, use global goal */ if (ac->ac_flags &EXT4_MB_STREAM_ALLOC ) { -int hash = ac->ac_inode->i_ino % sbi->s_mb_nr_global_goals; +int hash = (unsigned int )ac->ac_inode->i_ino % sbi->s_mb_nr_global_goals; ac->ac_g_ex.fe_group =READ_ONCE (sbi->s_mb_last_groups[hash]); ac->ac_g_ex.fe_start =-1 ;
@@ -5628,7 +5628,7 @@ void ext4_discard_preallocations(struct inode *inode)if (EXT4_SB (sb)->s_mount_state &EXT4_FC_REPLAY )return ; -mb_debug (sb,"discard preallocation for inode %lu\n" , +mb_debug (sb,"discard preallocation for inode %llu\n" , inode->i_ino);trace_ext4_discard_preallocations (inode,atomic_read (&ei->i_prealloc_active));
fs/ext4/migrate.c +1 -1
@@ -455,7 +455,7 @@ int ext4_ext_migrate(struct inode *inode)* log, so disable fast commits for this transaction. */ ext4_fc_mark_ineligible (inode->i_sb,EXT4_FC_REASON_MIGRATE , handle); - goal = (((inode->i_ino -1 ) /EXT4_INODES_PER_GROUP (inode->i_sb)) * + goal = (div_u64 (inode->i_ino -1 ,EXT4_INODES_PER_GROUP (inode->i_sb)) *EXT4_INODES_PER_GROUP (inode->i_sb)) +1 ; owner[0 ] =i_uid_read (inode); owner[1 ] =i_gid_read (inode);
fs/ext4/move_extent.c +10 -10
@@ -420,21 +420,21 @@ static int mext_check_validity(struct inode *orig_inode,/* origin and donor should be different inodes */ if (orig_inode == donor_inode) { -ext4_debug ("ext4 move extent: The argument files should not be same inode [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: The argument files should not be same inode [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ; }/* origin and donor should belone to the same filesystem */ if (orig_inode->i_sb != donor_inode->i_sb) { -ext4_debug ("ext4 move extent: The argument files should be in same FS [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: The argument files should be in same FS [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ; }/* Regular file check */ if (!S_ISREG (orig_inode->i_mode) || !S_ISREG (donor_inode->i_mode)) { -ext4_debug ("ext4 move extent: The argument files should be regular file [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: The argument files should be regular file [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ; }
@@ -477,26 +477,26 @@ static int mext_check_validity(struct inode *orig_inode, }if (donor_inode->i_mode & (S_ISUID |S_ISGID )) { -ext4_debug ("ext4 move extent: suid or sgid is set to donor file [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: suid or sgid is set to donor file [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ; }if (IS_IMMUTABLE (donor_inode) ||IS_APPEND (donor_inode)) { -ext4_debug ("ext4 move extent: donor should not be immutable or append file [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: donor should not be immutable or append file [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EPERM ; }/* Ext4 move extent does not support swap files */ if (IS_SWAPFILE (orig_inode) ||IS_SWAPFILE (donor_inode)) { -ext4_debug ("ext4 move extent: The argument files should not be swap files [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: The argument files should not be swap files [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -ETXTBSY ; }if (ext4_is_quota_file (orig_inode) ||ext4_is_quota_file (donor_inode)) { -ext4_debug ("ext4 move extent: The argument files should not be quota files [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: The argument files should not be quota files [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EOPNOTSUPP ; }
@@ -523,7 +523,7 @@ static int mext_check_adjust_range(struct inode *orig_inode,/* Start offset should be same */ if ((orig_start & ~(PAGE_MASK >> orig_inode->i_blkbits)) != (donor_start & ~(PAGE_MASK >> orig_inode->i_blkbits))) { -ext4_debug ("ext4 move extent: orig and donor's start offsets are not aligned [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: orig and donor's start offsets are not aligned [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ; }
@@ -533,7 +533,7 @@ static int mext_check_adjust_range(struct inode *orig_inode, (*len > EXT_MAX_BLOCKS) || (donor_start + *len >= EXT_MAX_BLOCKS) || (orig_start + *len >= EXT_MAX_BLOCKS)) { -ext4_debug ("ext4 move extent: Can't handle over [%u] blocks [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: Can't handle over [%u] blocks [ino:orig %llu, donor %llu]\n" ,EXT_MAX_BLOCKS , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ;
@@ -550,7 +550,7 @@ static int mext_check_adjust_range(struct inode *orig_inode,else if (donor_eof < donor_start + *len -1 ) *len = donor_eof - donor_start;if (!*len) { -ext4_debug ("ext4 move extent: len should not be 0 [ino:orig %lu, donor %lu]\n" , +ext4_debug ("ext4 move extent: len should not be 0 [ino:orig %llu, donor %llu]\n" , orig_inode->i_ino, donor_inode->i_ino);return -EINVAL ; }
fs/ext4/namei.c +5 -5
@@ -144,7 +144,7 @@ static struct buffer_head *__ext4_read_dirblock(struct inode *inode, bh =ext4_bread (NULL , inode, block,0 );if (IS_ERR (bh)) {__ext4_warning (inode->i_sb, func, line, -"inode #%lu: lblock %lu: comm %s: " +"inode #%llu: lblock %lu: comm %s: " "error %ld reading directory block" , inode->i_ino, (unsigned long )block, current->comm,PTR_ERR (bh));
@@ -841,7 +841,7 @@ dx_probe(struct ext4_filename *fname, struct inode *dir, indirect = root->info.indirect_levels;if (indirect >=ext4_dir_htree_level (dir->i_sb)) {ext4_warning (dir->i_sb, -"Directory (ino: %lu) htree depth %#06x exceed" +"Directory (ino: %llu) htree depth %#06x exceed" "supported value" , dir->i_ino,ext4_dir_htree_level (dir->i_sb));if (ext4_dir_htree_level (dir->i_sb) <EXT4_HTREE_LEVEL ) {
@@ -1793,7 +1793,7 @@ static struct dentry *ext4_lookup(struct inode *dir, struct dentry *dentry, unsi (S_ISDIR(inode->i_mode) || S_ISLNK(inode->i_mode)) && !fscrypt_has_permitted_context(dir, inode)) {ext4_warning (inode->i_sb, -"Inconsistent encryption contexts: %lu/%lu" , +"Inconsistent encryption contexts: %llu/%llu" , dir->i_ino, inode->i_ino);iput (inode);return ERR_PTR (-EPERM );
@@ -2227,7 +2227,7 @@ static int make_indexed_dir(handle_t *handle, struct ext4_filename *fname, csum_size =sizeof (struct ext4_dir_entry_tail ); blocksize = dir->i_sb->s_blocksize; -dxtrace (printk (KERN_DEBUG "Creating index: inode %lu\n" , dir->i_ino)); +dxtrace (printk (KERN_DEBUG "Creating index: inode %llu\n" , dir->i_ino));BUFFER_TRACE (bh,"get_write_access" ); retval =ext4_journal_get_write_access (handle, dir->i_sb, bh,EXT4_JTR_NONE );
@@ -2523,7 +2523,7 @@ static int ext4_dx_add_entry(handle_t *handle, struct ext4_filename *fname, restart =1 ; }if (add_level && levels ==ext4_dir_htree_level (sb)) { -ext4_warning (sb,"Directory (ino: %lu) index full, " +ext4_warning (sb,"Directory (ino: %llu) index full, " "reach max htree level :%d" , dir->i_ino, levels);if (ext4_dir_htree_level (sb) <EXT4_HTREE_LEVEL ) {
fs/ext4/orphan.c +8 -8
@@ -179,8 +179,8 @@ int ext4_orphan_add(handle_t *handle, struct inode *inode) }else brelse (iloc.bh); -ext4_debug ("superblock will point to %lu\n" , inode->i_ino); -ext4_debug ("orphan inode %lu will point to %d\n" , +ext4_debug ("superblock will point to %llu\n" , inode->i_ino); +ext4_debug ("orphan inode %llu will point to %d\n" , inode->i_ino,NEXT_ORPHAN (inode)); out:ext4_std_error (sb, err);
@@ -249,7 +249,7 @@ int ext4_orphan_del(handle_t *handle, struct inode *inode) }mutex_lock (&sbi->s_orphan_lock); -ext4_debug ("remove inode %lu from orphan list\n" , inode->i_ino); +ext4_debug ("remove inode %llu from orphan list\n" , inode->i_ino); prev = ei->i_orphan.prev;list_del_init (&ei->i_orphan);
@@ -284,7 +284,7 @@ int ext4_orphan_del(handle_t *handle, struct inode *inode)struct inode *i_prev = &list_entry(prev, struct ext4_inode_info, i_orphan)->vfs_inode; -ext4_debug ("orphan inode %lu will point to %u\n" , +ext4_debug ("orphan inode %llu will point to %u\n" , i_prev->i_ino, ino_next); err =ext4_reserve_inode_write (handle, i_prev, &iloc2);if (err) {
@@ -328,9 +328,9 @@ static void ext4_process_orphan(struct inode *inode,if (inode->i_nlink) {if (test_opt (sb,DEBUG ))ext4_msg (sb,KERN_DEBUG , -"%s: truncating inode %lu to %lld bytes" , +"%s: truncating inode %llu to %lld bytes" , __func__, inode->i_ino, inode->i_size); -ext4_debug ("truncating inode %lu to %lld bytes\n" , +ext4_debug ("truncating inode %llu to %lld bytes\n" , inode->i_ino, inode->i_size);inode_lock (inode);truncate_inode_pages (inode->i_mapping, inode->i_size);
@@ -349,9 +349,9 @@ static void ext4_process_orphan(struct inode *inode, }else {if (test_opt (sb,DEBUG ))ext4_msg (sb,KERN_DEBUG , -"%s: deleting unreferenced inode %lu" , +"%s: deleting unreferenced inode %llu" , __func__, inode->i_ino); -ext4_debug ("deleting unreferenced inode %lu\n" , +ext4_debug ("deleting unreferenced inode %llu\n" , inode->i_ino); (*nr_orphans)++; }
fs/ext4/page-io.c +5 -5
@@ -180,7 +180,7 @@ static int ext4_end_io_end(ext4_io_end_t *io_end)struct super_block *sb = inode->i_sb;int ret =0 ; -ext4_debug ("ext4_end_io_nolock: io_end 0x%p from inode %lu,list->next 0x%p," +ext4_debug ("ext4_end_io_nolock: io_end 0x%p from inode %llu,list->next 0x%p," "list->prev 0x%p\n" , io_end, inode->i_ino, io_end->list.next, io_end->list.prev);
@@ -204,7 +204,7 @@ static int ext4_end_io_end(ext4_io_end_t *io_end)ext4_msg (sb,KERN_EMERG ,"failed to convert unwritten extents to written " "extents -- potential data loss! " -"(inode %lu, error %d)" , inode->i_ino, ret); +"(inode %llu, error %d)" , inode->i_ino, ret); }ext4_clear_io_unwritten_flag (io_end);
@@ -221,7 +221,7 @@ static void dump_completed_IO(struct inode *inode, struct list_head *head)if (list_empty (head))return ; -ext4_debug ("Dump inode %lu completed io list\n" , inode->i_ino); +ext4_debug ("Dump inode %llu completed io list\n" , inode->i_ino);list_for_each_entry (io_end, head, list) { cur = &io_end->list; before = cur->prev;
@@ -229,7 +229,7 @@ static void dump_completed_IO(struct inode *inode, struct list_head *head) after = cur->next; io_end1 =container_of (after, ext4_io_end_t, list); -ext4_debug ("io 0x%p from inode %lu,prev 0x%p,next 0x%p\n" , +ext4_debug ("io 0x%p from inode %llu,prev 0x%p,next 0x%p\n" , io_end, inode->i_ino, io_end0, io_end1); }#endif
@@ -366,7 +366,7 @@ static void ext4_end_bio(struct bio *bio)if (bio->bi_status) {struct inode *inode = io_end->inode; - ext4_warning(inode->i_sb, "I/O error %d writing to inode %lu " + ext4_warning(inode->i_sb, "I/O error %d writing to inode %llu " "starting block %llu)", bio->bi_status, inode->i_ino, (unsigned long long)
fs/ext4/super.c +11 -11
@@ -848,12 +848,12 @@ void __ext4_error_inode(struct inode *inode, const char *function, vaf.va = &args;if (block)printk (KERN_CRIT "EXT4-fs error (device %s): %s:%d: " -"inode #%lu: block %llu: comm %s: %pV\n" , +"inode #%llu: block %llu: comm %s: %pV\n" , inode->i_sb->s_id, function, line, inode->i_ino, block, current->comm, &vaf);else printk (KERN_CRIT "EXT4-fs error (device %s): %s:%d: " -"inode #%lu: comm %s: %pV\n" , +"inode #%llu: comm %s: %pV\n" , inode->i_sb->s_id, function, line, inode->i_ino, current->comm, &vaf);va_end (args);
@@ -888,13 +888,13 @@ void __ext4_error_file(struct file *file, const char *function, vaf.va = &args;if (block)printk (KERN_CRIT -"EXT4-fs error (device %s): %s:%d: inode #%lu: " +"EXT4-fs error (device %s): %s:%d: inode #%llu: " "block %llu: comm %s: path %s: %pV\n" , inode->i_sb->s_id, function, line, inode->i_ino, block, current->comm, path, &vaf);else printk (KERN_CRIT -"EXT4-fs error (device %s): %s:%d: inode #%lu: " +"EXT4-fs error (device %s): %s:%d: inode #%llu: " "comm %s: path %s: %pV\n" , inode->i_sb->s_id, function, line, inode->i_ino, current->comm, path, &vaf);
@@ -1035,14 +1035,14 @@ void __ext4_warning_inode(const struct inode *inode, const char *function, vaf.fmt = fmt; vaf.va = &args;printk (KERN_WARNING "EXT4-fs warning (device %s): %s:%d: " -"inode #%lu: comm %s: %pV\n" , inode->i_sb->s_id, +"inode #%llu: comm %s: %pV\n" , inode->i_sb->s_id, function, line, inode->i_ino, current->comm, &vaf);va_end (args); } void __ext4_grp_locked_error(const char *function, unsigned int line, struct super_block *sb, ext4_group_t grp, - unsigned long ino, ext4_fsblk_t block, + u64 ino, ext4_fsblk_t block, const char *fmt, ...) __releases(bitlock) __acquires(bitlock)
@@ -1061,7 +1061,7 @@ __acquires(bitlock)printk (KERN_CRIT "EXT4-fs error (device %s): %s:%d: group %u, " , sb->s_id, function, line, grp);if (ino) -printk (KERN_CONT "inode %lu: " , ino); +printk (KERN_CONT "inode %llu: " , ino);if (block)printk (KERN_CONT "block %llu:" , (unsigned long long ) block);
@@ -1170,7 +1170,7 @@ static void dump_orphan_list(struct super_block *sb, struct ext4_sb_info *sbi)list_for_each (l, &sbi->s_orphan) {struct inode *inode =orphan_list_entry (l);printk (KERN_ERR " " -"inode %s:%lu at %p: mode %o, nlink %d, next %d\n" , +"inode %s:%llu at %p: mode %o, nlink %d, next %d\n" , inode->i_sb->s_id, inode->i_ino, inode, inode->i_mode, inode->i_nlink,NEXT_ORPHAN (inode));
@@ -1446,7 +1446,7 @@ static void ext4_free_in_core_inode(struct inode *inode) {fscrypt_free_inode (inode);if (!list_empty (&(EXT4_I (inode)->i_fc_list))) { -pr_warn ("%s: inode %ld still in fc list" , +pr_warn ("%s: inode %llu still in fc list" , __func__, inode->i_ino); }kmem_cache_free (ext4_inode_cachep,EXT4_I (inode));
@@ -1456,7 +1456,7 @@ static void ext4_destroy_inode(struct inode *inode) {if (ext4_inode_orphan_tracked (inode)) {ext4_msg (inode->i_sb,KERN_ERR , -"Inode %lu (%p): inode tracked as orphan!" , +"Inode %llu (%p): inode tracked as orphan!" , inode->i_ino,EXT4_I (inode)); print_hex_dump(KERN_INFO, "", DUMP_PREFIX_ADDRESS, 16, 4, EXT4_I(inode), sizeof(struct ext4_inode_info),
@@ -1467,7 +1467,7 @@ static void ext4_destroy_inode(struct inode *inode)if (!(EXT4_SB (inode->i_sb)->s_mount_state &EXT4_ERROR_FS ) &&WARN_ON_ONCE (EXT4_I (inode)->i_reserved_data_blocks))ext4_msg (inode->i_sb,KERN_ERR , -"Inode %lu (%p): i_reserved_data_blocks (%u) not cleared!" , +"Inode %llu (%p): i_reserved_data_blocks (%u) not cleared!" , inode->i_ino,EXT4_I (inode),EXT4_I (inode)->i_reserved_data_blocks); }
fs/ext4/xattr.c +5 -5
@@ -64,7 +64,7 @@#ifdef EXT4_XATTR_DEBUG # define ea_idebug (inode, fmt, ...) \ - printk(KERN_DEBUG "inode %s:%lu: " fmt "\n", \ + printk(KERN_DEBUG "inode %s:%llu: " fmt "\n", \ inode->i_sb->s_id, inode->i_ino, ##__VA_ARGS__)# define ea_bdebug (bh, fmt, ...) \ printk(KERN_DEBUG "block %pg:%lu: " fmt "\n", \
@@ -1035,7 +1035,7 @@ static int ext4_xattr_inode_update_ref(handle_t *handle, struct inode *ea_inode, ref_count =ext4_xattr_inode_get_ref (ea_inode);if ((ref_count ==0 && ref_change <0 ) || (ref_count ==U64_MAX && ref_change >0 )) {ext4_error_inode (ea_inode, __func__, __LINE__,0 , -"EA inode %lu ref wraparound: ref_count=%lld ref_change=%d" , +"EA inode %llu ref wraparound: ref_count=%lld ref_change=%d" , ea_inode->i_ino, ref_count, ref_change);brelse (iloc.bh); ret = -EFSCORRUPTED ;
@@ -1046,7 +1046,7 @@ static int ext4_xattr_inode_update_ref(handle_t *handle, struct inode *ea_inode,if (ref_change >0 ) {if (ref_count ==1 ) { -WARN_ONCE (ea_inode->i_nlink,"EA inode %lu i_nlink=%u" , +WARN_ONCE (ea_inode->i_nlink,"EA inode %llu i_nlink=%u" , ea_inode->i_ino, ea_inode->i_nlink);set_nlink (ea_inode,1 );
@@ -1055,7 +1055,7 @@ static int ext4_xattr_inode_update_ref(handle_t *handle, struct inode *ea_inode, }else {if (ref_count ==0 ) {WARN_ONCE (ea_inode->i_nlink !=1 , -"EA inode %lu i_nlink=%u" , +"EA inode %llu i_nlink=%u" , ea_inode->i_ino, ea_inode->i_nlink);clear_nlink (ea_inode);
@@ -2854,7 +2854,7 @@ int ext4_expand_extra_isize_ea(struct inode *inode, int new_extra_isize, cleanup:if (error && (mnt_count !=le16_to_cpu (sbi->s_es->s_mnt_count))) { -ext4_warning (inode->i_sb,"Unable to expand inode %lu. Delete some EAs or run e2fsck." , +ext4_warning (inode->i_sb,"Unable to expand inode %llu. Delete some EAs or run e2fsck." , inode->i_ino); mnt_count =le16_to_cpu (sbi->s_es->s_mnt_count); }
include/trace/events/ext4.h +214 -213
1,321 lines not on this page · raw message
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 5/61 jbd2: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate %lu to %llu in jbd2 debug/warning messages that print i_ino, since i_ino is now u64.
--- fs/jbd2/journal.c | 4 ++-- fs/jbd2/transaction.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-)
fs/jbd2/journal.c +2 -2
@@ -1677,7 +1677,7 @@ journal_t *jbd2_journal_init_inode(struct inode *inode)return err ?ERR_PTR (err) :ERR_PTR (-EINVAL ); } -jbd2_debug (1 ,"JBD2: inode %s/%ld, size %lld, bits %d, blksize %ld\n" , +jbd2_debug (1 ,"JBD2: inode %s/%lld, size %lld, bits %d, blksize %ld\n" , inode->i_sb->s_id, inode->i_ino, (long long ) inode->i_size, inode->i_sb->s_blocksize_bits, inode->i_sb->s_blocksize);
@@ -1689,7 +1689,7 @@ journal_t *jbd2_journal_init_inode(struct inode *inode) journal->j_inode = inode;snprintf (journal->j_devname,sizeof (journal->j_devname), -"%pg-%lu" , journal->j_dev, journal->j_inode->i_ino); +"%pg-%llu" , journal->j_dev, journal->j_inode->i_ino);strreplace (journal->j_devname,'/' ,'!' );jbd2_stats_proc_init (journal);
fs/jbd2/transaction.c +1 -1
@@ -2651,7 +2651,7 @@ static int jbd2_journal_file_inode(handle_t *handle, struct jbd2_inode *jinode,return -EROFS ; journal = transaction->t_journal; -jbd2_debug (4 ,"Adding inode %lu, tid:%d\n" , jinode->i_vfs_inode->i_ino, +jbd2_debug (4 ,"Adding inode %llu, tid:%d\n" , jinode->i_vfs_inode->i_ino, transaction->t_tid);spin_lock (&journal->j_list_lock);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 6/61 f2fs: update for u64 i_ino
In reply to Jeff LaytonUpdate f2fs trace events and filesystem code for u64 i_ino:
- Change __field(ino_t, ...) to __field(u64, ...) in trace events
- Update show_dev_ino() macro format strings from %lu to %llu
- Cast inode numbers to (unsigned long long) in TP_printk
- Update format string in fs/f2fs/node.c
--- fs/f2fs/compress.c | 4 +- fs/f2fs/dir.c | 2 +- fs/f2fs/extent_cache.c | 8 +-- fs/f2fs/f2fs.h | 6 +- fs/f2fs/file.c | 12 ++-- fs/f2fs/gc.c | 2 +- fs/f2fs/inline.c | 4 +- fs/f2fs/inode.c | 48 ++++++------- fs/f2fs/namei.c | 8 +-- fs/f2fs/node.c | 12 ++-- fs/f2fs/recovery.c | 10 +-- fs/f2fs/xattr.c | 10 +-- include/trace/events/f2fs.h | 172 ++++++++++++++++++++++---------------------- 13 files changed, 149 insertions(+), 149 deletions(-)
fs/f2fs/compress.c +2 -2
@@ -773,7 +773,7 @@ void f2fs_decompress_cluster(struct decompress_io_ctx *dic, bool in_task)if (!is_inode_flag_set (dic->inode,FI_COMPRESS_CORRUPT )) {set_inode_flag (dic->inode,FI_COMPRESS_CORRUPT );f2fs_info_ratelimited (sbi, -"checksum invalid, nid = %lu, %x vs %x" , +"checksum invalid, nid = %llu, %x vs %x" , dic->inode->i_ino, provided, calculated); }
@@ -932,7 +932,7 @@ bool f2fs_sanity_check_cluster(struct dnode_of_data *dn)return false; out: -f2fs_warn (sbi,"access invalid cluster, ino:%lu, nid:%u, ofs_in_node:%u, reason:%s" , +f2fs_warn (sbi,"access invalid cluster, ino:%llu, nid:%u, ofs_in_node:%u, reason:%s" , dn->inode->i_ino, dn->nid, dn->ofs_in_node, reason);set_sbi_flag (sbi,SBI_NEED_FSCK );return true;
fs/f2fs/dir.c +1 -1
@@ -368,7 +368,7 @@ struct f2fs_dir_entry *__f2fs_find_entry(struct inode *dir, max_depth =F2FS_I (dir)->i_current_depth;if (unlikely (max_depth >MAX_DIR_HASH_DEPTH )) { -f2fs_warn (F2FS_I_SB (dir),"Corrupted max_depth of %lu: %u" , +f2fs_warn (F2FS_I_SB (dir),"Corrupted max_depth of %llu: %u" , dir->i_ino, max_depth); max_depth =MAX_DIR_HASH_DEPTH ;f2fs_i_depth_write (dir, max_depth);
fs/f2fs/extent_cache.c +4 -4
@@ -34,7 +34,7 @@ bool sanity_check_extent_cache(struct inode *inode, struct folio *ifolio)if (!f2fs_is_valid_blkaddr (sbi, ei.blk,DATA_GENERIC_ENHANCE ) || !f2fs_is_valid_blkaddr (sbi, ei.blk + ei.len -1 ,DATA_GENERIC_ENHANCE )) { -f2fs_warn (sbi,"%s: inode (ino=%lx) extent info [%u, %u, %u] is incorrect, run fsck to fix" , +f2fs_warn (sbi,"%s: inode (ino=%llx) extent info [%u, %u, %u] is incorrect, run fsck to fix" , __func__, inode->i_ino, ei.blk, ei.fofs, ei.len);return false;
@@ -50,14 +50,14 @@ bool sanity_check_extent_cache(struct inode *inode, struct folio *ifolio)if (devi ==0 ) {f2fs_warn (sbi, -"%s: inode (ino=%lx) is an alias of meta device" , +"%s: inode (ino=%llx) is an alias of meta device" , __func__, inode->i_ino);return false; }if (bdev_is_zoned (FDEV (devi).bdev)) {f2fs_warn (sbi, -"%s: device alias inode (ino=%lx)'s extent info " +"%s: device alias inode (ino=%llx)'s extent info " "[%u, %u, %u] maps to zoned block device" , __func__, inode->i_ino, ei.blk, ei.fofs, ei.len);return false;
@@ -65,7 +65,7 @@ bool sanity_check_extent_cache(struct inode *inode, struct folio *ifolio)return true; } -f2fs_warn (sbi,"%s: device alias inode (ino=%lx)'s extent info " +f2fs_warn (sbi,"%s: device alias inode (ino=%llx)'s extent info " "[%u, %u, %u] is inconsistent w/ any devices" , __func__, inode->i_ino, ei.blk, ei.fofs, ei.len);return false;
fs/f2fs/f2fs.h +3 -3
@@ -2706,7 +2706,7 @@ static inline void dec_valid_block_count(struct f2fs_sb_info *sbi,spin_lock (&sbi->stat_lock);if (unlikely (sbi->total_valid_block_count < count)) { -f2fs_warn (sbi,"Inconsistent total_valid_block_count:%u, ino:%lu, count:%u" , +f2fs_warn (sbi,"Inconsistent total_valid_block_count:%u, ino:%llu, count:%u" , sbi->total_valid_block_count, inode->i_ino, count); sbi->total_valid_block_count =0 ;set_sbi_flag (sbi,SBI_NEED_FSCK );
@@ -2719,7 +2719,7 @@ static inline void dec_valid_block_count(struct f2fs_sb_info *sbi, sbi->current_reserved_blocks + count);spin_unlock (&sbi->stat_lock);if (unlikely (inode->i_blocks < sectors)) { -f2fs_warn (sbi,"Inconsistent i_blocks, ino:%lu, iblocks:%llu, sectors:%llu" , +f2fs_warn (sbi,"Inconsistent i_blocks, ino:%llu, iblocks:%llu, sectors:%llu" , inode->i_ino, (unsigned long long )inode->i_blocks, (unsigned long long )sectors);
@@ -2993,7 +2993,7 @@ static inline void dec_valid_node_count(struct f2fs_sb_info *sbi,dquot_free_inode (inode); }else {if (unlikely (inode->i_blocks ==0 )) { -f2fs_warn (sbi,"dec_valid_node_count: inconsistent i_blocks, ino:%lu, iblocks:%llu" , +f2fs_warn (sbi,"dec_valid_node_count: inconsistent i_blocks, ino:%llu, iblocks:%llu" , inode->i_ino, (unsigned long long )inode->i_blocks);set_sbi_flag (sbi,SBI_NEED_FSCK );
fs/f2fs/file.c +6 -6
@@ -1917,7 +1917,7 @@ static int f2fs_expand_inode_data(struct inode *inode, loff_t offset,f2fs_up_write (&sbi->pin_sem); err = -ENOSPC ;f2fs_warn_ratelimited (sbi, -"ino:%lu, start:%lu, end:%lu, need to trigger GC to " +"ino:%llu, start:%lu, end:%lu, need to trigger GC to" "reclaim enough free segment when checkpoint is enabled" , inode->i_ino, pg_start, pg_end); goto out_err;
@@ -2307,7 +2307,7 @@ static int f2fs_ioc_start_atomic_write(struct file *filp, bool truncate)* f2fs_is_atomic_file. */ if (get_dirty_pages (inode)) -f2fs_warn (sbi,"Unexpected flush for atomic writes: ino=%lu, npages=%u" , +f2fs_warn (sbi,"Unexpected flush for atomic writes: ino=%llu, npages=%u" , inode->i_ino,get_dirty_pages (inode)); ret =filemap_write_and_wait_range (inode->i_mapping,0 ,LLONG_MAX );if (ret)
@@ -3494,7 +3494,7 @@ int f2fs_pin_file_control(struct inode *inode, bool inc)return -EINVAL ;if (fi->i_gc_failures >= sbi->gc_pin_file_threshold) { -f2fs_warn (sbi,"%s: Enable GC = ino %lx after %x GC trials" , +f2fs_warn (sbi,"%s: Enable GC = ino %llx after %x GC trials" , __func__, inode->i_ino, fi->i_gc_failures);clear_inode_flag (inode,FI_PIN_FILE );return -EAGAIN ;
@@ -3679,7 +3679,7 @@ static int f2fs_ioc_enable_verity(struct file *filp, unsigned long arg)if (!f2fs_sb_has_verity (F2FS_I_SB (inode))) {f2fs_warn (F2FS_I_SB (inode), -"Can't enable fs-verity on inode %lu: the verity feature is not enabled on this filesystem" , +"Can't enable fs-verity on inode %llu: the verity feature is not enabled on this filesystem" , inode->i_ino);return -EOPNOTSUPP ; }
@@ -3950,7 +3950,7 @@ static int f2fs_release_compress_blocks(struct file *filp, unsigned long arg) }else if (released_blocks &&atomic_read (&fi->i_compr_blocks)) {set_sbi_flag (sbi,SBI_NEED_FSCK ); - f2fs_warn(sbi, "%s: partial blocks were released i_ino=%lx " + f2fs_warn(sbi, "%s: partial blocks were released i_ino=%llx " "iblocks=%llu, released=%u, compr_blocks=%u, " "run fsck to fix.", __func__, inode->i_ino, inode->i_blocks,
@@ -4133,7 +4133,7 @@ static int f2fs_reserve_compress_blocks(struct file *filp, unsigned long arg) }else if (reserved_blocks &&atomic_read (&fi->i_compr_blocks)) {set_sbi_flag (sbi,SBI_NEED_FSCK ); - f2fs_warn(sbi, "%s: partial blocks were reserved i_ino=%lx " + f2fs_warn(sbi, "%s: partial blocks were reserved i_ino=%llx " "iblocks=%llu, reserved=%u, compr_blocks=%u, " "run fsck to fix.", __func__, inode->i_ino, inode->i_blocks,
fs/f2fs/gc.c +1 -1
@@ -1622,7 +1622,7 @@ static int gc_data_segment(struct f2fs_sb_info *sbi, struct f2fs_summary *sum,iput (inode);set_sbi_flag (sbi,SBI_NEED_FSCK );f2fs_err_ratelimited (sbi, -"inode %lx has both inline_data flag and " +"inode %llu has both inline_data flag and " "data block, nid=%u, ofs_in_node=%u" , inode->i_ino, dni.nid, ofs_in_node);continue ;
fs/f2fs/inline.c +2 -2
@@ -176,7 +176,7 @@ int f2fs_convert_inline_folio(struct dnode_of_data *dn, struct folio *folio)if (unlikely (dn->data_blkaddr !=NEW_ADDR )) {f2fs_put_dnode (dn);set_sbi_flag (fio.sbi,SBI_NEED_FSCK ); -f2fs_warn (fio.sbi,"%s: corrupted inline inode ino=%lx, i_addr[0]:0x%x, run fsck to fix." , +f2fs_warn (fio.sbi,"%s: corrupted inline inode ino=%llu, i_addr[0]:0x%x, run fsck to fix." , __func__, dn->inode->i_ino, dn->data_blkaddr);f2fs_handle_error (fio.sbi,ERROR_INVALID_BLKADDR );return -EFSCORRUPTED ;
@@ -431,7 +431,7 @@ static int f2fs_move_inline_dirents(struct inode *dir, struct folio *ifolio,if (unlikely (dn.data_blkaddr !=NEW_ADDR )) {f2fs_put_dnode (&dn);set_sbi_flag (F2FS_F_SB (folio),SBI_NEED_FSCK ); -f2fs_warn (F2FS_F_SB (folio),"%s: corrupted inline inode ino=%lx, i_addr[0]:0x%x, run fsck to fix." , +f2fs_warn (F2FS_F_SB (folio),"%s: corrupted inline inode ino=%llu, i_addr[0]:0x%x, run fsck to fix." , __func__, dir->i_ino, dn.data_blkaddr);f2fs_handle_error (F2FS_F_SB (folio),ERROR_INVALID_BLKADDR ); err = -EFSCORRUPTED ;
fs/f2fs/inode.c +24 -24
177 lines not on this page · raw message
fs/f2fs/namei.c +4 -4
@@ -505,7 +505,7 @@ static struct dentry *f2fs_lookup(struct inode *dir, struct dentry *dentry, }if (inode->i_nlink ==0 ) { -f2fs_warn (F2FS_I_SB (inode),"%s: inode (ino=%lx) has zero i_nlink" , +f2fs_warn (F2FS_I_SB (inode),"%s: inode (ino=%llx) has zero i_nlink" , __func__, inode->i_ino); err = -EFSCORRUPTED ;set_sbi_flag (F2FS_I_SB (inode),SBI_NEED_FSCK );
@@ -515,7 +515,7 @@ static struct dentry *f2fs_lookup(struct inode *dir, struct dentry *dentry,if (IS_ENCRYPTED (dir) && (S_ISDIR (inode->i_mode) ||S_ISLNK (inode->i_mode)) && !fscrypt_has_permitted_context (dir, inode)) { -f2fs_warn (F2FS_I_SB (inode),"Inconsistent encryption contexts: %lu/%lu" , +f2fs_warn (F2FS_I_SB (inode),"Inconsistent encryption contexts: %llu/%llu" , dir->i_ino, inode->i_ino); err = -EPERM ; goto out_iput;
@@ -573,11 +573,11 @@ static int f2fs_unlink(struct inode *dir, struct dentry *dentry) }if (unlikely (inode->i_nlink ==0 )) { -f2fs_warn (sbi,"%s: inode (ino=%lx) has zero i_nlink" , +f2fs_warn (sbi,"%s: inode (ino=%llx) has zero i_nlink" , __func__, inode->i_ino); goto corrupted; }else if (S_ISDIR (inode->i_mode) &&unlikely (inode->i_nlink ==1 )) { -f2fs_warn (sbi,"%s: directory inode (ino=%lx) has a single i_nlink" , +f2fs_warn (sbi,"%s: directory inode (ino=%llx) has a single i_nlink" , __func__, inode->i_ino); goto corrupted; }
fs/f2fs/node.c +6 -6
@@ -847,7 +847,7 @@ int f2fs_get_dnode_of_data(struct dnode_of_data *dn, pgoff_t index, int mode) err = -EFSCORRUPTED ;f2fs_err_ratelimited (sbi,"inode mapping table is corrupted, run fsck to fix it, " -"ino:%lu, nid:%u, level:%d, offset:%d" , +"ino:%llu, nid:%u, level:%d, offset:%d" , dn->inode->i_ino, nids[i], level, offset[level]);set_sbi_flag (sbi,SBI_NEED_FSCK ); goto release_pages;
@@ -1013,7 +1013,7 @@ static int truncate_dnode(struct dnode_of_data *dn)return PTR_ERR (folio);if (IS_INODE (folio) ||ino_of_node (folio) != dn->inode->i_ino) { -f2fs_err (sbi,"incorrect node reference, ino: %lu, nid: %u, ino_of_node: %u" , +f2fs_err (sbi,"incorrect node reference, ino: %llu, nid: %u, ino_of_node: %u" , dn->inode->i_ino, dn->nid,ino_of_node (folio));set_sbi_flag (sbi,SBI_NEED_FSCK );f2fs_handle_error (sbi,ERROR_INVALID_NODE_REFERENCE );
@@ -1194,7 +1194,7 @@ int f2fs_truncate_inode_blocks(struct inode *inode, pgoff_t from)if (level <=0 ) {if (!level) { level = -EFSCORRUPTED ; -f2fs_err (sbi,"%s: inode ino=%lx has corrupted node block, from:%lu addrs:%u" , +f2fs_err (sbi,"%s: inode ino=%llx has corrupted node block, from:%lu addrs:%u" , __func__, inode->i_ino, from,ADDRS_PER_INODE (inode));set_sbi_flag (sbi,SBI_NEED_FSCK );
@@ -1265,7 +1265,7 @@ int f2fs_truncate_inode_blocks(struct inode *inode, pgoff_t from)set_sbi_flag (F2FS_F_SB (folio),SBI_NEED_FSCK );f2fs_handle_error (sbi,ERROR_INVALID_BLKADDR );f2fs_err_ratelimited (sbi, -"truncate node fail, ino:%lu, nid:%u, " +"truncate node fail, ino:%llu, nid:%u, " "offset[0]:%d, offset[1]:%d, nofs:%d" , inode->i_ino, dn.nid, offset[0 ], offset[1 ], nofs);
@@ -1351,7 +1351,7 @@ int f2fs_remove_inode_page(struct inode *inode)if (unlikely (inode->i_blocks !=0 && inode->i_blocks !=8 )) {f2fs_warn (F2FS_I_SB (inode), -"f2fs_remove_inode_page: inconsistent i_blocks, ino:%lu, iblocks:%llu" , +"f2fs_remove_inode_page: inconsistent i_blocks, ino:%llu, iblocks:%llu" , inode->i_ino, (unsigned long long )inode->i_blocks);set_sbi_flag (F2FS_I_SB (inode),SBI_NEED_FSCK ); }
@@ -1997,7 +1997,7 @@ int f2fs_fsync_node_pages(struct f2fs_sb_info *sbi, struct inode *inode,return ret; } -static int f2fs_match_ino (struct inode *inode,unsigned long ino,void *data) +static int f2fs_match_ino (struct inode *inode,u64 ino,void *data) {struct f2fs_sb_info *sbi =F2FS_I_SB (inode);bool clean;
fs/f2fs/recovery.c +5 -5
@@ -232,7 +232,7 @@ static int recover_dentry(struct inode *inode, struct folio *ifolio, name ="<encrypted>" ; else name = raw_inode->i_name; -f2fs_notice (F2FS_I_SB (inode),"%s: ino = %x, name = %s, dir = %lx, err = %d" , +f2fs_notice (F2FS_I_SB (inode),"%s: ino = %x, name = %s, dir = %llu, err = %d" , __func__,ino_of_node (ifolio), name,IS_ERR (dir) ?0 : dir->i_ino, err);return err;
@@ -532,7 +532,7 @@ static int check_index_in_prev_nodes(struct f2fs_sb_info *sbi, max_addrs =ADDRS_PER_PAGE (dn->node_folio, dn->inode);if (ofs_in_node >= max_addrs) { -f2fs_err (sbi,"Inconsistent ofs_in_node:%u in summary, ino:%lu, nid:%u, max:%u" , +f2fs_err (sbi,"Inconsistent ofs_in_node:%u in summary, ino:%llu, nid:%u, max:%u" , ofs_in_node, dn->inode->i_ino, nid, max_addrs);f2fs_handle_error (sbi,ERROR_INCONSISTENT_SUMMARY );return -EFSCORRUPTED ;
@@ -674,7 +674,7 @@ static int do_recover_data(struct f2fs_sb_info *sbi, struct inode *inode,f2fs_bug_on (sbi, ni.ino !=ino_of_node (folio));if (ofs_of_node (dn.node_folio) !=ofs_of_node (folio)) { -f2fs_warn (sbi,"Inconsistent ofs_of_node, ino:%lu, ofs:%u, %u" , +f2fs_warn (sbi,"Inconsistent ofs_of_node, ino:%llu, ofs:%u, %u" , inode->i_ino,ofs_of_node (dn.node_folio),ofs_of_node (folio)); err = -EFSCORRUPTED ;
@@ -748,7 +748,7 @@ static int do_recover_data(struct f2fs_sb_info *sbi, struct inode *inode,if (f2fs_is_valid_blkaddr (sbi, dest,DATA_GENERIC_ENHANCE_UPDATE )) { -f2fs_err (sbi,"Inconsistent dest blkaddr:%u, ino:%lu, ofs:%u" , +f2fs_err (sbi,"Inconsistent dest blkaddr:%u, ino:%llu, ofs:%u" , dest, inode->i_ino, dn.ofs_in_node); err = -EFSCORRUPTED ; goto err;
@@ -768,7 +768,7 @@ static int do_recover_data(struct f2fs_sb_info *sbi, struct inode *inode, err:f2fs_put_dnode (&dn); out: - f2fs_notice(sbi, "recover_data: ino = %lx, nid = %x (i_size: %s), " + f2fs_notice(sbi, "recover_data: ino = %llx, nid = %x (i_size: %s), " "range (%u, %u), recovered = %d, err = %d", inode->i_ino, nid_of_node(folio), file_keep_isize(inode) ? "keep" : "recover",
fs/f2fs/xattr.c +5 -5
@@ -365,7 +365,7 @@ static int lookup_all_xattrs(struct inode *inode, struct folio *ifolio, *xe =__find_xattr (cur_addr, last_txattr_addr,NULL , index, len, name);if (!*xe) { -f2fs_err (F2FS_I_SB (inode),"lookup inode (%lu) has corrupted xattr" , +f2fs_err (F2FS_I_SB (inode),"lookup inode (%llu) has corrupted xattr" , inode->i_ino);set_sbi_flag (F2FS_I_SB (inode),SBI_NEED_FSCK ); err = -ENODATA ;
@@ -585,7 +585,7 @@ ssize_t f2fs_listxattr(struct dentry *dentry, char *buffer, size_t buffer_size)if ((void *)(entry) +sizeof (__u32) > last_base_addr || (void *)XATTR_NEXT_ENTRY (entry) > last_base_addr) { -f2fs_err (F2FS_I_SB (inode),"list inode (%lu) has corrupted xattr" , +f2fs_err (F2FS_I_SB (inode),"list inode (%llu) has corrupted xattr" , inode->i_ino);set_sbi_flag (F2FS_I_SB (inode),SBI_NEED_FSCK ); f2fs_handle_error(F2FS_I_SB(inode),
@@ -664,14 +664,14 @@ static int __f2fs_setxattr(struct inode *inode, int index,if (!F2FS_I (inode)->i_xattr_nid) { error =f2fs_recover_xattr_data (inode,NULL );f2fs_notice (F2FS_I_SB (inode), -"recover xattr in inode (%lu), error(%d)" , +"recover xattr in inode (%llu), error(%d)" , inode->i_ino, error);if (!error) {kfree (base_addr); goto retry; } } -f2fs_err (F2FS_I_SB (inode),"set inode (%lu) has corrupted xattr" , +f2fs_err (F2FS_I_SB (inode),"set inode (%llu) has corrupted xattr" , inode->i_ino);set_sbi_flag (F2FS_I_SB (inode),SBI_NEED_FSCK ); error = -EFSCORRUPTED ;
@@ -699,7 +699,7 @@ static int __f2fs_setxattr(struct inode *inode, int index,while (!IS_XATTR_LAST_ENTRY (last)) {if ((void *)(last) +sizeof (__u32) > last_base_addr || (void *)XATTR_NEXT_ENTRY (last) > last_base_addr) { -f2fs_err (F2FS_I_SB (inode),"inode (%lu) has invalid last xattr entry, entry_size: %zu" , +f2fs_err (F2FS_I_SB (inode),"inode (%llu) has invalid last xattr entry, entry_size: %zu" , inode->i_ino,ENTRY_SIZE (last));set_sbi_flag (F2FS_I_SB (inode),SBI_NEED_FSCK ); error = -EFSCORRUPTED ;
include/trace/events/f2fs.h +86 -86
651 lines not on this page · raw message
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 7/61 lockd: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings from %ld/%lu to %lld/%llu for i_ino, which is now a u64.
--- fs/lockd/svclock.c | 8 ++++---- fs/lockd/svcsubs.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-)
fs/lockd/svclock.c +4 -4
@@ -487,7 +487,7 @@ nlmsvc_lock(struct svc_rqst *rqstp, struct nlm_file *file,int async_block =0 ;__be32 ret; - dprintk("lockd: nlmsvc_lock(%s/%ld, ty=%d, pi=%d, %Ld-%Ld, bl=%d)\n", + dprintk("lockd: nlmsvc_lock(%s/%lld, ty=%d, pi=%d, %Ld-%Ld, bl=%d)\n", inode->i_sb->s_id, inode->i_ino, lock->fl.c.flc_type, lock->fl.c.flc_pid,
@@ -617,7 +617,7 @@ nlmsvc_testlock(struct svc_rqst *rqstp, struct nlm_file *file,int mode;__be32 ret; - dprintk("lockd: nlmsvc_testlock(%s/%ld, ty=%d, %Ld-%Ld)\n", + dprintk("lockd: nlmsvc_testlock(%s/%lld, ty=%d, %Ld-%Ld)\n", nlmsvc_file_inode(file)->i_sb->s_id, nlmsvc_file_inode(file)->i_ino, lock->fl.c.flc_type,
@@ -676,7 +676,7 @@ nlmsvc_unlock(struct net *net, struct nlm_file *file, struct nlm_lock *lock) {int error =0 ; - dprintk("lockd: nlmsvc_unlock(%s/%ld, pi=%d, %Ld-%Ld)\n", + dprintk("lockd: nlmsvc_unlock(%s/%lld, pi=%d, %Ld-%Ld)\n", nlmsvc_file_inode(file)->i_sb->s_id, nlmsvc_file_inode(file)->i_ino, lock->fl.c.flc_pid,
@@ -716,7 +716,7 @@ nlmsvc_cancel_blocked(struct net *net, struct nlm_file *file, struct nlm_lock *lint status =0 ;int mode; - dprintk("lockd: nlmsvc_cancel(%s/%ld, pi=%d, %Ld-%Ld)\n", + dprintk("lockd: nlmsvc_cancel(%s/%lld, pi=%d, %Ld-%Ld)\n", nlmsvc_file_inode(file)->i_sb->s_id, nlmsvc_file_inode(file)->i_ino, lock->fl.c.flc_pid,
fs/lockd/svcsubs.c +1 -1
@@ -47,7 +47,7 @@ static inline void nlm_debug_print_file(char *msg, struct nlm_file *file) {struct inode *inode =nlmsvc_file_inode (file); -dprintk ("lockd: %s %s/%ld\n" , +dprintk ("lockd: %s %s/%llu\n" , msg, inode->i_sb->s_id, inode->i_ino); }#else
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 8/61 nfs: update for u64 i_ino
In reply to Jeff LaytonUpdate NFS for u64 i_ino:
- Simplify nfs_fileid_to_ino_t() to return u64 directly, since i_ino can now store a full 64-bit fileid without folding on 32-bit
- Update nfs_fattr_to_ino_t() to return u64
- Update format strings from %lu/%lx to %llu/%llx
- Remove unnecessary (unsigned long) casts on i_ino
--- fs/nfs/dir.c | 20 ++++++++++---------- fs/nfs/file.c | 8 ++++---- fs/nfs/filelayout/filelayout.c | 8 ++++---- fs/nfs/flexfilelayout/flexfilelayout.c | 8 ++++---- fs/nfs/inode.c | 10 +++++----- fs/nfs/nfs4proc.c | 4 ++-- fs/nfs/pnfs.c | 12 ++++++------ include/linux/nfs_fs.h | 7 ++----- 8 files changed, 37 insertions(+), 40 deletions(-)
fs/nfs/dir.c +10 -10
@@ -1906,7 +1906,7 @@ static int nfs_weak_revalidate(struct dentry *dentry, unsigned int flags) } error =nfs_lookup_verify_inode (inode, flags); -dfprintk (LOOKUPCACHE ,"NFS: %s: inode %lu is %s\n" , +dfprintk (LOOKUPCACHE ,"NFS: %s: inode %llu is %s\n" , __func__, inode->i_ino, error ?"invalid" :"valid" );return !error; }
@@ -2121,7 +2121,7 @@ int nfs_atomic_open(struct inode *dir, struct dentry *dentry,/* Expect a negative dentry */ BUG_ON (d_inode (dentry)); -dfprintk (VFS ,"NFS: atomic_open(%s/%lu), %pd\n" , +dfprintk (VFS ,"NFS: atomic_open(%s/%llu), %pd\n" , dir->i_sb->s_id, dir->i_ino, dentry); err =nfs_check_flags (open_flags);
@@ -2404,7 +2404,7 @@ static int nfs_do_create(struct inode *dir, struct dentry *dentry, open_flags |=O_CREAT ; -dfprintk (VFS ,"NFS: create(%s/%lu), %pd\n" , +dfprintk (VFS ,"NFS: create(%s/%llu), %pd\n" , dir->i_sb->s_id, dir->i_ino, dentry); attr.ia_mode = mode;
@@ -2442,7 +2442,7 @@ nfs_mknod(struct mnt_idmap *idmap, struct inode *dir,struct iattr attr;int status; -dfprintk (VFS ,"NFS: mknod(%s/%lu), %pd\n" , +dfprintk (VFS ,"NFS: mknod(%s/%llu), %pd\n" , dir->i_sb->s_id, dir->i_ino, dentry); attr.ia_mode = mode;
@@ -2469,7 +2469,7 @@ struct dentry *nfs_mkdir(struct mnt_idmap *idmap, struct inode *dir,struct iattr attr;struct dentry *ret; -dfprintk (VFS ,"NFS: mkdir(%s/%lu), %pd\n" , +dfprintk (VFS ,"NFS: mkdir(%s/%llu), %pd\n" , dir->i_sb->s_id, dir->i_ino, dentry); attr.ia_valid =ATTR_MODE ;
@@ -2507,7 +2507,7 @@ int nfs_rmdir(struct inode *dir, struct dentry *dentry) {int error; -dfprintk (VFS ,"NFS: rmdir(%s/%lu), %pd\n" , +dfprintk (VFS ,"NFS: rmdir(%s/%llu), %pd\n" , dir->i_sb->s_id, dir->i_ino, dentry);trace_nfs_rmdir_enter (dir, dentry);
@@ -2578,7 +2578,7 @@ int nfs_unlink(struct inode *dir, struct dentry *dentry) {int error; -dfprintk (VFS ,"NFS: unlink(%s/%lu, %pd)\n" , dir->i_sb->s_id, +dfprintk (VFS ,"NFS: unlink(%s/%llu, %pd)\n" , dir->i_sb->s_id, dir->i_ino, dentry);trace_nfs_unlink_enter (dir, dentry);
@@ -2638,7 +2638,7 @@ int nfs_symlink(struct mnt_idmap *idmap, struct inode *dir,unsigned int pathlen =strlen (symname);int error; -dfprintk (VFS ,"NFS: symlink(%s/%lu, %pd, %s)\n" , dir->i_sb->s_id, +dfprintk (VFS ,"NFS: symlink(%s/%llu, %pd, %s)\n" , dir->i_sb->s_id, dir->i_ino, dentry, symname);if (pathlen >PAGE_SIZE )
@@ -2660,7 +2660,7 @@ int nfs_symlink(struct mnt_idmap *idmap, struct inode *dir, error =NFS_PROTO (dir)->symlink (dir, dentry, folio, pathlen, &attr);trace_nfs_symlink_exit (dir, dentry, error);if (error !=0 ) { -dfprintk (VFS ,"NFS: symlink(%s/%lu, %pd, %s) error %d\n" , +dfprintk (VFS ,"NFS: symlink(%s/%llu, %pd, %s) error %d\n" , dir->i_sb->s_id, dir->i_ino, dentry, symname, error);d_drop (dentry);
@@ -3414,7 +3414,7 @@ int nfs_permission(struct mnt_idmap *idmap,if (!res && (mask &MAY_EXEC )) res =nfs_execute_ok (inode, mask); -dfprintk (VFS ,"NFS: permission(%s/%lu), mask=0x%x, res=%d\n" , +dfprintk (VFS ,"NFS: permission(%s/%llu), mask=0x%x, res=%d\n" , inode->i_sb->s_id, inode->i_ino, mask, res);return res; out_notsup:
fs/nfs/file.c +4 -4
@@ -391,7 +391,7 @@ static int nfs_write_begin(const struct kiocb *iocb,trace_nfs_write_begin (file_inode (file), pos, len); -dfprintk (PAGECACHE ,"NFS: write_begin(%pD2(%lu), %u@%lld)\n" , +dfprintk (PAGECACHE ,"NFS: write_begin(%pD2(%llu), %u@%lld)\n" , file, mapping->host->i_ino, len, (long long ) pos);nfs_truncate_last_folio (mapping,i_size_read (mapping->host), pos);
@@ -432,7 +432,7 @@ static int nfs_write_end(const struct kiocb *iocb,int status;trace_nfs_write_end (file_inode (file), pos, len); -dfprintk (PAGECACHE ,"NFS: write_end(%pD2(%lu), %u@%lld)\n" , +dfprintk (PAGECACHE ,"NFS: write_end(%pD2(%llu), %u@%lld)\n" , file, mapping->host->i_ino, len, (long long ) pos);/*
@@ -557,7 +557,7 @@ static int nfs_launder_folio(struct folio *folio)struct inode *inode = folio->mapping->host;int ret; -dfprintk (PAGECACHE ,"NFS: launder_folio(%ld, %llu)\n" , +dfprintk (PAGECACHE ,"NFS: launder_folio(%llu, %llu)\n" , inode->i_ino,folio_pos (folio));folio_wait_private_2 (folio);/* [DEPRECATED] */
@@ -647,7 +647,7 @@ static vm_fault_t nfs_vm_page_mkwrite(struct vm_fault *vmf)struct address_space *mapping;struct folio *folio =page_folio (vmf->page); -dfprintk (PAGECACHE ,"NFS: vm_page_mkwrite(%pD2(%lu), offset %lld)\n" , +dfprintk (PAGECACHE ,"NFS: vm_page_mkwrite(%pD2(%llu), offset %lld)\n" , filp, filp->f_mapping->host->i_ino, (long long )folio_pos (folio));
fs/nfs/filelayout/filelayout.c +4 -4
@@ -241,7 +241,7 @@ filelayout_set_layoutcommit(struct nfs_pgio_header *hdr)/* Note: if the write is unstable, don't set end_offs until commit */ pnfs_set_layoutcommit (hdr->inode, hdr->lseg, end_offs); -dprintk ("%s inode %lu pls_end_pos %lu\n" , __func__, hdr->inode->i_ino, +dprintk ("%s inode %llu pls_end_pos %lu\n" , __func__, hdr->inode->i_ino, (unsigned long )NFS_I (hdr->inode)->layout->plh_lwb); }
@@ -456,7 +456,7 @@ filelayout_read_pagelist(struct nfs_pgio_header *hdr)u32 j, idx;struct nfs_fh *fh; -dprintk ("--> %s ino %lu pgbase %u req %zu@%llu\n" , +dprintk ("--> %s ino %llu pgbase %u req %zu@%llu\n" , __func__, hdr->inode->i_ino, hdr->args.pgbase, (size_t )hdr->args.count, offset);
@@ -514,7 +514,7 @@ filelayout_write_pagelist(struct nfs_pgio_header *hdr, int sync)if (IS_ERR (ds_clnt))return PNFS_NOT_ATTEMPTED ; -dprintk ("%s ino %lu sync %d req %zu@%llu DS: %s cl_count %d\n" , +dprintk ("%s ino %llu sync %d req %zu@%llu DS: %s cl_count %d\n" , __func__, hdr->inode->i_ino, sync, (size_t ) hdr->args.count, offset, ds->ds_remotestr,refcount_read (&ds->ds_clp->cl_count));
@@ -1001,7 +1001,7 @@ static int filelayout_initiate_commit(struct nfs_commit_data *data, int how)if (IS_ERR (ds_clnt)) goto out_err; -dprintk ("%s ino %lu, how %d cl_count %d\n" , __func__, +dprintk ("%s ino %llu, how %d cl_count %d\n" , __func__, data->inode->i_ino, how,refcount_read (&ds->ds_clp->cl_count)); data->commit_done_cb = filelayout_commit_done_cb;refcount_inc (&ds->ds_clp->cl_count);
fs/nfs/flexfilelayout/flexfilelayout.c +4 -4
@@ -1631,7 +1631,7 @@ ff_layout_set_layoutcommit(struct inode *inode,return ;pnfs_set_layoutcommit (inode, lseg, end_offset); -dprintk ("%s inode %lu pls_end_pos %llu\n" , __func__, inode->i_ino, +dprintk ("%s inode %llu pls_end_pos %llu\n" , __func__, inode->i_ino, (unsigned long long )NFS_I (inode)->layout->plh_lwb); }
@@ -2136,7 +2136,7 @@ ff_layout_read_pagelist(struct nfs_pgio_header *hdr)u32 dss_id;bool ds_fatal_error = false; -dprintk ("--> %s ino %lu pgbase %u req %zu@%llu\n" , +dprintk ("--> %s ino %llu pgbase %u req %zu@%llu\n" , __func__, hdr->inode->i_ino, hdr->args.pgbase, (size_t )hdr->args.count, offset);
@@ -2245,7 +2245,7 @@ ff_layout_write_pagelist(struct nfs_pgio_header *hdr, int sync) vers =nfs4_ff_layout_ds_version (mirror, dss_id); -dprintk ("%s ino %lu sync %d req %zu@%llu DS: %s cl_count %d vers %d\n" , +dprintk ("%s ino %llu sync %d req %zu@%llu DS: %s cl_count %d vers %d\n" , __func__, hdr->inode->i_ino, sync, (size_t ) hdr->args.count, offset, ds->ds_remotestr,refcount_read (&ds->ds_clp->cl_count), vers);
@@ -2336,7 +2336,7 @@ static int ff_layout_initiate_commit(struct nfs_commit_data *data, int how) vers =nfs4_ff_layout_ds_version (mirror, dss_id); -dprintk ("%s ino %lu, how %d cl_count %d vers %d\n" , __func__, +dprintk ("%s ino %llu, how %d cl_count %d vers %d\n" , __func__, data->inode->i_ino, how,refcount_read (&ds->ds_clp->cl_count), vers); data->commit_done_cb = ff_layout_commit_done_cb;
fs/nfs/inode.c +5 -5
@@ -66,10 +66,10 @@ static int nfs_update_inode(struct inode *, struct nfs_fattr *);static struct kmem_cache * nfs_inode_cachep; -static inline unsigned long +static inline u64 nfs_fattr_to_ino_t (struct nfs_fattr *fattr) { -return nfs_fileid_to_ino_t (fattr->fileid); +return fattr->fileid; }int nfs_wait_bit_killable (struct wait_bit_key *key,int mode)
@@ -2258,7 +2258,7 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)bool attr_changed = false;bool have_delegation; -dfprintk (VFS ,"NFS: %s(%s/%lu fh_crc=0x%08x ct=%d info=0x%llx)\n" , +dfprintk (VFS ,"NFS: %s(%s/%llu fh_crc=0x%08x ct=%d info=0x%llx)\n" , __func__, inode->i_sb->s_id, inode->i_ino,nfs_display_fhandle_hash (NFS_FH (inode)),icount_read (inode), fattr->valid);
@@ -2288,7 +2288,7 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)/* * Big trouble! The inode has become a different object. */ -printk (KERN_DEBUG "NFS: %s: inode %lu mode changed, %07o to %07o\n" , +printk (KERN_DEBUG "NFS: %s: inode %llu mode changed, %07o to %07o\n" , __func__, inode->i_ino, inode->i_mode, fattr->mode); goto out_err; }
@@ -2358,7 +2358,7 @@ static int nfs_update_inode(struct inode *inode, struct nfs_fattr *fattr)if (S_ISDIR (inode->i_mode))nfs_force_lookup_revalidate (inode); attr_changed = true; -dprintk ("NFS: change_attr change on server for file %s/%ld\n" , +dprintk ("NFS: change_attr change on server for file %s/%lld\n" , inode->i_sb->s_id, inode->i_ino); }else if (!have_delegation) {
fs/nfs/nfs4proc.c +2 -2
@@ -4714,7 +4714,7 @@ static int _nfs4_proc_lookupp(struct inode *inode,nfs_fattr_init (fattr);nfs4_init_sequence (server->nfs_client, &args.seq_args, &res.seq_res,0 ,0 ); -dprintk ("NFS call lookupp ino=0x%lx\n" , inode->i_ino); +dprintk ("NFS call lookupp ino=0x%llx\n" , inode->i_ino); status =nfs4_do_call_sync (clnt, server, &msg, &args.seq_args, &res.seq_res, task_flags);dprintk ("NFS reply lookupp: %d\n" , status);
@@ -10019,7 +10019,7 @@ nfs4_proc_layoutcommit(struct nfs4_layoutcommit_data *data, bool sync)int status =0 ;dprintk ("NFS: initiating layoutcommit call. sync %d " -"lbw: %llu inode %lu\n" , sync, +"lbw: %llu inode %llu\n" , sync, data->args.lastbytewritten, data->args.inode->i_ino);
fs/nfs/pnfs.c +6 -6
@@ -891,7 +891,7 @@ pnfs_layout_free_bulk_destroy_list(struct list_head *layout_list,while (!list_empty (layout_list)) { lo = list_entry(layout_list->next, struct pnfs_layout_hdr, plh_bulk_destroy); -dprintk ("%s freeing layout for inode %lu\n" , __func__, +dprintk ("%s freeing layout for inode %llu\n" , __func__, lo->plh_inode->i_ino); inode = lo->plh_inode;
@@ -1440,7 +1440,7 @@ _pnfs_return_layout(struct inode *ino)int status =0 ;bool send, valid_layout; -dprintk ("NFS: %s for inode %lu\n" , __func__, ino->i_ino); +dprintk ("NFS: %s for inode %llu\n" , __func__, ino->i_ino);spin_lock (&ino->i_lock); lo = nfsi->layout;
@@ -3055,7 +3055,7 @@ pnfs_try_to_write_data(struct nfs_pgio_header *hdr, hdr->mds_ops = call_ops; -dprintk ("%s: Writing ino:%lu %u@%llu (how %d)\n" , __func__, +dprintk ("%s: Writing ino:%llu %u@%llu (how %d)\n" , __func__, inode->i_ino, hdr->args.count, hdr->args.offset, how); trypnfs = nfss->pnfs_curr_ld->write_pagelist (hdr, how);if (trypnfs !=PNFS_NOT_ATTEMPTED )
@@ -3181,7 +3181,7 @@ pnfs_try_to_read_data(struct nfs_pgio_header *hdr, hdr->mds_ops = call_ops; -dprintk ("%s: Reading ino:%lu %u@%llu\n" , +dprintk ("%s: Reading ino:%llu %u@%llu\n" , __func__, inode->i_ino, hdr->args.count, hdr->args.offset); trypnfs = nfss->pnfs_curr_ld->read_pagelist (hdr);
@@ -3314,7 +3314,7 @@ pnfs_set_layoutcommit(struct inode *inode, struct pnfs_layout_segment *lseg,if (!test_and_set_bit (NFS_INO_LAYOUTCOMMIT , &nfsi->flags)) { nfsi->layout->plh_lwb = end_pos; mark_as_dirty = true; -dprintk ("%s: Set layoutcommit for inode %lu " , +dprintk ("%s: Set layoutcommit for inode %llu " , __func__, inode->i_ino); }else if (end_pos > nfsi->layout->plh_lwb) nfsi->layout->plh_lwb = end_pos;
@@ -3363,7 +3363,7 @@ pnfs_layoutcommit_inode(struct inode *inode, bool sync)if (!pnfs_layoutcommit_outstanding (inode))return 0 ; -dprintk ("--> %s inode %lu\n" , __func__, inode->i_ino); +dprintk ("--> %s inode %llu\n" , __func__, inode->i_ino); status = -EAGAIN ;if (test_and_set_bit (NFS_INO_LAYOUTCOMMITTING , &nfsi->flags)) {
include/linux/nfs_fs.h +2 -5
@@ -667,13 +667,10 @@ static inline loff_t nfs_size_to_loff_t(__u64 size)return min_t (u64, size,OFFSET_MAX ); } -static inline ino_t +static inline u64 nfs_fileid_to_ino_t (u64 fileid) { -ino_t ino = (ino_t ) fileid; -if (sizeof (ino_t) <sizeof (u64)) - ino ^= fileid >> (sizeof (u64)-sizeof (ino_t)) *8 ; -return ino; +return fileid; }static inline void nfs_ooo_clear (struct nfs_inode *nfsi)
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 9/61 nfs: remove nfs_fattr_to_ino_t() and nfs_fileid_to_ino_t()
In reply to Jeff LaytonNow that i_ino is u64, these helpers are trivial identity functions that just return the fileid unchanged. Remove them and use fattr->fileid directly at the two call sites.
nfs_fileid_to_ino_t() had no callers at all.
--- fs/nfs/inode.c | 17 +++-------------- include/linux/nfs_fs.h | 6 ------ 2 files changed, 3 insertions(+), 20 deletions(-)
fs/nfs/inode.c +3 -14
@@ -66,12 +66,6 @@ static int nfs_update_inode(struct inode *, struct nfs_fattr *);static struct kmem_cache * nfs_inode_cachep; -static inline u64 -nfs_fattr_to_ino_t (struct nfs_fattr *fattr) -{ -return fattr->fileid; -} -int nfs_wait_bit_killable (struct wait_bit_key *key,int mode) {if (unlikely (nfs_current_task_exiting ()))
@@ -413,14 +407,12 @@ nfs_ilookup(struct super_block *sb, struct nfs_fattr *fattr, struct nfs_fh *fh) .fattr = fattr, };struct inode *inode; -unsigned long hash;if (!(fattr->valid &NFS_ATTR_FATTR_FILEID ) || !(fattr->valid &NFS_ATTR_FATTR_TYPE ))return NULL ; - hash =nfs_fattr_to_ino_t (fattr); - inode =ilookup5 (sb, hash, nfs_find_actor, &desc); + inode =ilookup5 (sb, fattr->fileid, nfs_find_actor, &desc);dprintk ("%s: returning %p\n" , __func__, inode);return inode;
@@ -456,7 +448,6 @@ nfs_fhget(struct super_block *sb, struct nfs_fh *fh, struct nfs_fattr *fattr) };struct inode *inode =ERR_PTR (-ENOENT );u64 fattr_supported =NFS_SB (sb)->fattr_valid; -unsigned long hash;nfs_attr_check_mountpoint (sb, fattr);
@@ -467,9 +458,7 @@ nfs_fhget(struct super_block *sb, struct nfs_fh *fh, struct nfs_fattr *fattr)if ((fattr->valid &NFS_ATTR_FATTR_TYPE ) ==0 ) goto out_no_inode; - hash =nfs_fattr_to_ino_t (fattr); - - inode =iget5_locked (sb, hash, nfs_find_actor, nfs_init_locked, &desc); + inode =iget5_locked (sb, fattr->fileid, nfs_find_actor, nfs_init_locked, &desc);if (inode ==NULL ) { inode =ERR_PTR (-ENOMEM ); goto out_no_inode;
@@ -481,7 +470,7 @@ nfs_fhget(struct super_block *sb, struct nfs_fh *fh, struct nfs_fattr *fattr)/* We set i_ino for the few things that still rely on it, * such as stat(2) */ - inode->i_ino = hash; + inode->i_ino = fattr->fileid;/* We can't support update_atime(), since the server will reset it */ inode->i_flags |=S_NOATIME |S_NOCMTIME ;
include/linux/nfs_fs.h +0 -6
@@ -667,12 +667,6 @@ static inline loff_t nfs_size_to_loff_t(__u64 size)return min_t (u64, size,OFFSET_MAX ); } -static inline u64 -nfs_fileid_to_ino_t (u64 fileid) -{ -return fileid; -} -static inline void nfs_ooo_clear (struct nfs_inode *nfsi) { nfsi->cache_validity &= ~NFS_INO_DATA_INVAL_DEFER ;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 10/61 nfs: remove nfs_compat_user_ino64()
In reply to Jeff LaytonNow that i_ino is u64, the VFS stat path handles 64-bit inode numbers natively. The truncation to 32-bit st_ino (with -EOVERFLOW) is handled by cp_new_stat() and cp_compat_stat() in the generic stat code, so the NFS-specific XOR-folding hack is no longer needed.
Remove nfs_compat_user_ino64() and have callers pass the full 64-bit fileid directly to stat->ino and dir_emit(), both of which accept u64.
--- fs/nfs/dir.c | 2 +- fs/nfs/inode.c | 25 +------------------------ include/linux/nfs_fs.h | 1 - 3 files changed, 2 insertions(+), 26 deletions(-)
fs/nfs/dir.c +1 -1
@@ -1107,7 +1107,7 @@ static void nfs_do_filldir(struct nfs_readdir_descriptor *desc, ent = &array->array[i];if (!dir_emit (desc->ctx, ent->name, ent->name_len, -nfs_compat_user_ino64 (ent->ino), ent->d_type)) { + ent->ino, ent->d_type)) { desc->eob = true;break ; }
fs/nfs/inode.c +1 -24
@@ -77,29 +77,6 @@ int nfs_wait_bit_killable(struct wait_bit_key *key, int mode) }EXPORT_SYMBOL_GPL (nfs_wait_bit_killable); -/** -* nfs_compat_user_ino64 - returns the user-visible inode number -* @fileid: 64-bit fileid -* -* This function returns a 32-bit inode number if the boot parameter -* nfs.enable_ino64 is zero. -*/ -u64 nfs_compat_user_ino64 (u64 fileid) -{ -#ifdef CONFIG_COMPAT -compat_ulong_t ino; -#else -unsigned long ino; -#endif - -if (enable_ino64) -return fileid; - ino = fileid; -if (sizeof (ino) <sizeof (fileid)) - ino ^= fileid >> (sizeof (fileid)-sizeof (ino)) *8 ; -return ino; -} -int nfs_drop_inode (struct inode *inode) {return NFS_STALE (inode) ||inode_generic_drop (inode);
@@ -1061,7 +1038,7 @@ int nfs_getattr(struct mnt_idmap *idmap, const struct path *path, stat->result_mask =nfs_get_valid_attrmask (inode) | request_mask;generic_fillattr (&nop_mnt_idmap, request_mask, inode, stat); - stat->ino =nfs_compat_user_ino64 (NFS_FILEID (inode)); + stat->ino =NFS_FILEID (inode); stat->change_cookie =inode_peek_iversion_raw (inode); stat->attributes_mask |=STATX_ATTR_CHANGE_MONOTONIC ;if (server->change_attr_type !=NFS4_CHANGE_TYPE_IS_UNDEFINED )
include/linux/nfs_fs.h +0 -1
@@ -472,7 +472,6 @@ extern void nfs_file_set_open_context(struct file *filp, struct nfs_open_contextextern void nfs_file_clear_open_context (struct file *flip);extern struct nfs_lock_context *nfs_get_lock_context (struct nfs_open_context *ctx);extern void nfs_put_lock_context (struct nfs_lock_context *l_ctx); -extern u64 nfs_compat_user_ino64 (u64 fileid);extern void nfs_fattr_init (struct nfs_fattr *fattr);extern void nfs_fattr_set_barrier (struct nfs_fattr *fattr);extern unsigned long nfs_inc_attr_generation_counter (void );
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 11/61 nfs: remove enable_ino64 module parameter
In reply to Jeff LaytonThe enable_ino64 module parameter controlled whether NFS presented 64-bit or XOR-folded 32-bit inode numbers to userspace. With i_ino now being u64 and the compat folding function removed, this parameter has no remaining consumers.
Remove the parameter, the NFS_64_BIT_INODE_NUMBERS_ENABLED macro, and the enable_ino64 variable.
--- fs/nfs/inode.c | 6 ------ 1 file changed, 6 deletions(-)
fs/nfs/inode.c +0 -6
@@ -57,11 +57,6 @@#define NFSDBG_FACILITY NFSDBG_VFS -#define NFS_64_BIT_INODE_NUMBERS_ENABLED 1 - -/* Default is to see 64-bit inode numbers */ -static bool enable_ino64 =NFS_64_BIT_INODE_NUMBERS_ENABLED ; -static int nfs_update_inode (struct inode *,struct nfs_fattr *);static struct kmem_cache * nfs_inode_cachep;
@@ -2770,7 +2765,6 @@ static void __exit exit_nfs_fs(void)MODULE_AUTHOR ("Olaf Kirch <[email protected]>" );MODULE_DESCRIPTION ("NFS client support" );MODULE_LICENSE ("GPL" ); -module_param (enable_ino64, bool,0644 );module_init (init_nfs_fs)module_exit (exit_nfs_fs)
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 12/61 nfsd: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings from %ld/%lu to %lld/%llu for i_ino, which is now a u64.
--- fs/nfsd/export.c | 2 +- fs/nfsd/nfs4state.c | 4 ++-- fs/nfsd/nfsfh.c | 4 ++-- fs/nfsd/vfs.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-)
fs/nfsd/export.c +1 -1
@@ -1039,7 +1039,7 @@ exp_rootfh(struct net *net, struct auth_domain *clp, char *name, } inode =d_inode (path.dentry); -dprintk ("nfsd: exp_rootfh(%s [%p] %s:%s/%ld)\n" , +dprintk ("nfsd: exp_rootfh(%s [%p] %s:%s/%lld)\n" , name, path.dentry, clp->name, inode->i_sb->s_id, inode->i_ino); exp =exp_parent (cd, clp, &path);
fs/nfsd/nfs4state.c +2 -2
@@ -1253,7 +1253,7 @@ static void nfsd4_finalize_deleg_timestamps(struct nfs4_delegation *dp, struct fif (ret) {struct inode *inode =file_inode (f); -pr_notice_ratelimited ("nfsd: Unable to update timestamps on inode %02x:%02x:%lu: %d\n" , +pr_notice_ratelimited ("nfsd: Unable to update timestamps on inode %02x:%02x:%llu: %d\n" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino, ret);
@@ -2888,7 +2888,7 @@ static void nfs4_show_superblock(struct seq_file *s, struct nfsd_file *f) {struct inode *inode =file_inode (f->nf_file); -seq_printf (s,"superblock: \"%02x:%02x:%ld\"" , +seq_printf (s,"superblock: \"%02x:%02x:%llu\"" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino);
fs/nfsd/nfsfh.c +2 -2
@@ -601,9 +601,9 @@ fh_compose(struct svc_fh *fhp, struct svc_export *exp, struct dentry *dentry,struct inode * inode =d_inode (dentry);dev_t ex_dev =exp_sb (exp)->s_dev; -dprintk ("nfsd: fh_compose(exp %02x:%02x/%ld %pd2, ino=%ld)\n" , +dprintk ("nfsd: fh_compose(exp %02x:%02x/%lld %pd2, ino=%lld)\n" ,MAJOR (ex_dev),MINOR (ex_dev), - (long )d_inode (exp->ex_path.dentry)->i_ino, + (long long )d_inode (exp->ex_path.dentry)->i_ino, dentry, (inode ? inode->i_ino :0 ));
fs/nfsd/vfs.c +1 -1
@@ -1163,7 +1163,7 @@ nfsd_direct_read(struct svc_rqst *rqstp, struct svc_fh *fhp, }else if (unlikely (host_err == -EINVAL )) {struct inode *inode =d_inode (fhp->fh_dentry); -pr_info_ratelimited ("nfsd: Direct I/O alignment failure on %s/%ld\n" , +pr_info_ratelimited ("nfsd: Direct I/O alignment failure on %s/%lld\n" , inode->i_sb->s_id, inode->i_ino); host_err = -ESERVERFAULT ; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 13/61 smb: store full 64-bit uniqueid in i_ino
In reply to Jeff LaytonWith i_ino now u64, CIFS/SMB can store the full 64-bit uniqueid in i_ino without the XOR-folding hack previously needed on 32-bit architectures.
- Simplify cifs_uniqueid_to_ino_t() to return u64 directly
- Update hash variable type in cifs_get_inode_info()
- Update format strings from %lu to %llu
--- fs/smb/client/cifsfs.h | 12 +++--------- fs/smb/client/inode.c | 4 ++-- 2 files changed, 5 insertions(+), 11 deletions(-)
fs/smb/client/cifsfs.h +3 -9
@@ -14,18 +14,12 @@#define ROOT_I 2/* -* ino_t is 32-bits on 32-bit arch. We have to squash the 64-bit value down -* so that it will fit. We use hash_64 to convert the value to 31 bits, and -* then add 1, to ensure that we don't end up with a 0 as the value. +* With i_ino being u64, we can store the full 64-bit uniqueid directly. */ -static inline ino_t +static inline u64 cifs_uniqueid_to_ino_t (u64 fileid) { -if ((sizeof (ino_t)) < (sizeof (u64))) -return (ino_t )hash_64 (fileid, (sizeof (ino_t) *8 ) -1 ) +1 ; - -return (ino_t )fileid; - +return fileid; }static inline void cifs_set_time (struct dentry *dentry,unsigned long time)
fs/smb/client/inode.c +2 -2
@@ -1611,13 +1611,13 @@ inode_has_hashed_dentries(struct inode *inode)struct inode *cifs_iget (struct super_block *sb,struct cifs_fattr *fattr) { -unsigned long hash; +u64 hash;struct inode *inode; retry_iget5_locked:cifs_dbg (FYI ,"looking for uniqueid=%llu\n" , fattr->cf_uniqueid); -/* hash down to 32-bits on 32-bit arch */ +/* With u64 i_ino, we can use the full uniqueid */ hash =cifs_uniqueid_to_ino_t (fattr->cf_uniqueid); inode =iget5_locked (sb, hash, cifs_find_inode, cifs_init_inode, fattr);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 14/61 smb: remove cifs_uniqueid_to_ino_t()
In reply to Jeff LaytonNow that i_ino is u64, cifs_uniqueid_to_ino_t() is a trivial identity function. Remove it and use fattr->cf_uniqueid directly at both call sites.
Also remove the now-unused #include <linux/hash.h>, which was only needed for the old XOR-folding logic.
--- fs/smb/client/cifsfs.h | 11 ----------- fs/smb/client/inode.c | 2 +- fs/smb/client/readdir.c | 2 +- 3 files changed, 2 insertions(+), 13 deletions(-)
fs/smb/client/cifsfs.h +0 -11
@@ -9,19 +9,8 @@#ifndef _CIFSFS_H#define _CIFSFS_H -#include <linux/hash.h> -#define ROOT_I 2 -/* -* With i_ino being u64, we can store the full 64-bit uniqueid directly. -*/ -static inline u64 -cifs_uniqueid_to_ino_t (u64 fileid) -{ -return fileid; -} -static inline void cifs_set_time (struct dentry *dentry,unsigned long time) { dentry->d_fsdata = (void *) time;
fs/smb/client/inode.c +1 -1
@@ -1618,7 +1618,7 @@ cifs_iget(struct super_block *sb, struct cifs_fattr *fattr)cifs_dbg (FYI ,"looking for uniqueid=%llu\n" , fattr->cf_uniqueid);/* With u64 i_ino, we can use the full uniqueid */ - hash =cifs_uniqueid_to_ino_t (fattr->cf_uniqueid); + hash = fattr->cf_uniqueid; inode =iget5_locked (sb, hash, cifs_find_inode, cifs_init_inode, fattr);if (inode) {
fs/smb/client/readdir.c +1 -1
@@ -919,7 +919,7 @@ static bool cifs_dir_emit(struct dir_context *ctx, {size_t delta_bytes =0 ;bool rc, added = false; -ino_t ino =cifs_uniqueid_to_ino_t (fattr->cf_uniqueid); +ino_t ino = fattr->cf_uniqueid; rc =dir_emit (ctx, name, namelen, ino, fattr->cf_dtype);if (!rc)
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 15/61 locks: update /proc/locks format for u64 i_ino
In reply to Jeff LaytonUpdate the seq_printf format string in lock_get_status() from %lu to %llu for printing inode->i_ino, since i_ino is now u64.
--- fs/locks.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
fs/locks.c +3 -3
@@ -234,7 +234,7 @@ locks_check_ctx_lists(struct inode *inode)if (unlikely (!list_empty (&ctx->flc_flock) || !list_empty (&ctx->flc_posix) || !list_empty (&ctx->flc_lease))) { -pr_warn ("Leaked locks on dev=0x%x:0x%x ino=0x%lx:\n" , +pr_warn ("Leaked locks on dev=0x%x:0x%x ino=0x%llx:\n" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino);locks_dump_ctx_list (&ctx->flc_flock,"FLOCK" );
@@ -251,7 +251,7 @@ locks_check_ctx_file_list(struct file *filp, struct list_head *list, char *list_list_for_each_entry (flc, list, flc_list)if (flc->flc_file == filp) - pr_warn("Leaked %s lock on dev=0x%x:0x%x ino=0x%lx " + pr_warn("Leaked %s lock on dev=0x%x:0x%x ino=0x%llx " " fl_owner=%p fl_flags=0x%x fl_type=0x%x fl_pid=%u\n", list_type, MAJOR(inode->i_sb->s_dev), MINOR(inode->i_sb->s_dev), inode->i_ino,
@@ -2896,7 +2896,7 @@ static void lock_get_status(struct seq_file *f, struct file_lock_core *flc, (type == F_RDLCK) ? "READ" : "UNLCK");if (inode) {/* userspace relies on this representation of dev_t */ -seq_printf (f,"%d %02x:%02x:%lu " , pid, +seq_printf (f,"%d %02x:%02x:%llu " , pid,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino); }else {
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 16/61 proc: update /proc/PID/maps for u64 i_ino
In reply to Jeff LaytonUpdate the local ino variable type from unsigned long to u64, and change the format string from %lu to %llu when printing it. The variable is assigned from inode->i_ino which is now u64.
--- fs/proc/fd.c | 2 +- fs/proc/task_mmu.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-)
fs/proc/fd.c +1 -1
@@ -54,7 +54,7 @@ static int seq_show(struct seq_file *m, void *v)if (ret)return ret; -seq_printf (m,"pos:\t%lli\nflags:\t0%o\nmnt_id:\t%i\nino:\t%lu\n" , +seq_printf (m,"pos:\t%lli\nflags:\t0%o\nmnt_id:\t%i\nino:\t%llu\n" , (long long )file->f_pos, f_flags,real_mount (file->f_path.mnt)->mnt_id,file_inode (file)->i_ino);
fs/proc/task_mmu.c +2 -2
@@ -442,7 +442,7 @@ static void get_vma_name(struct vm_area_struct *vma,static void show_vma_header_prefix (struct seq_file *m,unsigned long start,unsigned long end,vm_flags_t flags,unsigned long long pgoff, -dev_t dev,unsigned long ino) +dev_t dev,u64 ino) {seq_setwidth (m,25 +sizeof (void *) *6 -1 );seq_put_hex_ll (m,NULL , start,8 );
@@ -465,7 +465,7 @@ show_map_vma(struct seq_file *m, struct vm_area_struct *vma)const struct path *path;const char *name_fmt, *name;vm_flags_t flags = vma->vm_flags; -unsigned long ino =0 ; +u64 ino =0 ;unsigned long long pgoff =0 ;unsigned long start, end;dev_t dev =0 ;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 17/61 nilfs2: update for u64 i_ino
In reply to Jeff LaytonUpdate nilfs2 trace events and filesystem code for u64 i_ino:
- Change __field(ino_t, ...) to __field(u64, ...) in trace events
- Update format strings from %lu to %llu
- Cast to (unsigned long long) in TP_printk
--- fs/nilfs2/alloc.c | 10 +++++----- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/btnode.c | 2 +- fs/nilfs2/btree.c | 12 ++++++------ fs/nilfs2/dir.c | 12 ++++++------ fs/nilfs2/direct.c | 4 ++-- fs/nilfs2/gcinode.c | 2 +- fs/nilfs2/inode.c | 8 ++++---- fs/nilfs2/mdt.c | 2 +- fs/nilfs2/namei.c | 2 +- fs/nilfs2/segment.c | 2 +- include/trace/events/nilfs2.h | 12 ++++++------ 12 files changed, 35 insertions(+), 35 deletions(-)
fs/nilfs2/alloc.c +5 -5
@@ -707,7 +707,7 @@ void nilfs_palloc_commit_free_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else
@@ -748,7 +748,7 @@ void nilfs_palloc_abort_alloc_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else
@@ -861,7 +861,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems)if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap)) {nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )entry_nrs[j]); }else {
@@ -906,7 +906,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) last_nrs[k]);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting block that object (entry=%llu, ino=%lu) belongs to" , +"error %d deleting block that object (entry=%llu, ino=%llu) belongs to" , ret, (unsigned long long )last_nrs[k], inode->i_ino); }
@@ -923,7 +923,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) ret =nilfs_palloc_delete_bitmap_block (inode, group);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting bitmap block of group=%lu, ino=%lu" , +"error %d deleting bitmap block of group=%lu, ino=%llu" , ret, group, inode->i_ino); } }
fs/nilfs2/bmap.c +1 -1
@@ -33,7 +33,7 @@ static int nilfs_bmap_convert_error(struct nilfs_bmap *bmap,if (err == -EINVAL ) {__nilfs_error (inode->i_sb, fname, -"broken bmap (inode number=%lu)" , inode->i_ino); +"broken bmap (inode number=%llu)" , inode->i_ino); err = -EIO ; }return err;
fs/nilfs2/btnode.c +1 -1
@@ -64,7 +64,7 @@ nilfs_btnode_create_block(struct address_space *btnc, __u64 blocknr)* clearing of an abandoned b-tree node is missing somewhere). */ nilfs_error (inode->i_sb, -"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%lu)" , +"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%llu)" , (unsigned long long )blocknr, inode->i_ino); goto failed; }
fs/nilfs2/btree.c +6 -6
@@ -353,7 +353,7 @@ static int nilfs_btree_node_broken(const struct nilfs_btree_node *node, nchildren <= 0 || nchildren > NILFS_BTREE_NODE_NCHILDREN_MAX(size))) {nilfs_crit (inode->i_sb, -"bad btree node (ino=%lu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree node (ino=%llu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, (unsigned long long )blocknr, level, flags, nchildren); ret =1 ;
@@ -384,7 +384,7 @@ static int nilfs_btree_root_broken(const struct nilfs_btree_node *node, nchildren > NILFS_BTREE_ROOT_NCHILDREN_MAX || (nchildren == 0 && level > NILFS_BTREE_LEVEL_NODE_MIN))) {nilfs_crit (inode->i_sb, -"bad btree root (ino=%lu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree root (ino=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, level, flags, nchildren); ret =1 ; }
@@ -453,7 +453,7 @@ static int nilfs_btree_bad_node(const struct nilfs_bmap *btree,if (unlikely (nilfs_btree_node_get_level (node) != level)) {dump_stack ();nilfs_crit (btree->b_inode->i_sb, -"btree level mismatch (ino=%lu): %d != %d" , +"btree level mismatch (ino=%llu): %d != %d" , btree->b_inode->i_ino,nilfs_btree_node_get_level (node), level);return 1 ;
@@ -521,7 +521,7 @@ static int __nilfs_btree_get_block(const struct nilfs_bmap *btree, __u64 ptr, out_no_wait:if (!buffer_uptodate (bh)) {nilfs_err (btree->b_inode->i_sb, -"I/O error reading b-tree node block (ino=%lu, blocknr=%llu)" , +"I/O error reading b-tree node block (ino=%llu, blocknr=%llu)" , btree->b_inode->i_ino, (unsigned long long )ptr);brelse (bh);return -EIO ;
@@ -2104,7 +2104,7 @@ static int nilfs_btree_propagate(struct nilfs_bmap *btree,if (ret <0 ) {if (unlikely (ret == -ENOENT )) {nilfs_crit (btree->b_inode->i_sb, -"writing node/leaf block does not appear in b-tree (ino=%lu) at key=%llu, level=%d" , +"writing node/leaf block does not appear in b-tree (ino=%llu) at key=%llu, level=%d" , btree->b_inode->i_ino, (unsigned long long )key, level); ret = -EINVAL ;
@@ -2146,7 +2146,7 @@ static void nilfs_btree_add_dirty_buffer(struct nilfs_bmap *btree, level >= NILFS_BTREE_LEVEL_MAX) {dump_stack ();nilfs_warn (btree->b_inode->i_sb, -"invalid btree level: %d (key=%llu, ino=%lu, blocknr=%llu)" , +"invalid btree level: %d (key=%llu, ino=%llu, blocknr=%llu)" , level, (unsigned long long )key, btree->b_inode->i_ino, (unsigned long long )bh->b_blocknr);
fs/nilfs2/dir.c +6 -6
@@ -150,7 +150,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) Ebadsize:nilfs_error (sb, -"size of directory #%lu is not a multiple of chunk size" , +"size of directory #%llu is not a multiple of chunk size" , dir->i_ino); goto fail; Eshort:
@@ -169,7 +169,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) error ="disallowed inode number" ; bad_entry:nilfs_error (sb, -"bad entry in directory #%lu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d" , +"bad entry in directory #%llu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d" , dir->i_ino, error, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long )le64_to_cpu (p->inode), rec_len, p->name_len);
@@ -177,7 +177,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) Eend: p = (struct nilfs_dir_entry *)(kaddr + offs);nilfs_error (sb, -"entry in directory #%lu spans the page boundary offset=%lu, inode=%lu" , +"entry in directory #%llu spans the page boundary offset=%lu, inode=%lu" , dir->i_ino, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long )le64_to_cpu (p->inode)); fail:
@@ -251,7 +251,7 @@ static int nilfs_readdir(struct file *file, struct dir_context *ctx) kaddr =nilfs_get_folio (inode, n, &folio);if (IS_ERR (kaddr)) { -nilfs_error (sb,"bad page in #%lu" , inode->i_ino); +nilfs_error (sb,"bad page in #%llu" , inode->i_ino); ctx->pos +=PAGE_SIZE - offset;return -EIO ; }
@@ -336,7 +336,7 @@ struct nilfs_dir_entry *nilfs_find_entry(struct inode *dir,/* next folio is past the blocks we've got */ if (unlikely (n > (dir->i_blocks >> (PAGE_SHIFT -9 )))) {nilfs_error (dir->i_sb, -"dir %lu size %lld exceeds block count %llu" , +"dir %llu size %lld exceeds block count %llu" , dir->i_ino, dir->i_size, (unsigned long long )dir->i_blocks); goto out;
@@ -382,7 +382,7 @@ struct nilfs_dir_entry *nilfs_dotdot(struct inode *dir, struct folio **foliop)return next_de; fail: -nilfs_error (dir->i_sb,"directory #%lu %s" , dir->i_ino, msg); +nilfs_error (dir->i_sb,"directory #%llu %s" , dir->i_ino, msg);folio_release_kmap (folio, de);return NULL ; }
fs/nilfs2/direct.c +2 -2
@@ -338,7 +338,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, key =nilfs_bmap_data_get_key (bmap, *bh);if (unlikely (key >NILFS_DIRECT_KEY_MAX )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid key: %llu" , +"%s (ino=%llu): invalid key: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )key);return -EINVAL ;
@@ -346,7 +346,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, ptr =nilfs_direct_get_ptr (bmap, key);if (unlikely (ptr ==NILFS_BMAP_INVALID_PTR )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid pointer: %llu" , +"%s (ino=%llu): invalid pointer: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )ptr);return -EINVAL ;
fs/nilfs2/gcinode.c +1 -1
@@ -137,7 +137,7 @@ int nilfs_gccache_wait_and_mark_dirty(struct buffer_head *bh)struct inode *inode = bh->b_folio->mapping->host;nilfs_err (inode->i_sb, -"I/O error reading %s block for GC (ino=%lu, vblocknr=%llu)" , +"I/O error reading %s block for GC (ino=%llu, vblocknr=%llu)" ,buffer_nilfs_node (bh) ?"node" :"data" , inode->i_ino, (unsigned long long )bh->b_blocknr);return -EIO ;
fs/nilfs2/inode.c +4 -4
@@ -108,7 +108,7 @@ int nilfs_get_block(struct inode *inode, sector_t blkoff,* be locked in this case. */ nilfs_warn (inode->i_sb, -"%s (ino=%lu): a race condition while inserting a data block at offset=%llu" , +"%s (ino=%llu): a race condition while inserting a data block at offset=%llu" , __func__, inode->i_ino, (unsigned long long )blkoff); err = -EAGAIN ;
@@ -789,7 +789,7 @@ static void nilfs_truncate_bmap(struct nilfs_inode_info *ii, goto repeat; failed: -nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%lu)" , +nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%llu)" , ret, ii->vfs_inode.i_ino); }
@@ -1026,7 +1026,7 @@ int nilfs_set_file_dirty(struct inode *inode, unsigned int nr_dirty)* this inode. */ nilfs_warn (inode->i_sb, -"cannot set file dirty (ino=%lu): the file is being freed" , +"cannot set file dirty (ino=%llu): the file is being freed" , inode->i_ino);spin_unlock (&nilfs->ns_inode_lock);return -EINVAL ;/*
@@ -1057,7 +1057,7 @@ int __nilfs_mark_inode_dirty(struct inode *inode, int flags) err =nilfs_load_inode_block (inode, &ibh);if (unlikely (err)) {nilfs_warn (inode->i_sb, -"cannot mark inode dirty (ino=%lu): error %d loading inode block" , +"cannot mark inode dirty (ino=%llu): error %d loading inode block" , inode->i_ino, err);return err; }
fs/nilfs2/mdt.c +1 -1
@@ -203,7 +203,7 @@ static int nilfs_mdt_read_block(struct inode *inode, unsigned long block, err = -EIO ;if (!buffer_uptodate (first_bh)) {nilfs_err (inode->i_sb, -"I/O error reading meta-data file (ino=%lu, block-offset=%lu)" , +"I/O error reading meta-data file (ino=%llu, block-offset=%lu)" , inode->i_ino, block); goto failed_bh; }
fs/nilfs2/namei.c +1 -1
@@ -292,7 +292,7 @@ static int nilfs_do_unlink(struct inode *dir, struct dentry *dentry)if (!inode->i_nlink) {nilfs_warn (inode->i_sb, -"deleting nonexistent file (ino=%lu), %d" , +"deleting nonexistent file (ino=%llu), %d" , inode->i_ino, inode->i_nlink);set_nlink (inode,1 ); }
fs/nilfs2/segment.c +1 -1
@@ -2024,7 +2024,7 @@ static int nilfs_segctor_collect_dirty_files(struct nilfs_sc_info *sci, ifile, ii->vfs_inode.i_ino, &ibh);if (unlikely (err)) {nilfs_warn (sci->sc_super, -"log writer: error %d getting inode block (ino=%lu)" , +"log writer: error %d getting inode block (ino=%llu)" , err, ii->vfs_inode.i_ino);return err; }
include/trace/events/nilfs2.h +6 -6
@@ -165,14 +165,14 @@ TRACE_EVENT(nilfs2_segment_usage_freed, TRACE_EVENT(nilfs2_mdt_insert_new_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long block), TP_ARGS(inode, ino, block), TP_STRUCT__entry( __field(struct inode *, inode) - __field(unsigned long, ino) + __field(u64, ino) __field(unsigned long, block) ),
@@ -182,7 +182,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, __entry->block = block; ), -TP_printk ("inode = %p ino = %lu block = %lu" , +TP_printk ("inode = %p ino = %llu block = %lu" , __entry->inode, __entry->ino, __entry->block)
@@ -190,7 +190,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, TRACE_EVENT(nilfs2_mdt_submit_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long blkoff, enum req_op mode),
@@ -198,7 +198,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block,TP_STRUCT__entry (__field (struct inode *,inode ) - __field(unsigned long, ino) +__field (u64, ino) __field(unsigned long, blkoff)/* * Use field_struct() to avoid is_signed_type() on the
@@ -214,7 +214,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block, __entry->mode = mode; ), - TP_printk("inode = %p ino = %lu blkoff = %lu mode = %x", + TP_printk("inode = %p ino = %llu blkoff = %lu mode = %x", __entry->inode, __entry->ino, __entry->blkoff,
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 18/61 9p: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in 9p for the i_ino type change from unsigned long to u64.
--- fs/9p/vfs_addr.c | 4 ++-- fs/9p/vfs_inode.c | 6 +++--- fs/9p/vfs_inode_dotl.c | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-)
fs/9p/vfs_addr.c +2 -2
@@ -36,7 +36,7 @@ static void v9fs_begin_writeback(struct netfs_io_request *wreq) fid =v9fs_fid_find_inode (wreq->inode, true,INVALID_UID , true);if (!fid) { -WARN_ONCE (1 ,"folio expected an open fid inode->i_ino=%lx\n" , +WARN_ONCE (1 ,"folio expected an open fid inode->i_ino=%llx\n" , wreq->inode->i_ino);return ; }
@@ -133,7 +133,7 @@ static int v9fs_init_request(struct netfs_io_request *rreq, struct file *file)return 0 ; no_fid: -WARN_ONCE (1 ,"folio expected an open fid inode->i_ino=%lx\n" , +WARN_ONCE (1 ,"folio expected an open fid inode->i_ino=%llx\n" , rreq->inode->i_ino);return -EINVAL ; }
fs/9p/vfs_inode.c +3 -3
@@ -1245,7 +1245,7 @@ static int v9fs_vfs_symlink(struct mnt_idmap *idmap, struct inode *dir, struct dentry *dentry, const char *symname) { - p9_debug(P9_DEBUG_VFS, " %lu,%pd,%s\n", + p9_debug(P9_DEBUG_VFS, " %llu,%pd,%s\n", dir->i_ino, dentry, symname);return v9fs_vfs_mkspecial (dir, dentry,P9_DMSYMLINK , symname);
@@ -1269,7 +1269,7 @@ v9fs_vfs_link(struct dentry *old_dentry, struct inode *dir,char name[1 +U32_MAX_DIGITS +2 ];/* sign + number + \n + \0 */ struct p9_fid *oldfid; -p9_debug (P9_DEBUG_VFS ," %lu,%pd,%pd\n" , +p9_debug (P9_DEBUG_VFS ," %llu,%pd,%pd\n" , dir->i_ino, dentry, old_dentry); oldfid =v9fs_fid_clone (old_dentry);
@@ -1305,7 +1305,7 @@ v9fs_vfs_mknod(struct mnt_idmap *idmap, struct inode *dir,char name[2 +U32_MAX_DIGITS +1 +U32_MAX_DIGITS +1 ];u32 perm; -p9_debug (P9_DEBUG_VFS ," %lu,%pd mode: %x MAJOR: %u MINOR: %u\n" , +p9_debug (P9_DEBUG_VFS ," %llu,%pd mode: %x MAJOR: %u MINOR: %u\n" , dir->i_ino, dentry, mode,MAJOR (rdev),MINOR (rdev));
fs/9p/vfs_inode_dotl.c +3 -3
@@ -691,7 +691,7 @@ v9fs_vfs_symlink_dotl(struct mnt_idmap *idmap, struct inode *dir,struct p9_fid *fid =NULL ; name = dentry->d_name.name; -p9_debug (P9_DEBUG_VFS ,"%lu,%s,%s\n" , dir->i_ino, name, symname); +p9_debug (P9_DEBUG_VFS ,"%llu,%s,%s\n" , dir->i_ino, name, symname); dfid =v9fs_parent_fid (dentry);if (IS_ERR (dfid)) {
@@ -734,7 +734,7 @@ v9fs_vfs_link_dotl(struct dentry *old_dentry, struct inode *dir,struct p9_fid *dfid, *oldfid;struct v9fs_session_info *v9ses; -p9_debug (P9_DEBUG_VFS ,"dir ino: %lu, old_name: %pd, new_name: %pd\n" , +p9_debug (P9_DEBUG_VFS ,"dir ino: %llu, old_name: %pd, new_name: %pd\n" , dir->i_ino, old_dentry, dentry); v9ses =v9fs_inode2v9ses (dir);
@@ -798,7 +798,7 @@ v9fs_vfs_mknod_dotl(struct mnt_idmap *idmap, struct inode *dir,struct p9_qid qid;struct posix_acl *dacl =NULL , *pacl =NULL ; -p9_debug (P9_DEBUG_VFS ," %lu,%pd mode: %x MAJOR: %u MINOR: %u\n" , +p9_debug (P9_DEBUG_VFS ," %llu,%pd mode: %x MAJOR: %u MINOR: %u\n" , dir->i_ino, dentry, omode,MAJOR (rdev),MINOR (rdev));
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 19/61 affs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in affs for the i_ino type change from unsigned long to u64.
--- fs/affs/amigaffs.c | 8 ++++---- fs/affs/bitmap.c | 2 +- fs/affs/dir.c | 2 +- fs/affs/file.c | 20 ++++++++++---------- fs/affs/inode.c | 12 ++++++------ fs/affs/namei.c | 14 +++++++------- fs/affs/symlink.c | 2 +- 7 files changed, 30 insertions(+), 30 deletions(-)
fs/affs/amigaffs.c +4 -4
@@ -33,7 +33,7 @@ affs_insert_hash(struct inode *dir, struct buffer_head *bh) ino = bh->b_blocknr; offset =affs_hash_name (sb,AFFS_TAIL (sb, bh)->name +1 ,AFFS_TAIL (sb, bh)->name[0 ]); -pr_debug ("%s(dir=%lu, ino=%d)\n" , __func__, dir->i_ino, ino); +pr_debug ("%s(dir=%llu, ino=%d)\n" , __func__, dir->i_ino, ino); dir_bh =affs_bread (sb, dir->i_ino);if (!dir_bh)
@@ -83,7 +83,7 @@ affs_remove_hash(struct inode *dir, struct buffer_head *rem_bh) sb = dir->i_sb; rem_ino = rem_bh->b_blocknr; offset =affs_hash_name (sb,AFFS_TAIL (sb, rem_bh)->name+1 ,AFFS_TAIL (sb, rem_bh)->name[0 ]); -pr_debug ("%s(dir=%lu, ino=%d, hashval=%d)\n" , __func__, dir->i_ino, +pr_debug ("%s(dir=%llu, ino=%d, hashval=%d)\n" , __func__, dir->i_ino, rem_ino, offset); bh =affs_bread (sb, dir->i_ino);
@@ -147,7 +147,7 @@ affs_remove_link(struct dentry *dentry)u32 link_ino, ino;int retval; -pr_debug ("%s(key=%ld)\n" , __func__, inode->i_ino); +pr_debug ("%s(key=%lld)\n" , __func__, inode->i_ino); retval = -EIO ; bh =affs_bread (sb, inode->i_ino);if (!bh)
@@ -279,7 +279,7 @@ affs_remove_header(struct dentry *dentry)if (!inode) goto done; -pr_debug ("%s(key=%ld)\n" , __func__, inode->i_ino); +pr_debug ("%s(key=%lld)\n" , __func__, inode->i_ino); retval = -EIO ; bh =affs_bread (sb, (u32 )(long )dentry->d_fsdata);if (!bh)
fs/affs/bitmap.c +1 -1
@@ -125,7 +125,7 @@ affs_alloc_block(struct inode *inode, u32 goal) sb = inode->i_sb; sbi =AFFS_SB (sb); -pr_debug ("balloc(inode=%lu,goal=%u): " , inode->i_ino, goal); +pr_debug ("balloc(inode=%llu,goal=%u): " , inode->i_ino, goal);if (AFFS_I (inode)->i_pa_cnt) {pr_debug ("%d\n" ,AFFS_I (inode)->i_lastalloc+1 );
fs/affs/dir.c +1 -1
@@ -90,7 +90,7 @@ affs_readdir(struct file *file, struct dir_context *ctx)u32 ino;int error =0 ; -pr_debug ("%s(ino=%lu,f_pos=%llx)\n" , __func__, inode->i_ino, ctx->pos); +pr_debug ("%s(ino=%llu,f_pos=%llx)\n" , __func__, inode->i_ino, ctx->pos);if (ctx->pos <2 ) { data->ino =0 ;
fs/affs/file.c +10 -10
@@ -24,7 +24,7 @@ static struct buffer_head *affs_get_extblock_slow(struct inode *inode, u32 ext);static int affs_file_open (struct inode *inode,struct file *filp) { -pr_debug ("open(%lu,%d)\n" , +pr_debug ("open(%llu,%d)\n" , inode->i_ino,atomic_read (&AFFS_I (inode)->i_opencnt));atomic_inc (&AFFS_I (inode)->i_opencnt);return 0 ;
@@ -33,7 +33,7 @@ affs_file_open(struct inode *inode, struct file *filp)static int affs_file_release (struct inode *inode,struct file *filp) { -pr_debug ("release(%lu, %d)\n" , +pr_debug ("release(%llu, %d)\n" , inode->i_ino,atomic_read (&AFFS_I (inode)->i_opencnt));if (atomic_dec_and_test (&AFFS_I (inode)->i_opencnt)) {
@@ -301,7 +301,7 @@ affs_get_block(struct inode *inode, sector_t block, struct buffer_head *bh_resulstruct buffer_head *ext_bh;u32 ext; -pr_debug ("%s(%lu, %llu)\n" , __func__, inode->i_ino, +pr_debug ("%s(%llu, %llu)\n" , __func__, inode->i_ino, (unsigned long long )block);BUG_ON (block > (sector_t )0x7fffffffUL );
@@ -534,7 +534,7 @@ static int affs_do_read_folio_ofs(struct folio *folio, size_t to, int create)size_t bidx, boff, bsize;u32 tmp; -pr_debug ("%s(%lu, %ld, 0, %zu)\n" , __func__, inode->i_ino, +pr_debug ("%s(%llu, %ld, 0, %zu)\n" , __func__, inode->i_ino, folio->index, to);BUG_ON (to >folio_size (folio)); bsize =AFFS_SB (sb)->s_data_blksize;
@@ -566,7 +566,7 @@ affs_extent_file_ofs(struct inode *inode, u32 newsize)u32 size, bsize;u32 tmp; -pr_debug ("%s(%lu, %d)\n" , __func__, inode->i_ino, newsize); +pr_debug ("%s(%llu, %d)\n" , __func__, inode->i_ino, newsize); bsize =AFFS_SB (sb)->s_data_blksize; bh =NULL ; size =AFFS_I (inode)->mmu_private;
@@ -634,7 +634,7 @@ static int affs_read_folio_ofs(struct file *file, struct folio *folio)size_t to;int err; -pr_debug ("%s(%lu, %ld)\n" , __func__, inode->i_ino, folio->index); +pr_debug ("%s(%llu, %ld)\n" , __func__, inode->i_ino, folio->index); to =folio_size (folio);if (folio_pos (folio) + to > inode->i_size) { to = inode->i_size -folio_pos (folio);
@@ -658,7 +658,7 @@ static int affs_write_begin_ofs(const struct kiocb *iocb,pgoff_t index;int err =0 ; -pr_debug ("%s(%lu, %llu, %llu)\n" , __func__, inode->i_ino, pos, +pr_debug ("%s(%llu, %llu, %llu)\n" , __func__, inode->i_ino, pos, pos + len);if (pos >AFFS_I (inode)->mmu_private) {/* XXX: this probably leaves a too-big i_size in case of
@@ -710,7 +710,7 @@ static int affs_write_end_ofs(const struct kiocb *iocb,* due to write_begin. */ -pr_debug ("%s(%lu, %llu, %llu)\n" , __func__, inode->i_ino, pos, +pr_debug ("%s(%llu, %llu, %llu)\n" , __func__, inode->i_ino, pos, pos + len); bsize =AFFS_SB (sb)->s_data_blksize; data =folio_address (folio);
@@ -854,7 +854,7 @@ affs_free_prealloc(struct inode *inode) {struct super_block *sb = inode->i_sb; -pr_debug ("free_prealloc(ino=%lu)\n" , inode->i_ino); +pr_debug ("free_prealloc(ino=%llu)\n" , inode->i_ino);while (AFFS_I (inode)->i_pa_cnt) {AFFS_I (inode)->i_pa_cnt--;
@@ -874,7 +874,7 @@ affs_truncate(struct inode *inode)struct buffer_head *ext_bh;int i; -pr_debug ("truncate(inode=%lu, oldsize=%llu, newsize=%llu)\n" , +pr_debug ("truncate(inode=%llu, oldsize=%llu, newsize=%llu)\n" , inode->i_ino,AFFS_I (inode)->mmu_private, inode->i_size); last_blk =0 ;
fs/affs/inode.c +6 -6
@@ -32,7 +32,7 @@ struct inode *affs_iget(struct super_block *sb, unsigned long ino)if (!(inode_state_read_once (inode) &I_NEW ))return inode; -pr_debug ("affs_iget(%lu)\n" , inode->i_ino); +pr_debug ("affs_iget(%llu)\n" , inode->i_ino); block = inode->i_ino; bh =affs_bread (sb, block);
@@ -171,14 +171,14 @@ affs_write_inode(struct inode *inode, struct writeback_control *wbc)uid_t uid;gid_t gid; -pr_debug ("write_inode(%lu)\n" , inode->i_ino); +pr_debug ("write_inode(%llu)\n" , inode->i_ino);if (!inode->i_nlink)// possibly free block return 0 ; bh =affs_bread (sb, inode->i_ino);if (!bh) { -affs_error (sb,"write_inode" ,"Cannot read block %lu" ,inode->i_ino); +affs_error (sb,"write_inode" ,"Cannot read block %llu" , inode->i_ino);return -EIO ; } tail =AFFS_TAIL (sb, bh);
@@ -219,7 +219,7 @@ affs_notify_change(struct mnt_idmap *idmap, struct dentry *dentry,struct inode *inode =d_inode (dentry);int error; -pr_debug ("notify_change(%lu,0x%x)\n" , inode->i_ino, attr->ia_valid); +pr_debug ("notify_change(%llu,0x%x)\n" , inode->i_ino, attr->ia_valid); error =setattr_prepare (&nop_mnt_idmap, dentry, attr);if (error)
@@ -260,7 +260,7 @@ void affs_evict_inode(struct inode *inode) {unsigned long cache_page; -pr_debug ("evict_inode(ino=%lu, nlink=%u)\n" , +pr_debug ("evict_inode(ino=%llu, nlink=%u)\n" , inode->i_ino, inode->i_nlink);truncate_inode_pages_final (&inode->i_data);
@@ -353,7 +353,7 @@ affs_add_entry(struct inode *dir, struct inode *inode, struct dentry *dentry, s3u32 block =0 ;int retval; -pr_debug ("%s(dir=%lu, inode=%lu, \"%pd\", type=%d)\n" , __func__, +pr_debug ("%s(dir=%llu, inode=%llu, \"%pd\", type=%d)\n" , __func__, dir->i_ino, inode->i_ino, dentry, type); retval = -EIO ;
fs/affs/namei.c +7 -7
@@ -235,7 +235,7 @@ affs_lookup(struct inode *dir, struct dentry *dentry, unsigned int flags)int affs_unlink (struct inode *dir,struct dentry *dentry) { -pr_debug ("%s(dir=%lu, %lu \"%pd\")\n" , __func__, dir->i_ino, +pr_debug ("%s(dir=%llu, %llu \"%pd\")\n" , __func__, dir->i_ino,d_inode (dentry)->i_ino, dentry);return affs_remove_header (dentry);
@@ -249,7 +249,7 @@ affs_create(struct mnt_idmap *idmap, struct inode *dir,struct inode *inode;int error; -pr_debug ("%s(%lu,\"%pd\",0%ho)\n" , +pr_debug ("%s(%llu,\"%pd\",0%ho)\n" , __func__, dir->i_ino, dentry, mode); inode =affs_new_inode (dir);
@@ -280,7 +280,7 @@ affs_mkdir(struct mnt_idmap *idmap, struct inode *dir,struct inode *inode;int error; -pr_debug ("%s(%lu,\"%pd\",0%ho)\n" , +pr_debug ("%s(%llu,\"%pd\",0%ho)\n" , __func__, dir->i_ino, dentry, mode); inode =affs_new_inode (dir);
@@ -306,7 +306,7 @@ affs_mkdir(struct mnt_idmap *idmap, struct inode *dir,int affs_rmdir (struct inode *dir,struct dentry *dentry) { -pr_debug ("%s(dir=%lu, %lu \"%pd\")\n" , __func__, dir->i_ino, +pr_debug ("%s(dir=%llu, %llu \"%pd\")\n" , __func__, dir->i_ino,d_inode (dentry)->i_ino, dentry);return affs_remove_header (dentry);
@@ -323,7 +323,7 @@ affs_symlink(struct mnt_idmap *idmap, struct inode *dir,int i, maxlen, error;char c, lc; -pr_debug ("%s(%lu,\"%pd\" -> \"%s\")\n" , +pr_debug ("%s(%llu,\"%pd\" -> \"%s\")\n" , __func__, dir->i_ino, dentry, symname); maxlen =AFFS_SB (sb)->s_hashsize *sizeof (u32) -1 ;
@@ -395,7 +395,7 @@ affs_link(struct dentry *old_dentry, struct inode *dir, struct dentry *dentry) {struct inode *inode =d_inode (old_dentry); -pr_debug ("%s(%lu, %lu, \"%pd\")\n" , __func__, inode->i_ino, dir->i_ino, +pr_debug ("%s(%llu, %llu, \"%pd\")\n" , __func__, inode->i_ino, dir->i_ino, dentry);return affs_add_entry (dir, inode, dentry,ST_LINKFILE );
@@ -511,7 +511,7 @@ int affs_rename2(struct mnt_idmap *idmap, struct inode *old_dir,if (flags & ~(RENAME_NOREPLACE |RENAME_EXCHANGE ))return -EINVAL ; -pr_debug ("%s(old=%lu,\"%pd\" to new=%lu,\"%pd\")\n" , __func__, +pr_debug ("%s(old=%llu,\"%pd\" to new=%llu,\"%pd\")\n" , __func__, old_dir->i_ino, old_dentry, new_dir->i_ino, new_dentry);if (flags &RENAME_EXCHANGE )
fs/affs/symlink.c +1 -1
@@ -21,7 +21,7 @@ static int affs_symlink_read_folio(struct file *file, struct folio *folio)char c;char lc; -pr_debug ("get_link(ino=%lu)\n" , inode->i_ino); +pr_debug ("get_link(ino=%llu)\n" , inode->i_ino); bh =affs_bread (inode->i_sb, inode->i_ino);if (!bh)
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 20/61 afs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in afs for the i_ino type change from unsigned long to u64.
--- fs/afs/dir.c | 10 +++++----- fs/afs/dir_search.c | 2 +- fs/afs/dynroot.c | 2 +- fs/afs/inode.c | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-)
fs/afs/dir.c +5 -5
@@ -148,7 +148,7 @@ static bool afs_dir_check_block(struct afs_vnode *dvnode, size_t progress, union afs_xdr_dir_block *block) {if (block->hdr.magic !=AFS_DIR_MAGIC ) { -pr_warn ("%s(%lx): [%zx] bad magic %04x\n" , +pr_warn ("%s(%llx): [%zx] bad magic %04x\n" , __func__, dvnode->netfs.inode.i_ino, progress,ntohs (block->hdr.magic));trace_afs_dir_check_failed (dvnode, progress);
@@ -214,7 +214,7 @@ static int afs_dir_check(struct afs_vnode *dvnode)*/ static int afs_dir_open (struct inode *inode,struct file *file) { -_enter ("{%lu}" , inode->i_ino); +_enter ("{%llu}" , inode->i_ino);BUILD_BUG_ON (sizeof (union afs_xdr_dir_block ) !=2048 );BUILD_BUG_ON (sizeof (union afs_xdr_dirent ) !=32 );
@@ -523,7 +523,7 @@ static int afs_dir_iterate(struct inode *dir, struct dir_context *ctx,int retry_limit =100 ;int ret; -_enter ("{%lu},%llx,," , dir->i_ino, ctx->pos); +_enter ("{%llu},%llx,," , dir->i_ino, ctx->pos); do { if (--retry_limit < 0) {
@@ -610,7 +610,7 @@ static int afs_do_lookup_one(struct inode *dir, const struct qstr *name, };int ret; -_enter ("{%lu},{%.*s}," , dir->i_ino, name->len, name->name); +_enter ("{%llu},{%.*s}," , dir->i_ino, name->len, name->name);/* search the directory */ ret =afs_dir_iterate (dir, &cookie.ctx,NULL , _dir_version);
@@ -783,7 +783,7 @@ static struct inode *afs_do_lookup(struct inode *dir, struct dentry *dentry)long ret;int i; -_enter ("{%lu},%p{%pd}," , dir->i_ino, dentry, dentry); +_enter ("{%llu},%p{%pd}," , dir->i_ino, dentry, dentry); cookie = kzalloc_obj(struct afs_lookup_cookie);if (!cookie)
fs/afs/dir_search.c +1 -1
@@ -194,7 +194,7 @@ int afs_dir_search(struct afs_vnode *dvnode, const struct qstr *name,struct afs_dir_iter iter = { .dvnode = dvnode, };int ret, retry_limit =3 ; -_enter ("{%lu},,," , dvnode->netfs.inode.i_ino); +_enter ("{%llu},,," , dvnode->netfs.inode.i_ino);if (!afs_dir_init_iter (&iter, name))return -ENOENT ;
fs/afs/dynroot.c +1 -1
@@ -59,7 +59,7 @@ static struct inode *afs_iget_pseudo_dir(struct super_block *sb, ino_t ino)return ERR_PTR (-ENOMEM ); } -_debug ("GOT INODE %p { ino=%lu, vl=%llx, vn=%llx, u=%x }" , +_debug ("GOT INODE %p { ino=%llu, vl=%llx, vn=%llx, u=%x }" , inode, inode->i_ino, fid.vid, fid.vnode, fid.unique); vnode =AFS_FS_I (inode);
fs/afs/inode.c +1 -1
@@ -683,7 +683,7 @@ int afs_getattr(struct mnt_idmap *idmap, const struct path *path,struct key *key;int ret, seq; -_enter ("{ ino=%lu v=%u }" , inode->i_ino, inode->i_generation); +_enter ("{ ino=%llu v=%u }" , inode->i_ino, inode->i_generation); if (vnode->volume && !(query_flags & AT_STATX_DONT_SYNC) &&
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 21/61 autofs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in autofs for the i_ino type change from unsigned long to u64.
--- fs/autofs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/autofs/inode.c +1 -1
@@ -92,7 +92,7 @@ static int autofs_show_options(struct seq_file *m, struct dentry *root)seq_puts (m,",ignore" );#ifdef CONFIG_CHECKPOINT_RESTORE if (sbi->pipe) -seq_printf (m,",pipe_ino=%ld" ,file_inode (sbi->pipe)->i_ino); +seq_printf (m,",pipe_ino=%lld" ,file_inode (sbi->pipe)->i_ino);else seq_puts (m,",pipe_ino=-1" );#endif
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 22/61 befs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in befs for the i_ino type change from unsigned long to u64.
--- fs/befs/linuxvfs.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-)
fs/befs/linuxvfs.c +14 -14
@@ -140,20 +140,20 @@ befs_get_block(struct inode *inode, sector_t block,int res;ulong disk_off; -befs_debug (sb,"---> befs_get_block() for inode %lu, block %ld" , - (unsigned long )inode->i_ino, (long )block); +befs_debug (sb,"---> befs_get_block() for inode %llu, block %ld" , + (unsigned long long )inode->i_ino, (long )block);if (create) {befs_error (sb,"befs_get_block() was asked to write to " -"block %ld in inode %lu" , (long )block, - (unsigned long )inode->i_ino); +"block %ld in inode %llu" , (long )block, + (unsigned long long )inode->i_ino);return -EPERM ; } res =befs_fblock2brun (sb, ds, block, &run);if (res !=BEFS_OK ) {befs_error (sb, -"<--- %s for inode %lu, block %ld ERROR" , - __func__, (unsigned long )inode->i_ino, +"<--- %s for inode %llu, block %ld ERROR" , + __func__, (unsigned long long )inode->i_ino, (long )block);return -EFBIG ; }
@@ -162,8 +162,8 @@ befs_get_block(struct inode *inode, sector_t block,map_bh (bh_result, inode->i_sb, disk_off); -befs_debug (sb,"<--- %s for inode %lu, block %ld, disk address %lu" , - __func__, (unsigned long )inode->i_ino, (long )block, +befs_debug (sb,"<--- %s for inode %llu, block %ld, disk address %lu" , + __func__, (unsigned long long )inode->i_ino, (long )block, (unsigned long )disk_off);return 0 ;
@@ -181,7 +181,7 @@ befs_lookup(struct inode *dir, struct dentry *dentry, unsigned int flags)char *utfname;const char *name = dentry->d_name.name; -befs_debug (sb,"---> %s name %pd inode %ld" , __func__, +befs_debug (sb,"---> %s name %pd inode %lld" , __func__, dentry, dir->i_ino);/* Convert to UTF-8 */
@@ -224,7 +224,7 @@ befs_readdir(struct file *file, struct dir_context *ctx)size_t keysize;char keybuf[BEFS_NAME_LEN +1 ]; -befs_debug (sb,"---> %s name %pD, inode %ld, ctx->pos %lld" , +befs_debug (sb,"---> %s name %pD, inode %lld, ctx->pos %lld" , __func__, file, inode->i_ino, ctx->pos);while (1 ) {
@@ -233,7 +233,7 @@ befs_readdir(struct file *file, struct dir_context *ctx)if (result ==BEFS_ERR ) {befs_debug (sb,"<--- %s ERROR" , __func__); -befs_error (sb,"IO error reading %pD (inode %lu)" , +befs_error (sb,"IO error reading %pD (inode %llu)" , file, inode->i_ino);return -EIO ;
@@ -324,7 +324,7 @@ static struct inode *befs_iget(struct super_block *sb, unsigned long ino) bh =sb_bread (sb, inode->i_ino);if (!bh) {befs_error (sb,"unable to read inode block - " -"inode = %lu" , inode->i_ino); +"inode = %llu" , inode->i_ino); goto unacquire_none; }
@@ -333,7 +333,7 @@ static struct inode *befs_iget(struct super_block *sb, unsigned long ino)befs_dump_inode (sb, raw_inode);if (befs_check_inode (sb, raw_inode, inode->i_ino) !=BEFS_OK ) { -befs_error (sb,"Bad inode: %lu" , inode->i_ino); +befs_error (sb,"Bad inode: %llu" , inode->i_ino); goto unacquire_bh; }
@@ -407,7 +407,7 @@ static struct inode *befs_iget(struct super_block *sb, unsigned long ino) inode->i_op = &simple_symlink_inode_operations; } }else { -befs_error (sb,"Inode %lu is not a regular file, " +befs_error (sb,"Inode %llu is not a regular file, " "directory or symlink. THAT IS WRONG! BeFS has no " "on disk special files" , inode->i_ino); goto unacquire_bh;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 23/61 bfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in bfs for the i_ino type change from unsigned long to u64.
--- fs/bfs/dir.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/bfs/dir.c +2 -2
@@ -35,7 +35,7 @@ static int bfs_readdir(struct file *f, struct dir_context *ctx)int block;if (ctx->pos & (BFS_DIRENT_SIZE -1 )) { -printf ("Bad f_pos=%08lx for %s:%08lx\n" , +printf ("Bad f_pos=%08lx for %s:%08llx\n" , (unsigned long )ctx->pos, dir->i_sb->s_id, dir->i_ino);return -EINVAL ;
@@ -180,7 +180,7 @@ static int bfs_unlink(struct inode *dir, struct dentry *dentry) goto out_brelse;if (!inode->i_nlink) { -printf ("unlinking non-existent file %s:%lu (nlink=%d)\n" , +printf ("unlinking non-existent file %s:%llu (nlink=%d)\n" , inode->i_sb->s_id, inode->i_ino, inode->i_nlink);set_nlink (inode,1 );
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 24/61 cachefiles: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in cachefiles for the i_ino type change from unsigned long to u64.
--- fs/cachefiles/io.c | 6 +++--- fs/cachefiles/namei.c | 12 ++++++------ fs/cachefiles/xattr.c | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-)
fs/cachefiles/io.c +3 -3
@@ -93,7 +93,7 @@ static int cachefiles_read(struct netfs_cache_resources *cres, object =cachefiles_cres_object (cres); file =cachefiles_cres_file (cres); -_enter ("%pD,%li,%llx,%zx/%llx" , +_enter ("%pD,%llu,%llx,%zx/%llx" , file,file_inode (file)->i_ino, start_pos, len,i_size_read (file_inode (file)));
@@ -214,7 +214,7 @@ static int cachefiles_query_occupancy(struct netfs_cache_resources *cres, file =cachefiles_cres_file (cres); granularity =max_t (size_t, object->volume->cache->bsize, granularity); -_enter ("%pD,%li,%llx,%zx/%llx" , +_enter ("%pD,%llu,%llx,%zx/%llx" , file,file_inode (file)->i_ino, start, len,i_size_read (file_inode (file)));
@@ -294,7 +294,7 @@ int __cachefiles_write(struct cachefiles_object *object,fscache_count_write (); cache = object->volume->cache; -_enter ("%pD,%li,%llx,%zx/%llx" , +_enter ("%pD,%llu,%llx,%zx/%llx" , file,file_inode (file)->i_ino, start_pos, len,i_size_read (file_inode (file)));
fs/cachefiles/namei.c +6 -6
@@ -147,7 +147,7 @@ struct dentry *cachefiles_get_directory(struct cachefiles_cache *cache, }ASSERT (d_backing_inode (subdir)); -_debug ("mkdir -> %pd{ino=%lu}" , +_debug ("mkdir -> %pd{ino=%llu}" , subdir,d_backing_inode (subdir)->i_ino);if (_is_new) *_is_new = true;
@@ -158,7 +158,7 @@ struct dentry *cachefiles_get_directory(struct cachefiles_cache *cache,end_creating_keep (subdir);if (!__cachefiles_mark_inode_in_use (NULL ,d_inode (subdir))) { -pr_notice ("cachefiles: Inode already in use: %pd (B=%lx)\n" , +pr_notice ("cachefiles: Inode already in use: %pd (B=%llx)\n" , subdir,d_inode (subdir)->i_ino); goto mark_error; }
@@ -183,7 +183,7 @@ struct dentry *cachefiles_get_directory(struct cachefiles_cache *cache, !d_backing_inode(subdir)->i_op->unlink) goto check_error; -_leave (" = [%lu]" ,d_backing_inode (subdir)->i_ino); +_leave (" = [%llu]" ,d_backing_inode (subdir)->i_ino);return subdir; check_error:
@@ -529,7 +529,7 @@ static bool cachefiles_create_file(struct cachefiles_object *object)set_bit (FSCACHE_COOKIE_NEEDS_UPDATE , &object->cookie->flags);set_bit (CACHEFILES_OBJECT_USING_TMPFILE , &object->flags); -_debug ("create -> %pD{ino=%lu}" , file,file_inode (file)->i_ino); +_debug ("create -> %pD{ino=%llu}" , file,file_inode (file)->i_ino); object->file = file;return true; }
@@ -549,7 +549,7 @@ static bool cachefiles_open_file(struct cachefiles_object *object,_enter ("%pd" , dentry);if (!cachefiles_mark_inode_in_use (object,d_inode (dentry))) { -pr_notice ("cachefiles: Inode already in use: %pd (B=%lx)\n" , +pr_notice ("cachefiles: Inode already in use: %pd (B=%llx)\n" , dentry,d_inode (dentry)->i_ino);return false; }
@@ -657,7 +657,7 @@ bool cachefiles_look_up_object(struct cachefiles_object *object)if (!ret)return false; -_leave (" = t [%lu]" ,file_inode (object->file)->i_ino); +_leave (" = t [%llu]" ,file_inode (object->file)->i_ino);return true; new_file:
fs/cachefiles/xattr.c +1 -1
@@ -179,7 +179,7 @@ int cachefiles_remove_object_xattr(struct cachefiles_cache *cache, ret =0 ; else if (ret != -ENOMEM) cachefiles_io_error(cache, - "Can't remove xattr from %lu" + "Can't remove xattr from %llu" " (error %d)", d_backing_inode(dentry)->i_ino, -ret); }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 25/61 ceph: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ceph for the i_ino type change from unsigned long to u64.
--- fs/ceph/crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/ceph/crypto.c +2 -2
@@ -272,7 +272,7 @@ int ceph_encode_encrypted_dname(struct inode *parent, char *buf, int elen)/* To understand the 240 limit, see CEPH_NOHASH_NAME_MAX comments */ WARN_ON (elen >240 );if (dir != parent)// leading _ is already there; append _<inum> - elen +=1 +sprintf (p + elen,"_%ld" , dir->i_ino); + elen +=1 +sprintf (p + elen,"_%lld" , dir->i_ino); out:kfree (cryptbuf);
@@ -377,7 +377,7 @@ int ceph_fname_to_usr(const struct ceph_fname *fname, struct fscrypt_str *tname,if (!ret && (dir != fname->dir)) {char tmp_buf[BASE64_CHARS (NAME_MAX )]; - name_len =snprintf (tmp_buf,sizeof (tmp_buf),"_%.*s_%ld" , + name_len =snprintf (tmp_buf,sizeof (tmp_buf),"_%.*s_%lld" , oname->len, oname->name, dir->i_ino);memcpy (oname->name, tmp_buf, name_len); oname->len = name_len;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 26/61 coda: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in coda for the i_ino type change from unsigned long to u64.
--- fs/coda/dir.c | 2 +- fs/coda/inode.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
fs/coda/dir.c +1 -1
@@ -533,7 +533,7 @@ int coda_revalidate_inode(struct inode *inode)coda_vattr_to_iattr (inode, &attr);if ((old_mode &S_IFMT ) != (inode->i_mode &S_IFMT )) { -pr_warn ("inode %ld, fid %s changed type!\n" , +pr_warn ("inode %lld, fid %s changed type!\n" , inode->i_ino,coda_f2s (&(cii->c_fid))); }
fs/coda/inode.c +1 -1
@@ -257,7 +257,7 @@ static int coda_fill_super(struct super_block *sb, struct fs_context *fc) goto error; } -pr_info ("%s: rootinode is %ld dev %s\n" , +pr_info ("%s: rootinode is %lld dev %s\n" , __func__, root->i_ino, root->i_sb->s_id); sb->s_root =d_make_root (root);if (!sb->s_root) {
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 27/61 cramfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in cramfs for the i_ino type change from unsigned long to u64.
--- fs/cramfs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/cramfs/inode.c +1 -1
@@ -125,7 +125,7 @@ static struct inode *get_cramfs_inode(struct super_block *sb, old_decode_dev(cramfs_inode->size));break ;default : -printk (KERN_DEBUG "CRAMFS: Invalid file type 0%04o for inode %lu.\n" , +printk (KERN_DEBUG "CRAMFS: Invalid file type 0%04o for inode %llu.\n" , inode->i_mode, inode->i_ino);iget_failed (inode);return ERR_PTR (-EIO );
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 28/61 ecryptfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ecryptfs for the i_ino type change from unsigned long to u64.
--- fs/ecryptfs/crypto.c | 6 +++--- fs/ecryptfs/file.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)
fs/ecryptfs/crypto.c +3 -3
@@ -1313,7 +1313,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry) rc =ecryptfs_read_xattr_region (page_virt, ecryptfs_inode);if (rc) {printk (KERN_DEBUG "Valid eCryptfs headers not found in " -"file header region or xattr region, inode %lu\n" , +"file header region or xattr region, inode %llu\n" , ecryptfs_inode->i_ino); rc = -EINVAL ; goto out;
@@ -1323,7 +1323,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry) ECRYPTFS_DONT_VALIDATE_HEADER_SIZE);if (rc) {printk (KERN_DEBUG "Valid eCryptfs headers not found in " -"file xattr region either, inode %lu\n" , +"file xattr region either, inode %llu\n" , ecryptfs_inode->i_ino); rc = -EINVAL ; }
@@ -1335,7 +1335,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry)"crypto metadata only in the extended attribute " "region, but eCryptfs was mounted without " "xattr support enabled. eCryptfs will not treat " -"this like an encrypted file, inode %lu\n" , +"this like an encrypted file, inode %llu\n" , ecryptfs_inode->i_ino); rc = -EINVAL ; }
fs/ecryptfs/file.c +1 -1
@@ -253,7 +253,7 @@ static int ecryptfs_open(struct inode *inode, struct file *file)if (rc) goto out_put;ecryptfs_printk (KERN_DEBUG ,"inode w/ addr = [0x%p], i_ino = " -"[0x%.16lx] size: [0x%.16llx]\n" , inode, inode->i_ino, +"[0x%.16llx] size: [0x%.16llx]\n" , inode, inode->i_ino, (unsigned long long )i_size_read (inode)); goto out; out_put:
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 29/61 efs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in efs for the i_ino type change from unsigned long to u64.
--- fs/efs/inode.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
fs/efs/inode.c +3 -3
@@ -132,7 +132,7 @@ struct inode *efs_iget(struct super_block *super, unsigned long ino)for (i =0 ; i <EFS_DIRECTEXTENTS ; i++) {extent_copy (&(efs_inode->di_u.di_extents[i]), &(in->extents[i]));if (i < in->numextents && in->extents[i].cooked.ex_magic !=0 ) { -pr_warn ("extent %d has bad magic number in inode %lu\n" , +pr_warn ("extent %d has bad magic number in inode %llu\n" , i, inode->i_ino);brelse (bh); goto read_inode_error;
@@ -140,7 +140,7 @@ struct inode *efs_iget(struct super_block *super, unsigned long ino) }brelse (bh); -pr_debug ("efs_iget(): inode %lu, extents %d, mode %o\n" , +pr_debug ("efs_iget(): inode %llu, extents %d, mode %o\n" , inode->i_ino, in->numextents, inode->i_mode);switch (inode->i_mode &S_IFMT ) {case S_IFDIR :
@@ -171,7 +171,7 @@ struct inode *efs_iget(struct super_block *super, unsigned long ino)return inode; read_inode_error: -pr_warn ("failed to read inode %lu\n" , inode->i_ino); +pr_warn ("failed to read inode %llu\n" , inode->i_ino);iget_failed (inode);return ERR_PTR (-EIO ); }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 30/61 exportfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in exportfs for the i_ino type change from unsigned long to u64.
--- fs/exportfs/expfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/exportfs/expfs.c +2 -2
@@ -130,12 +130,12 @@ static struct dentry *reconnect_one(struct vfsmount *mnt, parent = mnt->mnt_sb->s_export_op->get_parent (dentry);if (IS_ERR (parent)) { -dprintk ("get_parent of %lu failed, err %ld\n" , +dprintk ("get_parent of %llu failed, err %ld\n" , dentry->d_inode->i_ino,PTR_ERR (parent));return parent; } -dprintk ("%s: find name of %lu in %lu\n" , __func__, +dprintk ("%s: find name of %llu in %llu\n" , __func__, dentry->d_inode->i_ino, parent->d_inode->i_ino); err =exportfs_get_name (mnt, parent, nbuf, dentry);if (err == -ENOENT )
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 31/61 ext2: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ext2 for the i_ino type change from unsigned long to u64.
--- fs/ext2/dir.c | 10 +++++----- fs/ext2/ialloc.c | 9 +++++---- fs/ext2/inode.c | 2 +- fs/ext2/xattr.c | 14 +++++++------- 4 files changed, 18 insertions(+), 17 deletions(-)
fs/ext2/dir.c +5 -5
@@ -141,7 +141,7 @@ static bool ext2_check_folio(struct folio *folio, int quiet, char *kaddr) Ebadsize:if (!quiet)ext2_error (sb, __func__, -"size of directory #%lu is not a multiple " +"size of directory #%llu is not a multiple " "of chunk size" , dir->i_ino); goto fail; Eshort:
@@ -160,7 +160,7 @@ static bool ext2_check_folio(struct folio *folio, int quiet, char *kaddr) error ="inode out of bounds" ; bad_entry:if (!quiet) - ext2_error(sb, __func__, "bad entry in directory #%lu: : %s - " + ext2_error(sb, __func__, "bad entry in directory #%llu: : %s - " "offset=%llu, inode=%lu, rec_len=%d, name_len=%d", dir->i_ino, error, folio_pos(folio) + offs, (unsigned long) le32_to_cpu(p->inode),
@@ -170,7 +170,7 @@ static bool ext2_check_folio(struct folio *folio, int quiet, char *kaddr)if (!quiet) { p = (ext2_dirent *)(kaddr + offs);ext2_error (sb,"ext2_check_folio" , -"entry in directory #%lu spans the page boundary" +"entry in directory #%llu spans the page boundary" "offset=%llu, inode=%lu" , dir->i_ino,folio_pos (folio) + offs, (unsigned long )le32_to_cpu (p->inode));
@@ -281,7 +281,7 @@ ext2_readdir(struct file *file, struct dir_context *ctx)if (IS_ERR (kaddr)) {ext2_error (sb, __func__, -"bad page in #%lu" , +"bad page in #%llu" , inode->i_ino); ctx->pos +=PAGE_SIZE - offset;return PTR_ERR (kaddr);
@@ -383,7 +383,7 @@ struct ext2_dir_entry_2 *ext2_find_entry (struct inode *dir,/* next folio is past the blocks we've got */ if (unlikely (n > (dir->i_blocks >> (PAGE_SHIFT -9 )))) {ext2_error (dir->i_sb, __func__, -"dir %lu size %lld exceeds block count %llu" , +"dir %llu size %lld exceeds block count %llu" , dir->i_ino, dir->i_size, (unsigned long long )dir->i_blocks); goto out;
fs/ext2/ialloc.c +5 -4
@@ -169,9 +169,10 @@ static void ext2_preread_inode(struct inode *inode)unsigned long block_group;unsigned long offset;unsigned long block; +unsigned int ino = inode->i_ino;struct ext2_group_desc * gdp; - block_group = (inode->i_ino -1 ) /EXT2_INODES_PER_GROUP (inode->i_sb); + block_group = (ino -1 ) /EXT2_INODES_PER_GROUP (inode->i_sb); gdp =ext2_get_group_desc (inode->i_sb, block_group,NULL );if (gdp ==NULL )return ;
@@ -179,7 +180,7 @@ static void ext2_preread_inode(struct inode *inode)/* * Figure out the offset within the block group inode table */ - offset = ((inode->i_ino -1 ) %EXT2_INODES_PER_GROUP (inode->i_sb)) * + offset = ((ino -1 ) %EXT2_INODES_PER_GROUP (inode->i_sb)) *EXT2_INODE_SIZE (inode->i_sb); block =le32_to_cpu (gdp->bg_inode_table) + (offset >>EXT2_BLOCK_SIZE_BITS (inode->i_sb));
@@ -381,7 +382,7 @@ static int find_group_other(struct super_block *sb, struct inode *parent)* * So add our directory's i_ino into the starting point for the hash. */ - group = (group + parent->i_ino) % ngroups; + group = (group + (unsigned int )parent->i_ino) % ngroups;/* * Use a quadratic hash to find a group with a free inode and some
@@ -589,7 +590,7 @@ struct inode *ext2_new_inode(struct inode *dir, umode_t mode, goto fail_free_drop;mark_inode_dirty (inode); -ext2_debug ("allocating inode %lu\n" , inode->i_ino); +ext2_debug ("allocating inode %llu\n" , inode->i_ino);ext2_preread_inode (inode);return inode;
fs/ext2/inode.c +1 -1
@@ -1152,7 +1152,7 @@ static void ext2_free_branches(struct inode *inode, __le32 *p, __le32 *q, int de*/ if (!bh) {ext2_error (inode->i_sb,"ext2_free_branches" , -"Read failure, inode=%ld, block=%ld" , +"Read failure, inode=%lld, block=%ld" , inode->i_ino, nr);continue ; }
fs/ext2/xattr.c +7 -7
@@ -227,7 +227,7 @@ ext2_xattr_get(struct inode *inode, int name_index, const char *name,if (!ext2_xattr_header_valid (HDR (bh))) { bad_block:ext2_error (inode->i_sb,"ext2_xattr_get" , -"inode %ld: bad block %d" , inode->i_ino, +"inode %llu: bad block %d" , inode->i_ino,EXT2_I (inode)->i_file_acl); error = -EIO ; goto cleanup;
@@ -313,7 +313,7 @@ ext2_xattr_list(struct dentry *dentry, char *buffer, size_t buffer_size)if (!ext2_xattr_header_valid (HDR (bh))) { bad_block:ext2_error (inode->i_sb,"ext2_xattr_list" , -"inode %ld: bad block %d" , inode->i_ino, +"inode %llu: bad block %d" , inode->i_ino,EXT2_I (inode)->i_file_acl); error = -EIO ; goto cleanup;
@@ -454,7 +454,7 @@ ext2_xattr_set(struct inode *inode, int name_index, const char *name,if (!ext2_xattr_header_valid (header)) { bad_block:ext2_error (sb,"ext2_xattr_set" , -"inode %ld: bad block %d" , inode->i_ino, +"inode %llu: bad block %d" , inode->i_ino,EXT2_I (inode)->i_file_acl); error = -EIO ; goto cleanup;
@@ -833,7 +833,7 @@ ext2_xattr_delete_inode(struct inode *inode)if (!ext2_data_block_valid (sbi,EXT2_I (inode)->i_file_acl,1 )) {ext2_error (inode->i_sb,"ext2_xattr_delete_inode" , -"inode %ld: xattr block %d is out of data blocks range" , +"inode %lld: xattr block %d is out of data blocks range" , inode->i_ino,EXT2_I (inode)->i_file_acl); goto cleanup; }
@@ -841,14 +841,14 @@ ext2_xattr_delete_inode(struct inode *inode) bh =sb_bread (inode->i_sb,EXT2_I (inode)->i_file_acl);if (!bh) {ext2_error (inode->i_sb,"ext2_xattr_delete_inode" , -"inode %ld: block %d read error" , inode->i_ino, +"inode %llu: block %d read error" , inode->i_ino,EXT2_I (inode)->i_file_acl); goto cleanup; }ea_bdebug (bh,"b_count=%d" ,atomic_read (&(bh->b_count)));if (!ext2_xattr_header_valid (HDR (bh))) {ext2_error (inode->i_sb,"ext2_xattr_delete_inode" , -"inode %ld: bad block %d" , inode->i_ino, +"inode %llu: bad block %d" , inode->i_ino,EXT2_I (inode)->i_file_acl); goto cleanup; }
@@ -952,7 +952,7 @@ ext2_xattr_cache_find(struct inode *inode, struct ext2_xattr_header *header) bh =sb_bread (inode->i_sb, ce->e_value);if (!bh) {ext2_error (inode->i_sb,"ext2_xattr_cache_find" , -"inode %ld: block %ld read error" , +"inode %lld: block %ld read error" , inode->i_ino, (unsigned long ) ce->e_value); }else {lock_buffer (bh);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 32/61 freevxfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in freevxfs for the i_ino type change from unsigned long to u64.
--- fs/freevxfs/vxfs_bmap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/freevxfs/vxfs_bmap.c +2 -2
@@ -260,12 +260,12 @@ vxfs_bmap1(struct inode *ip, long iblock)if (VXFS_ISIMMED (vip)) goto unsupp; -printk (KERN_WARNING "vxfs: inode %ld has no valid orgtype (%x)\n" , +printk (KERN_WARNING "vxfs: inode %lld has no valid orgtype (%x)\n" , ip->i_ino, vip->vii_orgtype);BUG (); unsupp: -printk (KERN_WARNING "vxfs: inode %ld has an unsupported orgtype (%x)\n" , +printk (KERN_WARNING "vxfs: inode %lld has an unsupported orgtype (%x)\n" , ip->i_ino, vip->vii_orgtype);return 0 ; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 33/61 hfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in hfs for the i_ino type change from unsigned long to u64.
--- fs/hfs/catalog.c | 2 +- fs/hfs/extent.c | 4 ++-- fs/hfs/inode.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-)
fs/hfs/catalog.c +1 -1
@@ -417,7 +417,7 @@ int hfs_cat_move(u32 cnid, struct inode *src_dir, const struct qstr *src_name,int entry_size, type;int err; -hfs_dbg ("cnid %u - (ino %lu, name %s) - (ino %lu, name %s)\n" , +hfs_dbg ("cnid %u - (ino %llu, name %s) - (ino %llu, name %s)\n" , cnid, src_dir->i_ino, src_name->name, dst_dir->i_ino, dst_name->name); sb = src_dir->i_sb;
fs/hfs/extent.c +2 -2
@@ -411,7 +411,7 @@ int hfs_extend_file(struct inode *inode) goto out; } -hfs_dbg ("ino %lu, start %u, len %u\n" , inode->i_ino, start, len); +hfs_dbg ("ino %llu, start %u, len %u\n" , inode->i_ino, start, len);if (HFS_I (inode)->alloc_blocks ==HFS_I (inode)->first_blocks) {if (!HFS_I (inode)->first_blocks) { hfs_dbg("first_extent: start %u, len %u\n",
@@ -482,7 +482,7 @@ void hfs_file_truncate(struct inode *inode)u32 size;int res; -hfs_dbg ("ino %lu, phys_size %llu -> i_size %llu\n" , +hfs_dbg ("ino %llu, phys_size %llu -> i_size %llu\n" , inode->i_ino, (long long )HFS_I (inode)->phys_size, inode->i_size);if (inode->i_size >HFS_I (inode)->phys_size) {
fs/hfs/inode.c +2 -2
@@ -270,7 +270,7 @@ void hfs_delete_inode(struct inode *inode) {struct super_block *sb = inode->i_sb; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino);if (S_ISDIR (inode->i_mode)) {atomic64_dec (&HFS_SB (sb)->folder_count);if (HFS_I (inode)->cat_key.ParID ==cpu_to_be32 (HFS_ROOT_CNID ))
@@ -455,7 +455,7 @@ int hfs_write_inode(struct inode *inode, struct writeback_control *wbc)hfs_cat_rec rec;int res; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino); res =hfs_ext_write_extent (inode);if (res)return res;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 34/61 hfsplus: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in hfsplus for the i_ino type change from unsigned long to u64.
--- fs/hfsplus/attributes.c | 10 +++++----- fs/hfsplus/catalog.c | 2 +- fs/hfsplus/dir.c | 6 +++--- fs/hfsplus/extents.c | 6 +++--- fs/hfsplus/inode.c | 8 ++++---- fs/hfsplus/super.c | 6 +++--- fs/hfsplus/xattr.c | 10 +++++----- 7 files changed, 24 insertions(+), 24 deletions(-)
fs/hfsplus/attributes.c +5 -5
@@ -203,7 +203,7 @@ int hfsplus_create_attr_nolock(struct inode *inode, const char *name,int entry_size;int err; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (name) {
@@ -255,7 +255,7 @@ int hfsplus_create_attr(struct inode *inode,hfsplus_attr_entry *entry_ptr;int err; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (!HFSPLUS_SB (sb)->attr_tree) {
@@ -337,7 +337,7 @@ int hfsplus_delete_attr_nolock(struct inode *inode, const char *name,struct super_block *sb = inode->i_sb;int err; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (name) {
@@ -367,7 +367,7 @@ int hfsplus_delete_attr(struct inode *inode, const char *name)struct super_block *sb = inode->i_sb;struct hfs_find_data fd; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (!HFSPLUS_SB (sb)->attr_tree) {
@@ -436,7 +436,7 @@ int hfsplus_replace_attr(struct inode *inode,hfsplus_attr_entry *entry_ptr;int err =0 ; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (!HFSPLUS_SB (sb)->attr_tree) {
fs/hfsplus/catalog.c +1 -1
@@ -441,7 +441,7 @@ int hfsplus_rename_cat(u32 cnid,int entry_size, type;int err; -hfs_dbg ("cnid %u - ino %lu, name %s - ino %lu, name %s\n" , +hfs_dbg ("cnid %u - ino %llu, name %s - ino %llu, name %s\n" , cnid, src_dir->i_ino, src_name->name, dst_dir->i_ino, dst_name->name); err =hfs_find_init (HFSPLUS_SB (sb)->cat_tree, &src_fd);
fs/hfsplus/dir.c +3 -3
@@ -313,7 +313,7 @@ static int hfsplus_link(struct dentry *src_dentry, struct inode *dst_dir,if (!S_ISREG (inode->i_mode))return -EPERM ; -hfs_dbg ("src_dir->i_ino %lu, dst_dir->i_ino %lu, inode->i_ino %lu\n" , +hfs_dbg ("src_dir->i_ino %llu, dst_dir->i_ino %llu, inode->i_ino %llu\n" , src_dir->i_ino, dst_dir->i_ino, inode->i_ino);mutex_lock (&sbi->vh_mutex);
@@ -385,7 +385,7 @@ static int hfsplus_unlink(struct inode *dir, struct dentry *dentry)if (HFSPLUS_IS_RSRC (inode))return -EPERM ; -hfs_dbg ("dir->i_ino %lu, inode->i_ino %lu\n" , +hfs_dbg ("dir->i_ino %llu, inode->i_ino %llu\n" , dir->i_ino, inode->i_ino);mutex_lock (&sbi->vh_mutex);
@@ -393,7 +393,7 @@ static int hfsplus_unlink(struct inode *dir, struct dentry *dentry)if (inode->i_ino == cnid &&atomic_read (&HFSPLUS_I (inode)->opencnt)) { str.name = name; - str.len =sprintf (name,"temp%lu" , inode->i_ino); + str.len =sprintf (name,"temp%llu" , inode->i_ino); res =hfsplus_rename_cat (inode->i_ino, dir, &dentry->d_name, sbi->hidden_dir, &str);
fs/hfsplus/extents.c +3 -3
@@ -275,7 +275,7 @@ int hfsplus_get_block(struct inode *inode, sector_t iblock,mutex_unlock (&hip->extents_lock); done: -hfs_dbg ("ino %lu, iblock %llu - dblock %u\n" , +hfs_dbg ("ino %llu, iblock %llu - dblock %u\n" , inode->i_ino, (long long )iblock, dblock); mask = (1 << sbi->fs_shift) -1 ;
@@ -476,7 +476,7 @@ int hfsplus_file_extend(struct inode *inode, bool zeroout) goto out; } -hfs_dbg ("ino %lu, start %u, len %u\n" , inode->i_ino, start, len); +hfs_dbg ("ino %llu, start %u, len %u\n" , inode->i_ino, start, len);if (hip->alloc_blocks <= hip->first_blocks) {if (!hip->first_blocks) {
@@ -545,7 +545,7 @@ void hfsplus_file_truncate(struct inode *inode)u32 alloc_cnt, blk_cnt, start;int res; -hfs_dbg ("ino %lu, phys_size %llu -> i_size %llu\n" , +hfs_dbg ("ino %llu, phys_size %llu -> i_size %llu\n" , inode->i_ino, (long long )hip->phys_size, inode->i_size);if (inode->i_size > hip->phys_size) {
fs/hfsplus/inode.c +4 -4
@@ -230,7 +230,7 @@ static int hfsplus_get_perms(struct inode *inode, inode->i_flags &= ~S_APPEND ;return 0 ; bad_type: -pr_err ("invalid file type 0%04o for inode %lu\n" , mode, inode->i_ino); +pr_err ("invalid file type 0%04o for inode %llu\n" , mode, inode->i_ino);return -EIO ; }
@@ -328,7 +328,7 @@ int hfsplus_file_fsync(struct file *file, loff_t start, loff_t end,struct hfsplus_vh *vhdr = sbi->s_vhdr;int error =0 , error2; -hfs_dbg ("inode->i_ino %lu, start %llu, end %llu\n" , +hfs_dbg ("inode->i_ino %llu, start %llu, end %llu\n" , inode->i_ino, start, end); error =file_write_and_wait_range (file, start, end);
@@ -639,7 +639,7 @@ int hfsplus_cat_write_inode(struct inode *inode)hfsplus_cat_entry entry;int res =0 ; -hfs_dbg ("inode->i_ino %lu\n" , inode->i_ino); +hfs_dbg ("inode->i_ino %llu\n" , inode->i_ino);if (HFSPLUS_IS_RSRC (inode)) main_inode =HFSPLUS_I (inode)->rsrc_inode;
@@ -716,7 +716,7 @@ int hfsplus_cat_write_inode(struct inode *inode)if (!res) { res =hfs_btree_write (tree);if (res) { -pr_err ("b-tree write err: %d, ino %lu\n" , +pr_err ("b-tree write err: %d, ino %llu\n" , res, inode->i_ino); } }
fs/hfsplus/super.c +3 -3
@@ -156,7 +156,7 @@ static int hfsplus_system_write_inode(struct inode *inode)int err =hfs_btree_write (tree);if (err) { -pr_err ("b-tree write err: %d, ino %lu\n" , +pr_err ("b-tree write err: %d, ino %llu\n" , err, inode->i_ino);return err; }
@@ -169,7 +169,7 @@ static int hfsplus_write_inode(struct inode *inode, {int err; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino); err =hfsplus_ext_write_extent (inode);if (err)
@@ -184,7 +184,7 @@ static int hfsplus_write_inode(struct inode *inode,static void hfsplus_evict_inode (struct inode *inode) { -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino);truncate_inode_pages_final (&inode->i_data);clear_inode (inode);if (HFSPLUS_IS_RSRC (inode)) {
fs/hfsplus/xattr.c +5 -5
@@ -277,7 +277,7 @@ int __hfsplus_setxattr(struct inode *inode, const char *name,u16 folder_finderinfo_len =sizeof (DInfo) +sizeof (DXInfo);u16 file_finderinfo_len =sizeof (FInfo) +sizeof (FXInfo); -hfs_dbg ("ino %lu, name %s, value %p, size %zu\n" , +hfs_dbg ("ino %llu, name %s, value %p, size %zu\n" , inode->i_ino, name ? name :NULL , value, size);
@@ -447,7 +447,7 @@ int hfsplus_setxattr(struct inode *inode, const char *name,NLS_MAX_CHARSET_SIZE *HFSPLUS_ATTR_MAX_STRLEN +1 ;int res; - hfs_dbg("ino %lu, name %s, prefix %s, prefixlen %zu, " + hfs_dbg("ino %llu, name %s, prefix %s, prefixlen %zu, " "value %p, size %zu\n", inode->i_ino, name ? name : NULL, prefix ? prefix : NULL, prefixlen,
@@ -607,7 +607,7 @@ ssize_t hfsplus_getxattr(struct inode *inode, const char *name,int res;char *xattr_name; -hfs_dbg ("ino %lu, name %s, prefix %s\n" , +hfs_dbg ("ino %llu, name %s, prefix %s\n" , inode->i_ino, name ? name :NULL , prefix ? prefix :NULL );
@@ -717,7 +717,7 @@ ssize_t hfsplus_listxattr(struct dentry *dentry, char *buffer, size_t size)size_t strbuf_size;int xattr_name_len; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino);if (!is_xattr_operation_supported (inode))return -EOPNOTSUPP ;
@@ -819,7 +819,7 @@ static int hfsplus_removexattr(struct inode *inode, const char *name)int is_xattr_acl_deleted;int is_all_xattrs_deleted; -hfs_dbg ("ino %lu, name %s\n" , +hfs_dbg ("ino %llu, name %s\n" , inode->i_ino, name ? name :NULL );if (!HFSPLUS_SB (inode->i_sb)->attr_tree)
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 35/61 hpfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in hpfs for the i_ino type change from unsigned long to u64.
--- fs/hpfs/dir.c | 4 ++-- fs/hpfs/dnode.c | 4 ++-- fs/hpfs/ea.c | 4 ++-- fs/hpfs/inode.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-)
fs/hpfs/dir.c +2 -2
@@ -96,8 +96,8 @@ static int hpfs_readdir(struct file *file, struct dir_context *ctx) }if (!fnode_is_dir (fno)) { e =1 ; -hpfs_error (inode->i_sb,"not a directory, fnode %08lx" , - (unsigned long )inode->i_ino); +hpfs_error (inode->i_sb,"not a directory, fnode %08llx" , + (unsigned long long )inode->i_ino); }if (hpfs_inode->i_dno !=le32_to_cpu (fno->u.external[0 ].disk_secno)) { e =1 ;
fs/hpfs/dnode.c +2 -2
@@ -550,9 +550,9 @@ static void delete_empty_dnode(struct inode *i, dnode_secno dno)if (hpfs_sb (i->i_sb)->sb_chk)if (up != i->i_ino) {hpfs_error (i->i_sb, -"bad pointer to fnode, dnode %08x, pointing to %08x, should be %08lx" , +"bad pointer to fnode, dnode %08x, pointing to %08x, should be %08llx" , dno, up, - (unsigned long )i->i_ino); + (unsigned long long )i->i_ino);return ; }if ((d1 =hpfs_map_dnode (i->i_sb, down, &qbh1))) {
fs/hpfs/ea.c +2 -2
@@ -245,8 +245,8 @@ void hpfs_set_ea(struct inode *inode, struct fnode *fnode, const char *key, fnode->ea_offs =cpu_to_le16 (0xc4 ); }if (le16_to_cpu (fnode->ea_offs) <0xc4 ||le16_to_cpu (fnode->ea_offs) +le16_to_cpu (fnode->acl_size_s) +le16_to_cpu (fnode->ea_size_s) >0x200 ) { -hpfs_error (s,"fnode %08lx: ea_offs == %03x, ea_size_s == %03x" , - (unsigned long )inode->i_ino, +hpfs_error (s,"fnode %08llx: ea_offs == %03x, ea_size_s == %03x" , + (unsigned long long )inode->i_ino,le16_to_cpu (fnode->ea_offs),le16_to_cpu (fnode->ea_size_s));return ; }
fs/hpfs/inode.c +2 -2
@@ -250,8 +250,8 @@ void hpfs_write_inode_nolock(struct inode *i)hpfs_brelse4 (&qbh); }else hpfs_error (i->i_sb, -"directory %08lx doesn't have '.' entry" , - (unsigned long )i->i_ino); +"directory %08llx doesn't have '.' entry" , + (unsigned long long )i->i_ino); }mark_buffer_dirty (bh);brelse (bh);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 36/61 isofs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in isofs for the i_ino type change from unsigned long to u64.
--- fs/isofs/compress.c | 2 +- fs/isofs/dir.c | 2 +- fs/isofs/inode.c | 6 +++--- fs/isofs/namei.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-)
fs/isofs/compress.c +1 -1
@@ -156,7 +156,7 @@ static loff_t zisofs_uncompress_block(struct inode *inode, loff_t block_start,else { printk(KERN_DEBUG "zisofs: zisofs_inflate returned" - " %d, inode = %lu," + " %d, inode = %llu," " page idx = %d, bh idx = %d," " avail_in = %ld," " avail_out = %ld\n",
fs/isofs/dir.c +1 -1
@@ -152,7 +152,7 @@ static int do_isofs_readdir(struct inode *inode, struct file *file, de_len < de->name_len[0] + sizeof(struct iso_directory_record)) {printk (KERN_NOTICE "iso9660: Corrupted directory entry" -" in block %lu of inode %lu\n" , block, +" in block %lu of inode %llu\n" , block, inode->i_ino);brelse (bh);return -EIO ;
fs/isofs/inode.c +3 -3
@@ -1261,7 +1261,7 @@ static int isofs_read_level3_size(struct inode *inode) out_toomany:printk (KERN_INFO "%s: More than 100 file sections ?!?, aborting...\n" -"isofs_read_level3_size: inode=%lu\n" , +"isofs_read_level3_size: inode=%llu\n" , __func__, inode->i_ino); goto out; }
@@ -1380,7 +1380,7 @@ static int isofs_read_inode(struct inode *inode, int relocated)/* I have no idea what file_unit_size is used for, so we will flag it for now */ if (de->file_unit_size[0 ] !=0 ) { -printk (KERN_DEBUG "ISOFS: File unit size != 0 for ISO file (%ld).\n" , +printk (KERN_DEBUG "ISOFS: File unit size != 0 for ISO file (%lld).\n" , inode->i_ino); }
@@ -1450,7 +1450,7 @@ static int isofs_read_inode(struct inode *inode, int relocated)/* XXX - parse_rock_ridge_inode() had already set i_rdev. */ init_special_inode (inode, inode->i_mode, inode->i_rdev); }else { -printk (KERN_DEBUG "ISOFS: Invalid file type 0%04o for inode %lu.\n" , +printk (KERN_DEBUG "ISOFS: Invalid file type 0%04o for inode %llu.\n" , inode->i_mode, inode->i_ino); ret = -EIO ; goto fail;
fs/isofs/namei.c +1 -1
@@ -100,7 +100,7 @@ isofs_find_entry(struct inode *dir, struct dentry *dentry,/* Basic sanity check, whether name doesn't exceed dir entry */ if (de_len < dlen +sizeof (struct iso_directory_record )) {printk (KERN_NOTICE "iso9660: Corrupted directory entry" -" in block %lu of inode %lu\n" , block, +" in block %lu of inode %llu\n" , block, dir->i_ino);brelse (bh);return 0 ;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 37/61 jffs2: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in jffs2 for the i_ino type change from unsigned long to u64.
--- fs/jffs2/dir.c | 4 ++-- fs/jffs2/file.c | 4 ++-- fs/jffs2/fs.c | 18 +++++++++--------- 3 files changed, 13 insertions(+), 13 deletions(-)
fs/jffs2/dir.c +2 -2
@@ -129,7 +129,7 @@ static int jffs2_readdir(struct file *file, struct dir_context *ctx)struct jffs2_full_dirent *fd;unsigned long curofs =1 ; -jffs2_dbg (1 ,"jffs2_readdir() for dir_i #%lu\n" , inode->i_ino); +jffs2_dbg (1 ,"jffs2_readdir() for dir_i #%llu\n" , inode->i_ino);if (!dir_emit_dots (file, ctx))return 0 ;
@@ -211,7 +211,7 @@ static int jffs2_create(struct mnt_idmap *idmap, struct inode *dir_i,jffs2_free_raw_inode (ri); -jffs2_dbg (1 ,"%s(): Created ino #%lu with mode %o, nlink %d(%d). nrpages %ld\n" , +jffs2_dbg (1 ,"%s(): Created ino #%llu with mode %o, nlink %d(%d). nrpages %ld\n" , __func__, inode->i_ino, inode->i_mode, inode->i_nlink, f->inocache->pino_nlink, inode->i_mapping->nrpages);
fs/jffs2/file.c +2 -2
@@ -88,7 +88,7 @@ static int jffs2_do_readpage_nolock(struct inode *inode, struct folio *folio)unsigned char *kaddr;int ret; -jffs2_dbg (2 ,"%s(): ino #%lu, page at offset 0x%lx\n" , +jffs2_dbg (2 ,"%s(): ino #%llu, page at offset 0x%lx\n" , __func__, inode->i_ino, folio->index <<PAGE_SHIFT );BUG_ON (!folio_test_locked (folio));
@@ -259,7 +259,7 @@ static int jffs2_write_end(const struct kiocb *iocb,uint32_t writtenlen =0 ;void *buf; -jffs2_dbg (1 ,"%s(): ino #%lu, page at 0x%llx, range %d-%d, flags %lx\n" , +jffs2_dbg (1 ,"%s(): ino #%llu, page at 0x%llx, range %d-%d, flags %lx\n" , __func__, inode->i_ino,folio_pos (folio), start, end, folio->flags.f);
fs/jffs2/fs.c +9 -9
@@ -43,7 +43,7 @@ int jffs2_do_setattr (struct inode *inode, struct iattr *iattr)int ret;int alloc_type =ALLOC_NORMAL ; -jffs2_dbg (1 ,"%s(): ino #%lu\n" , __func__, inode->i_ino); +jffs2_dbg (1 ,"%s(): ino #%llu\n" , __func__, inode->i_ino);/* Special cases - we don't want more than one data node for these types on the medium at any time. So setattr
@@ -243,7 +243,7 @@ void jffs2_evict_inode (struct inode *inode)struct jffs2_sb_info *c =JFFS2_SB_INFO (inode->i_sb);struct jffs2_inode_info *f =JFFS2_INODE_INFO (inode); -jffs2_dbg (1 ,"%s(): ino #%lu mode %o\n" , +jffs2_dbg (1 ,"%s(): ino #%llu mode %o\n" , __func__, inode->i_ino, inode->i_mode);truncate_inode_pages_final (&inode->i_data);clear_inode (inode);
@@ -334,8 +334,8 @@ struct inode *jffs2_iget(struct super_block *sb, unsigned long ino) ret =jffs2_read_dnode (c, f, f->metadata, (char *)&jdev,0 , f->metadata->size);if (ret <0 ) {/* Eep */ -pr_notice ("Read device numbers for inode %lu failed\n" , - (unsigned long )inode->i_ino); +pr_notice ("Read device numbers for inode %llu failed\n" , + (unsigned long long )inode->i_ino); goto error; }if (f->metadata->size ==sizeof (jdev.old_id))
@@ -351,8 +351,8 @@ struct inode *jffs2_iget(struct super_block *sb, unsigned long ino)break ;default : -pr_warn ("%s(): Bogus i_mode %o for ino %lu\n" , - __func__, inode->i_mode, (unsigned long )inode->i_ino); +pr_warn ("%s(): Bogus i_mode %o for ino %llu\n" , + __func__, inode->i_mode, (unsigned long long )inode->i_ino); }mutex_unlock (&f->sem);
@@ -374,12 +374,12 @@ void jffs2_dirty_inode(struct inode *inode, int flags)struct iattr iattr;if (!(inode_state_read_once (inode) &I_DIRTY_DATASYNC )) { -jffs2_dbg (2 ,"%s(): not calling setattr() for ino #%lu\n" , +jffs2_dbg (2 ,"%s(): not calling setattr() for ino #%llu\n" , __func__, inode->i_ino);return ; } -jffs2_dbg (1 ,"%s(): calling setattr() for ino #%lu\n" , +jffs2_dbg (1 ,"%s(): calling setattr() for ino #%llu\n" , __func__, inode->i_ino); iattr.ia_valid =ATTR_MODE |ATTR_UID |ATTR_GID |ATTR_ATIME |ATTR_MTIME |ATTR_CTIME ;
@@ -428,7 +428,7 @@ struct inode *jffs2_new_inode (struct inode *dir_i, umode_t mode, struct jffs2_rstruct jffs2_inode_info *f;int ret; -jffs2_dbg (1 ,"%s(): dir_i %ld, mode 0x%x\n" , +jffs2_dbg (1 ,"%s(): dir_i %lld, mode 0x%x\n" , __func__, dir_i->i_ino, mode); c =JFFS2_SB_INFO (sb);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 38/61 jfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in jfs for the i_ino type change from unsigned long to u64.
--- fs/jfs/inode.c | 2 +- fs/jfs/jfs_imap.c | 2 +- fs/jfs/jfs_metapage.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
fs/jfs/inode.c +1 -1
@@ -64,7 +64,7 @@ struct inode *jfs_iget(struct super_block *sb, unsigned long ino) inode->i_op = &jfs_file_inode_operations;init_special_inode (inode, inode->i_mode, inode->i_rdev); }else { -printk (KERN_DEBUG "JFS: Invalid file type 0%04o for inode %lu.\n" , +printk (KERN_DEBUG "JFS: Invalid file type 0%04o for inode %llu.\n" , inode->i_mode, inode->i_ino);iget_failed (inode);return ERR_PTR (-EIO );
fs/jfs/jfs_imap.c +1 -1
@@ -302,7 +302,7 @@ int diRead(struct inode *ip)unsigned long pageno;int rel_inode; -jfs_info ("diRead: ino = %ld" , ip->i_ino); +jfs_info ("diRead: ino = %lld" , ip->i_ino); ipimap = sbi->ipimap;JFS_IP (ip)->ipimap = ipimap;
fs/jfs/jfs_metapage.c +1 -1
@@ -692,7 +692,7 @@ struct metapage *__get_metapage(struct inode *inode, unsigned long lblock,unsigned long page_index;unsigned long page_offset; -jfs_info ("__get_metapage: ino = %ld, lblock = 0x%lx, abs=%d" , +jfs_info ("__get_metapage: ino = %lld, lblock = 0x%lx, abs=%d" , inode->i_ino, lblock, absolute); l2bsize = inode->i_blkbits;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 39/61 minix: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in minix for the i_ino type change from unsigned long to u64.
--- fs/minix/inode.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-)
fs/minix/inode.c +5 -5
@@ -36,7 +36,7 @@ void __minix_error_inode(struct inode *inode, const char *function, vaf.fmt = fmt; vaf.va = &args;printk (KERN_CRIT "minix-fs error (device %s): %s:%d: " -"inode #%lu: comm %s: %pV\n" , +"inode #%llu: comm %s: %pV\n" , inode->i_sb->s_id, function, line, inode->i_ino, current->comm, &vaf);va_end (args);
@@ -520,7 +520,7 @@ void minix_set_inode(struct inode *inode, dev_t rdev) S_ISFIFO(inode->i_mode) || S_ISSOCK(inode->i_mode)) { init_special_inode(inode, inode->i_mode, rdev); } else { -printk (KERN_DEBUG "MINIX-fs: Invalid file type 0%04o for inode %lu.\n" , +printk (KERN_DEBUG "MINIX-fs: Invalid file type 0%04o for inode %llu.\n" , inode->i_mode, inode->i_ino);make_bad_inode (inode); }
@@ -542,7 +542,7 @@ static struct inode *V1_minix_iget(struct inode *inode)return ERR_PTR (-EIO ); }if (raw_inode->i_nlinks ==0 ) { -printk ("MINIX-fs: deleted inode referenced: %lu\n" , +printk ("MINIX-fs: deleted inode referenced: %llu\n" , inode->i_ino);brelse (bh);iget_failed (inode);
@@ -580,7 +580,7 @@ static struct inode *V2_minix_iget(struct inode *inode)return ERR_PTR (-EIO ); }if (raw_inode->i_nlinks ==0 ) { -printk ("MINIX-fs: deleted inode referenced: %lu\n" , +printk ("MINIX-fs: deleted inode referenced: %llu\n" , inode->i_ino);brelse (bh);iget_failed (inode);
@@ -692,7 +692,7 @@ static int minix_write_inode(struct inode *inode, struct writeback_control *wbc)if (wbc->sync_mode ==WB_SYNC_ALL &&buffer_dirty (bh)) {sync_dirty_buffer (bh);if (buffer_req (bh) && !buffer_uptodate (bh)) { -printk ("IO error syncing minix inode [%s:%08lx]\n" , +printk ("IO error syncing minix inode [%s:%08llx]\n" , inode->i_sb->s_id, inode->i_ino); err = -EIO ; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 40/61 nsfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in nsfs for the i_ino type change from unsigned long to u64.
--- fs/nsfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/nsfs.c +2 -2
@@ -46,7 +46,7 @@ static char *ns_dname(struct dentry *dentry, char *buffer, int buflen)struct ns_common *ns = inode->i_private;const struct proc_ns_operations *ns_ops = ns->ops; -return dynamic_dname (buffer, buflen,"%s:[%lu]" , +return dynamic_dname (buffer, buflen,"%s:[%llu]" , ns_ops->name, inode->i_ino); }
@@ -394,7 +394,7 @@ static int nsfs_show_path(struct seq_file *seq, struct dentry *dentry)const struct ns_common *ns = inode->i_private;const struct proc_ns_operations *ns_ops = ns->ops; -seq_printf (seq,"%s:[%lu]" , ns_ops->name, inode->i_ino); +seq_printf (seq,"%s:[%llu]" , ns_ops->name, inode->i_ino);return 0 ; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 41/61 ntfs3: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ntfs3 for the i_ino type change from unsigned long to u64.
--- fs/ntfs3/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/ntfs3/super.c +1 -1
@@ -153,7 +153,7 @@ void ntfs_inode_printk(struct inode *inode, const char *fmt, ...) vaf.fmt =printk_skip_level (fmt); vaf.va = &args; -printk ("%c%cntfs3(%s): ino=%lx,%s %pV\n" ,KERN_SOH_ASCII , level, +printk ("%c%cntfs3(%s): ino=%llx,%s %pV\n" ,KERN_SOH_ASCII , level, sb->s_id, inode->i_ino, name ? name :"" , &vaf);va_end (args);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 42/61 ocfs2: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ocfs2 for the i_ino type change from unsigned long to u64.
--- fs/ocfs2/alloc.c | 2 +- fs/ocfs2/aops.c | 4 ++-- fs/ocfs2/dir.c | 8 ++++---- fs/ocfs2/dlmfs/dlmfs.c | 10 +++++----- fs/ocfs2/extent_map.c | 12 ++++++------ fs/ocfs2/inode.c | 2 +- fs/ocfs2/quota_local.c | 2 +- fs/ocfs2/refcounttree.c | 10 +++++----- fs/ocfs2/xattr.c | 4 ++-- 9 files changed, 27 insertions(+), 27 deletions(-)
fs/ocfs2/alloc.c +1 -1
@@ -7318,7 +7318,7 @@ int ocfs2_commit_truncate(struct ocfs2_super *osb,* to check it up here before changing the tree. */ if (root_el->l_tree_depth && rec->e_int_clusters ==0 ) { -mlog (ML_ERROR ,"Inode %lu has an empty " +mlog (ML_ERROR ,"Inode %llu has an empty " "extent record, depth %u\n" , inode->i_ino,le16_to_cpu (root_el->l_tree_depth)); status = ocfs2_remove_rightmost_empty_extent(osb,
fs/ocfs2/aops.c +2 -2
@@ -137,7 +137,7 @@ int ocfs2_get_block(struct inode *inode, sector_t iblock, (unsigned long long)iblock, bh_result, create);if (OCFS2_I (inode)->ip_flags &OCFS2_INODE_SYSTEM_FILE ) -mlog (ML_NOTICE ,"get_block on system inode 0x%p (%lu)\n" , +mlog (ML_NOTICE ,"get_block on system inode 0x%p (%llu)\n" , inode, inode->i_ino);if (S_ISLNK (inode->i_mode)) {
@@ -2146,7 +2146,7 @@ static int ocfs2_dio_wr_get_block(struct inode *inode, sector_t iblock, ((iblock + ((len - 1) >> i_blkbits)) > endblk)) len = (endblk - iblock +1 ) << i_blkbits; -mlog (0 ,"get block of %lu at %llu:%u req %u\n" , +mlog (0 ,"get block of %llu at %llu:%u req %u\n" , inode->i_ino, pos, len, total_len);/*
fs/ocfs2/dir.c +4 -4
@@ -794,7 +794,7 @@ static int ocfs2_dx_dir_lookup_rec(struct inode *inode,if (le16_to_cpu (el->l_count) !=ocfs2_extent_recs_per_dx_root (inode->i_sb)) { ret =ocfs2_error (inode->i_sb, -"Inode %lu has invalid extent list length %u\n" , +"Inode %llu has invalid extent list length %u\n" , inode->i_ino,le16_to_cpu (el->l_count)); goto out; }
@@ -812,7 +812,7 @@ static int ocfs2_dx_dir_lookup_rec(struct inode *inode,if (el->l_tree_depth) { ret =ocfs2_error (inode->i_sb, -"Inode %lu has non zero tree depth in btree tree block %llu\n" , +"Inode %llu has non zero tree depth in btree tree block %llu\n" , inode->i_ino, (unsigned long long )eb_bh->b_blocknr); goto out;
@@ -821,7 +821,7 @@ static int ocfs2_dx_dir_lookup_rec(struct inode *inode,if (le16_to_cpu (el->l_next_free_rec) ==0 ) { ret =ocfs2_error (inode->i_sb, -"Inode %lu has empty extent list at depth %u\n" , +"Inode %llu has empty extent list at depth %u\n" , inode->i_ino,le16_to_cpu (el->l_tree_depth)); goto out;
@@ -839,7 +839,7 @@ static int ocfs2_dx_dir_lookup_rec(struct inode *inode,if (!found) { ret =ocfs2_error (inode->i_sb, -"Inode %lu has bad extent record (%u, %u, 0) in btree\n" , +"Inode %llu has bad extent record (%u, %u, 0) in btree\n" , inode->i_ino,le32_to_cpu (rec->e_cpos),ocfs2_rec_clusters (el, rec));
fs/ocfs2/dlmfs/dlmfs.c +5 -5
@@ -123,7 +123,7 @@ static int dlmfs_file_open(struct inode *inode,if (S_ISDIR (inode->i_mode))BUG (); -mlog (0 ,"open called on inode %lu, flags 0x%x\n" , inode->i_ino, +mlog (0 ,"open called on inode %llu, flags 0x%x\n" , inode->i_ino, file->f_flags); status =dlmfs_decode_open_flags (file->f_flags, &level, &flags);
@@ -170,7 +170,7 @@ static int dlmfs_file_release(struct inode *inode,if (S_ISDIR (inode->i_mode))BUG (); -mlog (0 ,"close called on inode %lu\n" , inode->i_ino); +mlog (0 ,"close called on inode %llu\n" , inode->i_ino);if (fp) { level = fp->fp_lock_level;
@@ -242,7 +242,7 @@ static ssize_t dlmfs_file_write(struct file *filp,int bytes_left;struct inode *inode =file_inode (filp); -mlog (0 ,"inode %lu, count = %zu, *ppos = %llu\n" , +mlog (0 ,"inode %llu, count = %zu, *ppos = %llu\n" , inode->i_ino, count, *ppos);if (*ppos >=DLM_LVB_LEN )
@@ -301,7 +301,7 @@ static void dlmfs_evict_inode(struct inode *inode)clear_inode (inode); -mlog (0 ,"inode %lu\n" , inode->i_ino); +mlog (0 ,"inode %llu\n" , inode->i_ino); ip =DLMFS_I (inode); lockres = &ip->ip_lockres;
@@ -490,7 +490,7 @@ static int dlmfs_unlink(struct inode *dir,int status;struct inode *inode =d_inode (dentry); -mlog (0 ,"unlink inode %lu\n" , inode->i_ino); +mlog (0 ,"unlink inode %llu\n" , inode->i_ino);/* if there are no current holders, or none that are waiting * to acquire a lock, this basically destroys our lockres. */
fs/ocfs2/extent_map.c +6 -6
@@ -291,7 +291,7 @@ static int ocfs2_last_eb_is_empty(struct inode *inode,if (el->l_tree_depth) {ocfs2_error (inode->i_sb, -"Inode %lu has non zero tree depth in leaf block %llu\n" , +"Inode %llu has non zero tree depth in leaf block %llu\n" , inode->i_ino, (unsigned long long )eb_bh->b_blocknr); ret = -EROFS ;
@@ -427,7 +427,7 @@ static int ocfs2_get_clusters_nocache(struct inode *inode,if (el->l_tree_depth) {ocfs2_error (inode->i_sb, -"Inode %lu has non zero tree depth in leaf block %llu\n" , +"Inode %llu has non zero tree depth in leaf block %llu\n" , inode->i_ino, (unsigned long long )eb_bh->b_blocknr); ret = -EROFS ;
@@ -437,7 +437,7 @@ static int ocfs2_get_clusters_nocache(struct inode *inode,if (le16_to_cpu (el->l_next_free_rec) >le16_to_cpu (el->l_count)) {ocfs2_error (inode->i_sb, -"Inode %lu has an invalid extent (next_free_rec %u, count %u)\n" , +"Inode %llu has an invalid extent (next_free_rec %u, count %u)\n" , inode->i_ino,le16_to_cpu (el->l_next_free_rec),le16_to_cpu (el->l_count));
@@ -472,7 +472,7 @@ static int ocfs2_get_clusters_nocache(struct inode *inode,if (!rec->e_blkno) {ocfs2_error (inode->i_sb, -"Inode %lu has bad extent record (%u, %u, 0)\n" , +"Inode %llu has bad extent record (%u, %u, 0)\n" , inode->i_ino,le32_to_cpu (rec->e_cpos),ocfs2_rec_clusters (el, rec));
@@ -561,7 +561,7 @@ int ocfs2_xattr_get_clusters(struct inode *inode, u32 v_cluster,if (el->l_tree_depth) {ocfs2_error (inode->i_sb, -"Inode %lu has non zero tree depth in xattr leaf block %llu\n" , +"Inode %llu has non zero tree depth in xattr leaf block %llu\n" , inode->i_ino, (unsigned long long )eb_bh->b_blocknr); ret = -EROFS ;
@@ -580,7 +580,7 @@ int ocfs2_xattr_get_clusters(struct inode *inode, u32 v_cluster,if (!rec->e_blkno) {ocfs2_error (inode->i_sb, -"Inode %lu has bad extent record (%u, %u, 0) in xattr\n" , +"Inode %llu has bad extent record (%u, %u, 0) in xattr\n" , inode->i_ino,le32_to_cpu (rec->e_cpos),ocfs2_rec_clusters (el, rec));
fs/ocfs2/inode.c +1 -1
@@ -1196,7 +1196,7 @@ static void ocfs2_clear_inode(struct inode *inode) inode->i_nlink);mlog_bug_on_msg (osb ==NULL , -"Inode=%lu\n" , inode->i_ino); +"Inode=%llu\n" , inode->i_ino);dquot_drop (inode);
fs/ocfs2/quota_local.c +1 -1
@@ -471,7 +471,7 @@ static int ocfs2_recover_local_quota_file(struct inode *lqinode,qsize_t spacechange, inodechange;unsigned int memalloc; -trace_ocfs2_recover_local_quota_file ((unsigned long )lqinode->i_ino, type); +trace_ocfs2_recover_local_quota_file ((unsigned long long )lqinode->i_ino, type);list_for_each_entry_safe (rchunk, next, &(rec->r_list[type]), rc_list) { chunk = rchunk->rc_chunk;
fs/ocfs2/refcounttree.c +5 -5
@@ -2341,7 +2341,7 @@ static int ocfs2_mark_extent_refcounted(struct inode *inode, cpos, len, phys);if (!ocfs2_refcount_tree (OCFS2_SB (inode->i_sb))) { - ret =ocfs2_error (inode->i_sb,"Inode %lu want to use refcount tree, but the feature bit is not set in the super block\n" , + ret =ocfs2_error (inode->i_sb,"Inode %llu want to use refcount tree, but the feature bit is not set in the super block\n" , inode->i_ino); goto out; }
@@ -2524,7 +2524,7 @@ int ocfs2_prepare_refcount_change_for_del(struct inode *inode,u64 start_cpos =ocfs2_blocks_to_clusters (inode->i_sb, phys_blkno);if (!ocfs2_refcount_tree (OCFS2_SB (inode->i_sb))) { - ret =ocfs2_error (inode->i_sb,"Inode %lu want to use refcount tree, but the feature bit is not set in the super block\n" , + ret =ocfs2_error (inode->i_sb,"Inode %llu want to use refcount tree, but the feature bit is not set in the super block\n" , inode->i_ino); goto out; }
@@ -2650,7 +2650,7 @@ static int ocfs2_refcount_cal_cow_clusters(struct inode *inode,if (el->l_tree_depth) { ret =ocfs2_error (inode->i_sb, -"Inode %lu has non zero tree depth in leaf block %llu\n" , +"Inode %llu has non zero tree depth in leaf block %llu\n" , inode->i_ino, (unsigned long long )eb_bh->b_blocknr); goto out;
@@ -2662,7 +2662,7 @@ static int ocfs2_refcount_cal_cow_clusters(struct inode *inode, rec = &el->l_recs[i];if (ocfs2_is_empty_extent (rec)) { -mlog_bug_on_msg (i !=0 ,"Inode %lu has empty record in " +mlog_bug_on_msg (i !=0 ,"Inode %llu has empty record in " "index %d\n" , inode->i_ino, i);continue ; }
@@ -3325,7 +3325,7 @@ static int ocfs2_replace_cow(struct ocfs2_cow_context *context)struct ocfs2_super *osb =OCFS2_SB (inode->i_sb);if (!ocfs2_refcount_tree (osb)) { -return ocfs2_error (inode->i_sb,"Inode %lu want to use refcount tree, but the feature bit is not set in the super block\n" , +return ocfs2_error (inode->i_sb,"Inode %llu want to use refcount tree, but the feature bit is not set in the super block\n" , inode->i_ino); }
fs/ocfs2/xattr.c +2 -2
@@ -3741,7 +3741,7 @@ static int ocfs2_xattr_get_rec(struct inode *inode,if (el->l_tree_depth) { ret =ocfs2_error (inode->i_sb, -"Inode %lu has non zero tree depth in xattr tree block %llu\n" , +"Inode %llu has non zero tree depth in xattr tree block %llu\n" , inode->i_ino, (unsigned long long )eb_bh->b_blocknr); goto out;
@@ -3758,7 +3758,7 @@ static int ocfs2_xattr_get_rec(struct inode *inode, }if (!e_blkno) { - ret =ocfs2_error (inode->i_sb,"Inode %lu has bad extent record (%u, %u, 0) in xattr\n" , + ret =ocfs2_error (inode->i_sb,"Inode %llu has bad extent record (%u, %u, 0) in xattr\n" , inode->i_ino,le32_to_cpu (rec->e_cpos),ocfs2_rec_clusters (el, rec));
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 43/61 orangefs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in orangefs for the i_ino type change from unsigned long to u64.
--- fs/orangefs/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/orangefs/inode.c +1 -1
@@ -1062,7 +1062,7 @@ struct inode *orangefs_iget(struct super_block *sb,unlock_new_inode (inode); gossip_debug(GOSSIP_INODE_DEBUG, - "iget handle %pU, fsid %d hash %ld i_ino %lu\n", + "iget handle %pU, fsid %d hash %ld i_ino %llu\n", &ref->khandle, ref->fs_id, hash,
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 44/61 overlayfs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in overlayfs for the i_ino type change from unsigned long to u64.
--- fs/overlayfs/export.c | 2 +- fs/overlayfs/namei.c | 4 ++-- fs/overlayfs/util.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-)
fs/overlayfs/export.c +1 -1
@@ -262,7 +262,7 @@ static int ovl_dentry_to_fid(struct ovl_fs *ofs, struct inode *inode,return err; fail: -pr_warn_ratelimited ("failed to encode file handle (ino=%lu, err=%i)\n" , +pr_warn_ratelimited ("failed to encode file handle (ino=%llu, err=%i)\n" , inode->i_ino, err); goto out; }
fs/overlayfs/namei.c +2 -2
@@ -591,7 +591,7 @@ int ovl_verify_origin_xattr(struct ovl_fs *ofs, struct dentry *dentry, fail: inode =d_inode (real); -pr_warn_ratelimited ("failed to verify %s (%pd2, ino=%lu, err=%i)\n" , +pr_warn_ratelimited ("failed to verify %s (%pd2, ino=%llu, err=%i)\n" , is_upper ?"upper" :"origin" , real, inode ? inode->i_ino :0 , err); goto out;
@@ -831,7 +831,7 @@ struct dentry *ovl_lookup_index(struct ovl_fs *ofs, struct dentry *upper, index =NULL ; goto out; } -pr_warn_ratelimited ("failed inode index lookup (ino=%lu, key=%.*s, err=%i);\n" +pr_warn_ratelimited ("failed inode index lookup (ino=%llu, key=%.*s, err=%i);\n" "overlayfs: mount with '-o index=off' to disable inodes index.\n" ,d_inode (origin)->i_ino, name.len, name.name, err);
fs/overlayfs/util.c +1 -1
@@ -1092,7 +1092,7 @@ static void ovl_cleanup_index(struct dentry *dentry) got_write = true; inode =d_inode (upperdentry);if (!S_ISDIR (inode->i_mode) && inode->i_nlink !=1 ) { -pr_warn_ratelimited ("cleanup linked index (%pd2, ino=%lu, nlink=%u)\n" , +pr_warn_ratelimited ("cleanup linked index (%pd2, ino=%llu, nlink=%u)\n" , upperdentry, inode->i_ino, inode->i_nlink);/* * We either have a bug with persistent union nlink or a lower
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 45/61 qnx4: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in qnx4 for the i_ino type change from unsigned long to u64.
--- fs/qnx4/inode.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/qnx4/inode.c +2 -2
@@ -62,7 +62,7 @@ static int qnx4_get_block( struct inode *inode, sector_t iblock, struct buffer_h {unsigned long phys; -QNX4DEBUG ((KERN_INFO "qnx4: qnx4_get_block inode=[%ld] iblock=[%ld]\n" ,inode->i_ino,iblock)); +QNX4DEBUG ((KERN_INFO "qnx4: qnx4_get_block inode=[%lld] iblock=[%ld]\n" , inode->i_ino, iblock)); phys =qnx4_block_map ( inode, iblock );if ( phys ) {
@@ -128,7 +128,7 @@ unsigned long qnx4_block_map( struct inode *inode, long iblock )brelse ( bh ); } -QNX4DEBUG ((KERN_INFO "qnx4: mapping block %ld of inode %ld = %ld\n" ,iblock,inode->i_ino,block)); +QNX4DEBUG ((KERN_INFO "qnx4: mapping block %ld of inode %lld = %ld\n" , iblock, inode->i_ino, block));return block; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 46/61 qnx6: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in qnx6 for the i_ino type change from unsigned long to u64.
--- fs/qnx6/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/qnx6/inode.c +1 -1
@@ -75,7 +75,7 @@ static int qnx6_get_block(struct inode *inode, sector_t iblock, {unsigned phys; -pr_debug ("qnx6_get_block inode=[%ld] iblock=[%ld]\n" , +pr_debug ("qnx6_get_block inode=[%lld] iblock=[%ld]\n" , inode->i_ino, (unsigned long )iblock); phys =qnx6_block_map (inode, iblock);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 47/61 ubifs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ubifs for the i_ino type change from unsigned long to u64.
--- fs/ubifs/debug.c | 8 ++++---- fs/ubifs/dir.c | 28 ++++++++++++++-------------- fs/ubifs/file.c | 28 ++++++++++++++-------------- fs/ubifs/journal.c | 6 +++--- fs/ubifs/super.c | 16 ++++++++-------- fs/ubifs/tnc.c | 4 ++-- fs/ubifs/xattr.c | 14 +++++++------- 7 files changed, 52 insertions(+), 52 deletions(-)
fs/ubifs/debug.c +4 -4
@@ -230,7 +230,7 @@ void ubifs_dump_inode(struct ubifs_info *c, const struct inode *inode)int count =2 ;pr_err ("Dump in-memory inode:" ); -pr_err ("\tinode %lu\n" , inode->i_ino); +pr_err ("\tinode %llu\n" , inode->i_ino);pr_err ("\tsize %llu\n" , (unsigned long long )i_size_read (inode));pr_err ("\tnlink %u\n" , inode->i_nlink);
@@ -1101,7 +1101,7 @@ int dbg_check_synced_i_size(const struct ubifs_info *c, struct inode *inode)if (ui->ui_size != ui->synced_i_size && !ui->dirty) {ubifs_err (c,"ui_size is %lld, synced_i_size is %lld, but inode is clean" , ui->ui_size, ui->synced_i_size); -ubifs_err (c,"i_ino %lu, i_mode %#x, i_size %lld" , inode->i_ino, +ubifs_err (c,"i_ino %llu, i_mode %#x, i_size %lld" , inode->i_ino, inode->i_mode,i_size_read (inode));dump_stack (); err = -EINVAL ;
@@ -1163,7 +1163,7 @@ int dbg_check_dir(struct ubifs_info *c, const struct inode *dir)kfree (pdent);if (i_size_read (dir) != size) { -ubifs_err (c,"directory inode %lu has size %llu, but calculated size is %llu" , +ubifs_err (c,"directory inode %llu has size %llu, but calculated size is %llu" , dir->i_ino, (unsigned long long )i_size_read (dir), (unsigned long long )size);ubifs_dump_inode (c, dir);
@@ -1171,7 +1171,7 @@ int dbg_check_dir(struct ubifs_info *c, const struct inode *dir)return -EINVAL ; }if (dir->i_nlink != nlink) { -ubifs_err (c,"directory inode %lu has nlink %u, but calculated nlink is %u" , +ubifs_err (c,"directory inode %llu has nlink %u, but calculated nlink is %u" , dir->i_ino, dir->i_nlink, nlink);ubifs_dump_inode (c, dir);dump_stack ();
fs/ubifs/dir.c +14 -14
@@ -223,7 +223,7 @@ static struct dentry *ubifs_lookup(struct inode *dir, struct dentry *dentry,struct ubifs_info *c = dir->i_sb->s_fs_info;struct fscrypt_name nm; -dbg_gen ("'%pd' in dir ino %lu" , dentry, dir->i_ino); +dbg_gen ("'%pd' in dir ino %llu" , dentry, dir->i_ino); err =fscrypt_prepare_lookup (dir, dentry, &nm);if (err == -ENOENT )
@@ -281,7 +281,7 @@ static struct dentry *ubifs_lookup(struct inode *dir, struct dentry *dentry,if (IS_ENCRYPTED (dir) && (S_ISDIR (inode->i_mode) ||S_ISLNK (inode->i_mode)) && !fscrypt_has_permitted_context (dir, inode)) { -ubifs_warn (c,"Inconsistent encryption contexts: %lu/%lu" , +ubifs_warn (c,"Inconsistent encryption contexts: %llu/%llu" , dir->i_ino, inode->i_ino);iput (inode); inode =ERR_PTR (-EPERM );
@@ -318,7 +318,7 @@ static int ubifs_create(struct mnt_idmap *idmap, struct inode *dir,* parent directory inode. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); err =ubifs_budget_space (c, &req);
@@ -386,7 +386,7 @@ static struct inode *create_whiteout(struct inode *dir, struct dentry *dentry)* atomically. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); inode =ubifs_new_inode (c, dir, mode, false);
@@ -460,7 +460,7 @@ static int ubifs_tmpfile(struct mnt_idmap *idmap, struct inode *dir,* be released via writeback. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); err =fscrypt_setup_filename (dir, &dentry->d_name,0 , &nm);
@@ -589,7 +589,7 @@ static int ubifs_readdir(struct file *file, struct dir_context *ctx)bool encrypted =IS_ENCRYPTED (dir);struct ubifs_dir_data *data = file->private_data; -dbg_gen ("dir ino %lu, f_pos %#llx" , dir->i_ino, ctx->pos); +dbg_gen ("dir ino %llu, f_pos %#llx" , dir->i_ino, ctx->pos);if (ctx->pos >UBIFS_S_KEY_HASH_MASK || ctx->pos ==2 )/*
@@ -764,7 +764,7 @@ static int ubifs_link(struct dentry *old_dentry, struct inode *dir,* changing the parent inode. */ -dbg_gen ("dent '%pd' to ino %lu (nlink %d) in dir ino %lu" , +dbg_gen ("dent '%pd' to ino %llu (nlink %d) in dir ino %llu" , dentry, inode->i_ino, inode->i_nlink, dir->i_ino);ubifs_assert (c,inode_is_locked (dir));
@@ -836,7 +836,7 @@ static int ubifs_unlink(struct inode *dir, struct dentry *dentry)* deletions. */ -dbg_gen ("dent '%pd' from ino %lu (nlink %d) in dir ino %lu" , +dbg_gen ("dent '%pd' from ino %llu (nlink %d) in dir ino %llu" , dentry, inode->i_ino, inode->i_nlink, dir->i_ino);
@@ -941,7 +941,7 @@ static int ubifs_rmdir(struct inode *dir, struct dentry *dentry)* because we have extra space reserved for deletions. */ -dbg_gen ("directory '%pd', ino %lu in dir ino %lu" , dentry, +dbg_gen ("directory '%pd', ino %llu in dir ino %llu" , dentry, inode->i_ino, dir->i_ino);ubifs_assert (c,inode_is_locked (dir));ubifs_assert (c,inode_is_locked (inode));
@@ -1018,7 +1018,7 @@ static struct dentry *ubifs_mkdir(struct mnt_idmap *idmap, struct inode *dir,* directory inode. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); err =ubifs_budget_space (c, &req);
@@ -1096,7 +1096,7 @@ static int ubifs_mknod(struct mnt_idmap *idmap, struct inode *dir,* directory inode. */ -dbg_gen ("dent '%pd' in dir ino %lu" , dentry, dir->i_ino); +dbg_gen ("dent '%pd' in dir ino %llu" , dentry, dir->i_ino);if (S_ISBLK (mode) ||S_ISCHR (mode)) { dev = kmalloc_obj(union ubifs_dev_desc, GFP_NOFS);
@@ -1183,7 +1183,7 @@ static int ubifs_symlink(struct mnt_idmap *idmap, struct inode *dir, .dirtied_ino = 1 };struct fscrypt_name nm; -dbg_gen ("dent '%pd', target '%s' in dir ino %lu" , dentry, +dbg_gen ("dent '%pd', target '%s' in dir ino %llu" , dentry, symname, dir->i_ino); err = fscrypt_prepare_symlink(dir, symname, len, UBIFS_MAX_INO_DATA,
@@ -1349,7 +1349,7 @@ static int do_rename(struct inode *old_dir, struct dentry *old_dentry,* ino_req: marks the target inode as dirty and does not write it. */ -dbg_gen ("dent '%pd' ino %lu in dir ino %lu to dent '%pd' in dir ino %lu flags 0x%x" , +dbg_gen ("dent '%pd' ino %llu in dir ino %llu to dent '%pd' in dir ino %llu flags 0x%x" , old_dentry, old_inode->i_ino, old_dir->i_ino, new_dentry, new_dir->i_ino, flags);
@@ -1597,7 +1597,7 @@ static int ubifs_xrename(struct inode *old_dir, struct dentry *old_dentry,* parent directory inodes. */ -dbg_gen ("dent '%pd' ino %lu in dir ino %lu exchange dent '%pd' ino %lu in dir ino %lu" , +dbg_gen ("dent '%pd' ino %llu in dir ino %llu exchange dent '%pd' ino %llu in dir ino %llu" , old_dentry, fst_inode->i_ino, old_dir->i_ino, new_dentry, snd_inode->i_ino, new_dir->i_ino);
fs/ubifs/file.c +14 -14
@@ -90,7 +90,7 @@ static int read_block(struct inode *inode, struct folio *folio, size_t offset,return 0 ; dump: -ubifs_err (c,"bad data node (block %u, inode %lu)" , +ubifs_err (c,"bad data node (block %u, inode %llu)" , block, inode->i_ino);ubifs_dump_node (c, dn,UBIFS_MAX_DATA_NODE_SZ );return -EINVAL ;
@@ -106,7 +106,7 @@ static int do_readpage(struct folio *folio)loff_t i_size =i_size_read (inode);size_t offset =0 ; -dbg_gen ("ino %lu, pg %lu, i_size %lld, flags %#lx" , +dbg_gen ("ino %llu, pg %lu, i_size %lld, flags %#lx" , inode->i_ino, folio->index, i_size, folio->flags.f);ubifs_assert (c, !folio_test_checked (folio));ubifs_assert (c, !folio->private);
@@ -162,7 +162,7 @@ static int do_readpage(struct folio *folio)dbg_gen ("hole" ); err =0 ; }else { -ubifs_err (c,"cannot read page %lu of inode %lu, error %d" , +ubifs_err (c,"cannot read page %lu of inode %llu, error %d" , folio->index, inode->i_ino, err); } }
@@ -212,7 +212,7 @@ static int write_begin_slow(struct address_space *mapping,int err, appending = !!(pos + len > inode->i_size);struct folio *folio; -dbg_gen ("ino %lu, pos %llu, len %u, i_size %lld" , +dbg_gen ("ino %llu, pos %llu, len %u, i_size %lld" , inode->i_ino, pos, len, inode->i_size);/*
@@ -526,7 +526,7 @@ static int ubifs_write_end(const struct kiocb *iocb,loff_t end_pos = pos + len;int appending = !!(end_pos > inode->i_size); -dbg_gen ("ino %lu, pos %llu, pg %lu, len %u, copied %d, i_size %lld" , +dbg_gen ("ino %llu, pos %llu, pg %lu, len %u, copied %d, i_size %lld" , inode->i_ino, pos, folio->index, len, copied, inode->i_size);if (unlikely (copied < len && !folio_test_uptodate (folio))) {
@@ -599,7 +599,7 @@ static int populate_page(struct ubifs_info *c, struct folio *folio,size_t offset =0 ;pgoff_t end_index; -dbg_gen ("ino %lu, pg %lu, i_size %lld, flags %#lx" , +dbg_gen ("ino %llu, pg %lu, i_size %lld, flags %#lx" , inode->i_ino, folio->index, i_size, folio->flags.f); end_index = (i_size -1 ) >>PAGE_SHIFT ;
@@ -680,7 +680,7 @@ static int populate_page(struct ubifs_info *c, struct folio *folio,return 0 ; out_err: -ubifs_err (c,"bad data node (block %u, inode %lu)" , +ubifs_err (c,"bad data node (block %u, inode %llu)" , page_block, inode->i_ino);return -EINVAL ; }
@@ -913,7 +913,7 @@ static int do_writepage(struct folio *folio, size_t len) }if (err) {mapping_set_error (folio->mapping, err); -ubifs_err (c,"cannot write folio %lu of inode %lu, error %d" , +ubifs_err (c,"cannot write folio %lu of inode %llu, error %d" , folio->index, inode->i_ino, err);ubifs_ro_mode (c, err); }
@@ -987,7 +987,7 @@ static int ubifs_writepage(struct folio *folio, struct writeback_control *wbc)loff_t i_size =i_size_read (inode), synced_i_size;int err, len =folio_size (folio); -dbg_gen ("ino %lu, pg %lu, pg flags %#lx" , +dbg_gen ("ino %llu, pg %lu, pg flags %#lx" , inode->i_ino, folio->index, folio->flags.f);ubifs_assert (c, folio->private !=NULL );
@@ -1106,7 +1106,7 @@ static int do_truncation(struct ubifs_info *c, struct inode *inode,int offset = new_size & (UBIFS_BLOCK_SIZE -1 ), budgeted =1 ;struct ubifs_inode *ui =ubifs_inode (inode); -dbg_gen ("ino %lu, size %lld -> %lld" , inode->i_ino, old_size, new_size); +dbg_gen ("ino %llu, size %lld -> %lld" , inode->i_ino, old_size, new_size);memset (&req,0 ,sizeof (struct ubifs_budget_req ));/*
@@ -1258,7 +1258,7 @@ int ubifs_setattr(struct mnt_idmap *idmap, struct dentry *dentry,struct inode *inode =d_inode (dentry);struct ubifs_info *c = inode->i_sb->s_fs_info; -dbg_gen ("ino %lu, mode %#x, ia_valid %#x" , +dbg_gen ("ino %llu, mode %#x, ia_valid %#x" , inode->i_ino, inode->i_mode, attr->ia_valid); err =setattr_prepare (&nop_mnt_idmap, dentry, attr);if (err)
@@ -1308,7 +1308,7 @@ int ubifs_fsync(struct file *file, loff_t start, loff_t end, int datasync)struct ubifs_info *c = inode->i_sb->s_fs_info;int err; -dbg_gen ("syncing inode %lu" , inode->i_ino); +dbg_gen ("syncing inode %llu" , inode->i_ino);if (c->ro_mount)/*
@@ -1495,7 +1495,7 @@ static vm_fault_t ubifs_vm_page_mkwrite(struct vm_fault *vmf)struct ubifs_budget_req req = { .new_page =1 };int err, update_time; -dbg_gen ("ino %lu, pg %lu, i_size %lld" , inode->i_ino, folio->index, +dbg_gen ("ino %llu, pg %lu, i_size %lld" , inode->i_ino, folio->index,i_size_read (inode));ubifs_assert (c, !c->ro_media && !c->ro_mount);
@@ -1531,7 +1531,7 @@ static vm_fault_t ubifs_vm_page_mkwrite(struct vm_fault *vmf) err =ubifs_budget_space (c, &req);if (unlikely (err)) {if (err == -ENOSPC ) -ubifs_warn (c,"out of space for mmapped file (inode number %lu)" , +ubifs_warn (c,"out of space for mmapped file (inode number %llu)" , inode->i_ino);return VM_FAULT_SIGBUS ; }
fs/ubifs/journal.c +3 -3
@@ -982,7 +982,7 @@ int ubifs_jnl_write_inode(struct ubifs_info *c, const struct inode *inode)int kill_xattrs = ui->xattr_cnt && last_reference;u8 hash[UBIFS_HASH_ARR_SZ ]; -dbg_jnl ("ino %lu, nlink %u" , inode->i_ino, inode->i_nlink); +dbg_jnl ("ino %llu, nlink %u" , inode->i_ino, inode->i_nlink);if (kill_xattrs && ui->xattr_cnt >ubifs_xattr_max_cnt (c)) {ubifs_err (c,"Cannot delete inode, it has too many xattrs!" );
@@ -1743,7 +1743,7 @@ int ubifs_jnl_truncate(struct ubifs_info *c, const struct inode *inode,int dn_len =le32_to_cpu (dn->size);if (dn_len <=0 || dn_len >UBIFS_BLOCK_SIZE ) { -ubifs_err (c,"bad data node (block %u, inode %lu)" , +ubifs_err (c,"bad data node (block %u, inode %llu)" , blk, inode->i_ino);ubifs_dump_node (c, dn, dn_size); err = -EUCLEAN ;
@@ -1987,7 +1987,7 @@ int ubifs_jnl_change_xattr(struct ubifs_info *c, const struct inode *inode,u8 hash_host[UBIFS_HASH_ARR_SZ ];u8 hash[UBIFS_HASH_ARR_SZ ]; -dbg_jnl ("ino %lu, ino %lu" , host->i_ino, inode->i_ino); +dbg_jnl ("ino %llu, ino %llu" , host->i_ino, inode->i_ino);ubifs_assert (c, inode->i_nlink >0 );ubifs_assert (c,mutex_is_locked (&host_ui->ui_mutex));
fs/ubifs/super.c +8 -8
@@ -92,7 +92,7 @@ static int validate_inode(struct ubifs_info *c, const struct inode *inode)return 5 ;if (!ubifs_compr_present (c, ui->compr_type)) { -ubifs_warn (c,"inode %lu uses '%s' compression, but it was not compiled in" , +ubifs_warn (c,"inode %llu uses '%s' compression, but it was not compiled in" , inode->i_ino,ubifs_compr_name (c, ui->compr_type)); }
@@ -248,14 +248,14 @@ struct inode *ubifs_iget(struct super_block *sb, unsigned long inum)return inode; out_invalid: -ubifs_err (c,"inode %lu validation failed, error %d" , inode->i_ino, err); +ubifs_err (c,"inode %llu validation failed, error %d" , inode->i_ino, err);ubifs_dump_node (c, ino,UBIFS_MAX_INO_NODE_SZ );ubifs_dump_inode (c, inode); err = -EINVAL ; out_ino:kfree (ino); out: -ubifs_err (c,"failed to read inode %lu, error %d" , inode->i_ino, err); +ubifs_err (c,"failed to read inode %llu, error %d" , inode->i_ino, err);iget_failed (inode);return ERR_PTR (err); }
@@ -316,12 +316,12 @@ static int ubifs_write_inode(struct inode *inode, struct writeback_control *wbc)* As an optimization, do not write orphan inodes to the media just * because this is not needed. */ -dbg_gen ("inode %lu, mode %#x, nlink %u" , +dbg_gen ("inode %llu, mode %#x, nlink %u" , inode->i_ino, (int )inode->i_mode, inode->i_nlink);if (inode->i_nlink) { err =ubifs_jnl_write_inode (c, inode);if (err) -ubifs_err (c,"can't write inode %lu, error %d" , +ubifs_err (c,"can't write inode %llu, error %d" , inode->i_ino, err);else err =dbg_check_inode_size (c, inode, ui->ui_size);
@@ -357,7 +357,7 @@ static void ubifs_evict_inode(struct inode *inode)*/ goto out; -dbg_gen ("inode %lu, mode %#x" , inode->i_ino, (int )inode->i_mode); +dbg_gen ("inode %llu, mode %#x" , inode->i_ino, (int )inode->i_mode);ubifs_assert (c, !icount_read (inode));truncate_inode_pages_final (&inode->i_data);
@@ -375,7 +375,7 @@ static void ubifs_evict_inode(struct inode *inode)* Worst case we have a lost orphan inode wasting space, so a * simple error message is OK here. */ -ubifs_err (c,"can't delete inode %lu, error %d" , +ubifs_err (c,"can't delete inode %llu, error %d" , inode->i_ino, err); out:
@@ -399,7 +399,7 @@ static void ubifs_dirty_inode(struct inode *inode, int flags)ubifs_assert (c,mutex_is_locked (&ui->ui_mutex));if (!ui->dirty) { ui->dirty =1 ; -dbg_gen ("inode %lu" , inode->i_ino); +dbg_gen ("inode %llu" , inode->i_ino); } }
fs/ubifs/tnc.c +2 -2
@@ -3561,8 +3561,8 @@ int dbg_check_inode_size(struct ubifs_info *c, const struct inode *inode, out_dump: block =key_block (c, key); -ubifs_err (c,"inode %lu has size %lld, but there are data at offset %lld" , - (unsigned long )inode->i_ino, size, +ubifs_err (c,"inode %llu has size %lld, but there are data at offset %lld" , + (unsigned long long )inode->i_ino, size, ((loff_t )block) <<UBIFS_BLOCK_SHIFT );mutex_unlock (&c->tnc_mutex);ubifs_dump_inode (c, inode);
fs/ubifs/xattr.c +7 -7
@@ -76,7 +76,7 @@ static int create_xattr(struct ubifs_info *c, struct inode *host, .dirtied_ino_d = ALIGN(host_ui->data_len, 8) };if (host_ui->xattr_cnt >=ubifs_xattr_max_cnt (c)) { -ubifs_err (c,"inode %lu already has too many xattrs (%d), cannot create more" , +ubifs_err (c,"inode %llu already has too many xattrs (%d), cannot create more" , host->i_ino, host_ui->xattr_cnt);return -ENOSPC ; }
@@ -88,7 +88,7 @@ static int create_xattr(struct ubifs_info *c, struct inode *host,*/ names_len = host_ui->xattr_names + host_ui->xattr_cnt +fname_len (nm) +1 ;if (names_len >XATTR_LIST_MAX ) { -ubifs_err (c,"cannot add one more xattr name to inode %lu, total names length would become %d, max. is %d" , +ubifs_err (c,"cannot add one more xattr name to inode %llu, total names length would become %d, max. is %d" , host->i_ino, names_len,XATTR_LIST_MAX );return -ENOSPC ; }
@@ -390,7 +390,7 @@ ssize_t ubifs_listxattr(struct dentry *dentry, char *buffer, size_t size)int err, len, written =0 ;struct fscrypt_name nm = {0 }; -dbg_gen ("ino %lu ('%pd'), buffer size %zd" , host->i_ino, +dbg_gen ("ino %llu ('%pd'), buffer size %zd" , host->i_ino, dentry, size);down_read (&host_ui->xattr_sem);
@@ -498,7 +498,7 @@ int ubifs_purge_xattrs(struct inode *host)if (ubifs_inode (host)->xattr_cnt <=ubifs_xattr_max_cnt (c))return 0 ; -ubifs_warn (c,"inode %lu has too many xattrs, doing a non-atomic deletion" , +ubifs_warn (c,"inode %llu has too many xattrs, doing a non-atomic deletion" , host->i_ino);down_write (&ubifs_inode (host)->xattr_sem);
@@ -641,7 +641,7 @@ int ubifs_init_security(struct inode *dentry, struct inode *inode, &init_xattrs, NULL);if (err) {struct ubifs_info *c = dentry->i_sb->s_fs_info; -ubifs_err (c,"cannot initialize security for inode %lu, error %d" , +ubifs_err (c,"cannot initialize security for inode %llu, error %d" , inode->i_ino, err); }return err;
@@ -652,7 +652,7 @@ static int xattr_get(const struct xattr_handler *handler, struct dentry *dentry, struct inode *inode, const char *name, void *buffer, size_t size) { - dbg_gen("xattr '%s', ino %lu ('%pd'), buf size %zd", name, + dbg_gen("xattr '%s', ino %llu ('%pd'), buf size %zd", name, inode->i_ino, dentry, size); name =xattr_full_name (handler, name);
@@ -665,7 +665,7 @@ static int xattr_set(const struct xattr_handler *handler, const char *name, const void *value, size_t size, int flags) { - dbg_gen("xattr '%s', host ino %lu ('%pd'), size %zd", + dbg_gen("xattr '%s', host ino %llu ('%pd'), size %zd", name, inode->i_ino, dentry, size); name =xattr_full_name (handler, name);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 48/61 udf: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in udf for the i_ino type change from unsigned long to u64.
--- fs/udf/directory.c | 18 +++++++++--------- fs/udf/file.c | 2 +- fs/udf/inode.c | 12 ++++++------ fs/udf/namei.c | 8 ++++---- fs/udf/super.c | 2 +- 5 files changed, 21 insertions(+), 21 deletions(-)
fs/udf/directory.c +9 -9
@@ -22,7 +22,7 @@ static int udf_verify_fi(struct udf_fileident_iter *iter)if (iter->fi.descTag.tagIdent !=cpu_to_le16 (TAG_IDENT_FID )) {udf_err (iter->dir->i_sb, -"directory (ino %lu) has entry at pos %llu with incorrect tag %x\n" , +"directory (ino %llu) has entry at pos %llu with incorrect tag %x\n" , iter->dir->i_ino, (unsigned long long )iter->pos,le16_to_cpu (iter->fi.descTag.tagIdent));return -EFSCORRUPTED ;
@@ -30,7 +30,7 @@ static int udf_verify_fi(struct udf_fileident_iter *iter) len =udf_dir_entry_len (&iter->fi);if (le16_to_cpu (iter->fi.lengthOfImpUse) &3 ) {udf_err (iter->dir->i_sb, -"directory (ino %lu) has entry at pos %llu with unaligned length of impUse field\n" , +"directory (ino %llu) has entry at pos %llu with unaligned length of impUse field\n" , iter->dir->i_ino, (unsigned long long )iter->pos);return -EFSCORRUPTED ; }
@@ -41,20 +41,20 @@ static int udf_verify_fi(struct udf_fileident_iter *iter)*/ if (len >1 << iter->dir->i_blkbits) {udf_err (iter->dir->i_sb, -"directory (ino %lu) has too big (%u) entry at pos %llu\n" , +"directory (ino %llu) has too big (%u) entry at pos %llu\n" , iter->dir->i_ino, len, (unsigned long long )iter->pos);return -EFSCORRUPTED ; }if (iter->pos + len > iter->dir->i_size) {udf_err (iter->dir->i_sb, -"directory (ino %lu) has entry past directory size at pos %llu\n" , +"directory (ino %llu) has entry past directory size at pos %llu\n" , iter->dir->i_ino, (unsigned long long )iter->pos);return -EFSCORRUPTED ; }if (udf_dir_entry_len (&iter->fi) !=sizeof (struct tag ) +le16_to_cpu (iter->fi.descTag.descCRCLength)) { udf_err(iter->dir->i_sb, - "directory (ino %lu) has entry where CRC length (%u) does not match entry length (%u)\n", + "directory (ino %llu) has entry where CRC length (%u) does not match entry length (%u)\n", iter->dir->i_ino, (unsigned)le16_to_cpu(iter->fi.descTag.descCRCLength), (unsigned)(udf_dir_entry_len(&iter->fi) -
@@ -78,7 +78,7 @@ static int udf_copy_fi(struct udf_fileident_iter *iter) }if (iter->dir->i_size < iter->pos +sizeof (struct fileIdentDesc )) {udf_err (iter->dir->i_sb, -"directory (ino %lu) has entry straddling EOF\n" , +"directory (ino %llu) has entry straddling EOF\n" , iter->dir->i_ino);return -EFSCORRUPTED ; }
@@ -184,7 +184,7 @@ static int udf_fiiter_advance_blk(struct udf_fileident_iter *iter)return 0 ; }udf_err (iter->dir->i_sb, -"extent after position %llu not allocated in directory (ino %lu)\n" , +"extent after position %llu not allocated in directory (ino %llu)\n" , (unsigned long long )iter->pos, iter->dir->i_ino);return -EFSCORRUPTED ; }
@@ -272,7 +272,7 @@ int udf_fiiter_init(struct udf_fileident_iter *iter, struct inode *dir,if (pos == dir->i_size)return 0 ;udf_err (dir->i_sb, -"position %llu not allocated in directory (ino %lu)\n" , +"position %llu not allocated in directory (ino %llu)\n" , (unsigned long long )pos, dir->i_ino); err = -EFSCORRUPTED ; goto out;
@@ -483,7 +483,7 @@ int udf_fiiter_append_blk(struct udf_fileident_iter *iter) &iter->loffset, &etype);if (err <=0 || etype != (EXT_RECORDED_ALLOCATED >>30 )) {udf_err (iter->dir->i_sb, -"block %llu not allocated in directory (ino %lu)\n" , +"block %llu not allocated in directory (ino %llu)\n" , (unsigned long long )block, iter->dir->i_ino);return -EFSCORRUPTED ; }
fs/udf/file.c +1 -1
@@ -133,7 +133,7 @@ long udf_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)int result;if (file_permission (filp,MAY_READ ) !=0 ) { -udf_debug ("no permission to access inode %lu\n" , inode->i_ino); +udf_debug ("no permission to access inode %llu\n" , inode->i_ino);return -EPERM ; }
fs/udf/inode.c +6 -6
@@ -147,7 +147,7 @@ void udf_evict_inode(struct inode *inode)if (iinfo->i_alloc_type !=ICBTAG_FLAG_AD_IN_ICB && inode->i_size != iinfo->i_lenExtents) {udf_warn (inode->i_sb, -"Inode %lu (mode %o) has inode size %llu different from extent length %llu. Filesystem need not be standards compliant.\n" , +"Inode %llu (mode %o) has inode size %llu different from extent length %llu. Filesystem need not be standards compliant.\n" , inode->i_ino, inode->i_mode, (unsigned long long )inode->i_size, (unsigned long long )iinfo->i_lenExtents);
@@ -1386,13 +1386,13 @@ static int udf_read_inode(struct inode *inode, bool hidden_inode)*/ bh =udf_read_ptagged (inode->i_sb, iloc,0 , &ident);if (!bh) { -udf_err (inode->i_sb,"(ino %lu) failed !bh\n" , inode->i_ino); +udf_err (inode->i_sb,"(ino %llu) failed !bh\n" , inode->i_ino);return -EIO ; }if (ident !=TAG_IDENT_FE && ident !=TAG_IDENT_EFE && ident !=TAG_IDENT_USE ) { -udf_err (inode->i_sb,"(ino %lu) failed ident=%u\n" , +udf_err (inode->i_sb,"(ino %llu) failed ident=%u\n" , inode->i_ino, ident); goto out; }
@@ -1641,7 +1641,7 @@ static int udf_read_inode(struct inode *inode, bool hidden_inode)udf_debug ("METADATA BITMAP FILE-----\n" );break ;default : -udf_err (inode->i_sb,"(ino %lu) failed unknown file type=%u\n" , +udf_err (inode->i_sb,"(ino %llu) failed unknown file type=%u\n" , inode->i_ino, fe->icbTag.fileType); goto out; }
@@ -1942,7 +1942,7 @@ static int udf_update_inode(struct inode *inode, int do_sync)if (do_sync) {sync_dirty_buffer (bh);if (buffer_write_io_error (bh)) { -udf_warn (inode->i_sb,"IO error syncing udf inode [%08lx]\n" , +udf_warn (inode->i_sb,"IO error syncing udf inode [%08llx]\n" , inode->i_ino); err = -EIO ; }
@@ -2224,7 +2224,7 @@ int udf_next_aext(struct inode *inode, struct extent_position *epos,if (++indirections >UDF_MAX_INDIR_EXTS ) {udf_err (inode->i_sb, -"too many indirect extents in inode %lu\n" , +"too many indirect extents in inode %llu\n" , inode->i_ino);return -EFSCORRUPTED ; }
fs/udf/namei.c +4 -4
@@ -550,7 +550,7 @@ static int udf_unlink(struct inode *dir, struct dentry *dentry) goto end_unlink;if (!inode->i_nlink) { -udf_debug ("Deleting nonexistent file (%lu), %u\n" , +udf_debug ("Deleting nonexistent file (%llu), %u\n" , inode->i_ino, inode->i_nlink);set_nlink (inode,1 ); }
@@ -809,7 +809,7 @@ static int udf_rename(struct mnt_idmap *idmap, struct inode *old_dir, &diriter);if (retval == -ENOENT ) {udf_err (old_inode->i_sb, -"directory (ino %lu) has no '..' entry\n" , +"directory (ino %llu) has no '..' entry\n" , old_inode->i_ino); retval = -EFSCORRUPTED ; }
@@ -821,7 +821,7 @@ static int udf_rename(struct mnt_idmap *idmap, struct inode *old_dir, old_dir->i_ino) { retval = -EFSCORRUPTED ;udf_err (old_inode->i_sb, -"directory (ino %lu) has parent entry pointing to another inode (%lu != %u)\n" , +"directory (ino %llu) has parent entry pointing to another inode (%llu != %u)\n" , old_inode->i_ino, old_dir->i_ino,udf_get_lb_pblock (old_inode->i_sb, &tloc,0 )); goto out_oiter;
@@ -869,7 +869,7 @@ static int udf_rename(struct mnt_idmap *idmap, struct inode *old_dir, retval =udf_fiiter_find_entry (old_dir, &old_dentry->d_name, &oiter);if (retval) {udf_err (old_dir->i_sb, -"failed to find renamed entry again in directory (ino %lu)\n" , +"failed to find renamed entry again in directory (ino %llu)\n" , old_dir->i_ino); }else {udf_fiiter_delete_entry (&oiter);
fs/udf/super.c +1 -1
@@ -1166,7 +1166,7 @@ static int udf_fill_partdesc_info(struct super_block *sb, } map->s_uspace.s_table = inode; map->s_partition_flags |=UDF_PART_FLAG_UNALLOC_TABLE ; -udf_debug ("unallocSpaceTable (part %d) @ %lu\n" , +udf_debug ("unallocSpaceTable (part %d) @ %llu\n" , p_index, map->s_uspace.s_table->i_ino); }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 49/61 ufs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in ufs for the i_ino type change from unsigned long to u64.
--- fs/ufs/balloc.c | 6 +++--- fs/ufs/dir.c | 10 +++++----- fs/ufs/ialloc.c | 6 +++--- fs/ufs/inode.c | 18 +++++++++--------- fs/ufs/ufs_fs.h | 6 +++--- fs/ufs/util.c | 2 +- 6 files changed, 24 insertions(+), 24 deletions(-)
fs/ufs/balloc.c +3 -3
@@ -245,7 +245,7 @@ static void ufs_change_blocknr(struct inode *inode, sector_t beg,sector_t end, i;struct buffer_head *head, *bh; -UFSD ("ENTER, ino %lu, count %u, oldb %llu, newb %llu\n" , +UFSD ("ENTER, ino %llu, count %u, oldb %llu, newb %llu\n" , inode->i_ino, count, (unsigned long long )oldb, (unsigned long long )newb);
@@ -340,7 +340,7 @@ u64 ufs_new_fragments(struct inode *inode, void *p, u64 fragment,unsigned cgno, oldcount, newcount;u64 tmp, request, result; -UFSD ("ENTER, ino %lu, fragment %llu, goal %llu, count %u\n" , +UFSD ("ENTER, ino %llu, fragment %llu, goal %llu, count %u\n" , inode->i_ino, (unsigned long long )fragment, (unsigned long long )goal, count);
@@ -583,7 +583,7 @@ static u64 ufs_alloc_fragments(struct inode *inode, unsigned cgno,unsigned oldcg, i, j, k, allocsize;u64 result; -UFSD ("ENTER, ino %lu, cgno %u, goal %llu, count %u\n" , +UFSD ("ENTER, ino %llu, cgno %u, goal %llu, count %u\n" , inode->i_ino, cgno, (unsigned long long )goal, count); sb = inode->i_sb;
fs/ufs/dir.c +5 -5
@@ -150,7 +150,7 @@ static bool ufs_check_folio(struct folio *folio, char *kaddr) Ebadsize:ufs_error (sb, __func__, -"size of directory #%lu is not a multiple of chunk size" , +"size of directory #%llu is not a multiple of chunk size" , dir->i_ino ); goto fail;
@@ -169,7 +169,7 @@ static bool ufs_check_folio(struct folio *folio, char *kaddr) Einumber: error ="inode out of bounds" ; bad_entry: -ufs_error (sb, __func__,"bad entry in directory #%lu: %s - " +ufs_error (sb, __func__,"bad entry in directory #%llu: %s - " "offset=%llu, rec_len=%d, name_len=%d" , dir->i_ino, error,folio_pos (folio) + offs, rec_len,ufs_get_de_namlen (sb, p));
@@ -177,7 +177,7 @@ static bool ufs_check_folio(struct folio *folio, char *kaddr) Eend: p = (struct ufs_dir_entry *)(kaddr + offs);ufs_error (sb, __func__, -"entry in directory #%lu spans the page boundary" +"entry in directory #%llu spans the page boundary" "offset=%llu" , dir->i_ino,folio_pos (folio) + offs); fail:
@@ -258,7 +258,7 @@ struct ufs_dir_entry *ufs_find_entry(struct inode *dir, const struct qstr *qstr,struct ufs_inode_info *ui =UFS_I (dir);struct ufs_dir_entry *de; -UFSD ("ENTER, dir_ino %lu, name %s, namlen %u\n" , dir->i_ino, name, namelen); +UFSD ("ENTER, dir_ino %llu, name %s, namlen %u\n" , dir->i_ino, name, namelen);if (npages ==0 || namelen >UFS_MAXNAMLEN ) goto out;
@@ -434,7 +434,7 @@ ufs_readdir(struct file *file, struct dir_context *ctx)if (IS_ERR (kaddr)) {ufs_error (sb, __func__, -"bad page in #%lu" , +"bad page in #%llu" , inode->i_ino); ctx->pos +=PAGE_SIZE - offset;return PTR_ERR (kaddr);
fs/ufs/ialloc.c +3 -3
@@ -63,7 +63,7 @@ void ufs_free_inode (struct inode * inode)int is_directory;unsigned ino, cg, bit; -UFSD ("ENTER, ino %lu\n" , inode->i_ino); +UFSD ("ENTER, ino %llu\n" , inode->i_ino); sb = inode->i_sb; uspi =UFS_SB (sb)->s_uspi;
@@ -317,7 +317,7 @@ struct inode *ufs_new_inode(struct inode *dir, umode_t mode) bh =sb_bread (sb, uspi->s_sbbase +ufs_inotofsba (inode->i_ino));if (!bh) {ufs_warning (sb,"ufs_read_inode" , -"unable to read inode %lu\n" , +"unable to read inode %llu\n" , inode->i_ino); err = -EIO ; goto fail_remove_inode;
@@ -336,7 +336,7 @@ struct inode *ufs_new_inode(struct inode *dir, umode_t mode) }mutex_unlock (&sbi->s_lock); -UFSD ("allocating inode %lu\n" , inode->i_ino); +UFSD ("allocating inode %llu\n" , inode->i_ino);UFSD ("EXIT\n" );return inode;
fs/ufs/inode.c +9 -9
@@ -400,7 +400,7 @@ static int ufs_getfrag_block(struct inode *inode, sector_t fragment, struct buffmutex_lock (&UFS_I (inode)->truncate_mutex); -UFSD ("ENTER, ino %lu, fragment %llu\n" , inode->i_ino, (unsigned long long )fragment); +UFSD ("ENTER, ino %llu, fragment %llu\n" , inode->i_ino, (unsigned long long )fragment);if (unlikely (!depth)) {ufs_warning (sb,"ufs_get_block" ,"block > big" ); err = -EIO ;
@@ -595,7 +595,7 @@ static int ufs2_read_inode(struct inode *inode, struct ufs2_inode *ufs2_inode)struct super_block *sb = inode->i_sb;umode_t mode; -UFSD ("Reading ufs2 inode, ino %lu\n" , inode->i_ino); +UFSD ("Reading ufs2 inode, ino %llu\n" , inode->i_ino);/* * Copy data to the in-core inode. */
@@ -662,7 +662,7 @@ struct inode *ufs_iget(struct super_block *sb, unsigned long ino) bh =sb_bread (sb, uspi->s_sbbase +ufs_inotofsba (inode->i_ino));if (!bh) { -ufs_warning (sb,"ufs_read_inode" ,"unable to read inode %lu\n" , +ufs_warning (sb,"ufs_read_inode" ,"unable to read inode %llu\n" , inode->i_ino); goto bad_inode; }
@@ -793,17 +793,17 @@ static int ufs_update_inode(struct inode * inode, int do_sync)struct ufs_sb_private_info *uspi =UFS_SB (sb)->s_uspi;struct buffer_head * bh; -UFSD ("ENTER, ino %lu\n" , inode->i_ino); +UFSD ("ENTER, ino %llu\n" , inode->i_ino);if (inode->i_ino <UFS_ROOTINO || inode->i_ino > (uspi->s_ncg * uspi->s_ipg)) { -ufs_warning (sb,"ufs_read_inode" ,"bad inode number (%lu)\n" , inode->i_ino); +ufs_warning (sb,"ufs_read_inode" ,"bad inode number (%llu)\n" , inode->i_ino);return -1 ; } bh =sb_bread (sb,ufs_inotofsba (inode->i_ino));if (!bh) { -ufs_warning (sb,"ufs_read_inode" ,"unable to read inode %lu\n" , inode->i_ino); +ufs_warning (sb,"ufs_read_inode" ,"unable to read inode %llu\n" , inode->i_ino);return -1 ; }if (uspi->fs_magic ==UFS2_MAGIC ) {
@@ -891,7 +891,7 @@ static void ufs_trunc_direct(struct inode *inode)unsigned int old_tail, new_tail;struct to_free ctx = {.inode = inode}; -UFSD ("ENTER: ino %lu\n" , inode->i_ino); +UFSD ("ENTER: ino %llu\n" , inode->i_ino); new_frags =DIRECT_FRAGMENT ;// new_frags = first fragment past the new EOF
@@ -956,7 +956,7 @@ static void ufs_trunc_direct(struct inode *inode) } } done: -UFSD ("EXIT: ino %lu\n" , inode->i_ino); +UFSD ("EXIT: ino %llu\n" , inode->i_ino); }static void free_full_branch (struct inode *inode,u64 ind_block,int depth)
@@ -1169,7 +1169,7 @@ static int ufs_truncate(struct inode *inode, loff_t size) {int err =0 ; -UFSD ("ENTER: ino %lu, i_size: %llu, old_i_size: %llu\n" , +UFSD ("ENTER: ino %llu, i_size: %llu, old_i_size: %llu\n" , inode->i_ino, (unsigned long long )size, (unsigned long long )i_size_read (inode));
fs/ufs/ufs_fs.h +3 -3
@@ -226,10 +226,10 @@ typedef __u16 __bitwise __fs16;* inode number to cylinder group number. * inode number to file system block address. */ -#define ufs_inotocg (x) ((x) / uspi->s_ipg) -#define ufs_inotocgoff (x) ((x) % uspi->s_ipg) +#define ufs_inotocg (x) ((unsigned int)(x) / uspi->s_ipg) +#define ufs_inotocgoff (x) ((unsigned int)(x) % uspi->s_ipg)#define ufs_inotofsba (x) (((u64)ufs_cgimin(ufs_inotocg(x))) + ufs_inotocgoff(x) / uspi->s_inopf) -#define ufs_inotofsbo (x) ((x) % uspi->s_inopf) +#define ufs_inotofsbo (x) ((unsigned int)(x) % uspi->s_inopf)/* * Compute the cylinder and rotational position of a cyl block addr.
fs/ufs/util.c +1 -1
@@ -203,7 +203,7 @@ struct folio *ufs_get_locked_folio(struct address_space *mapping, folio =read_mapping_folio (mapping, index,NULL );if (IS_ERR (folio)) { -printk (KERN_ERR "ufs_change_blocknr: read_mapping_folio error: ino %lu, index: %lu\n" , +printk (KERN_ERR "ufs_change_blocknr: read_mapping_folio error: ino %llu, index: %lu\n" , mapping->host->i_ino, index);return folio; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 50/61 zonefs: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings and local variable types in zonefs for the i_ino type change from unsigned long to u64.
--- fs/zonefs/super.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
fs/zonefs/super.c +4 -4
@@ -297,7 +297,7 @@ static void zonefs_handle_io_error(struct inode *inode, struct blk_zone *zone,*/ if (isize != data_size)zonefs_warn (sb, -"inode %lu: invalid size %lld (should be %lld)\n" , +"inode %llu: invalid size %lld (should be %lld)\n" , inode->i_ino, isize, data_size);/*
@@ -308,7 +308,7 @@ static void zonefs_handle_io_error(struct inode *inode, struct blk_zone *zone,*/ if ((z->z_flags &ZONEFS_ZONE_OFFLINE ) || (sbi->s_mount_opts &ZONEFS_MNTOPT_ERRORS_ZOL )) { -zonefs_warn (sb,"inode %lu: read/write access disabled\n" , +zonefs_warn (sb,"inode %llu: read/write access disabled\n" , inode->i_ino);if (!(z->z_flags &ZONEFS_ZONE_OFFLINE )) z->z_flags |=ZONEFS_ZONE_OFFLINE ;
@@ -316,7 +316,7 @@ static void zonefs_handle_io_error(struct inode *inode, struct blk_zone *zone, data_size =0 ; }else if ((z->z_flags &ZONEFS_ZONE_READONLY ) || (sbi->s_mount_opts &ZONEFS_MNTOPT_ERRORS_ZRO )) { -zonefs_warn (sb,"inode %lu: write access disabled\n" , +zonefs_warn (sb,"inode %llu: write access disabled\n" , inode->i_ino);if (!(z->z_flags &ZONEFS_ZONE_READONLY )) z->z_flags |=ZONEFS_ZONE_READONLY ;
@@ -402,7 +402,7 @@ void __zonefs_io_error(struct inode *inode, bool write)memalloc_noio_restore (noio_flag);if (ret !=1 ) { -zonefs_err (sb,"Get inode %lu zone information failed %d\n" , +zonefs_err (sb,"Get inode %llu zone information failed %d\n" , inode->i_ino, ret);zonefs_warn (sb,"remounting filesystem read-only\n" ); sb->s_flags |=SB_RDONLY ;
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 51/61 security: update audit format strings for u64 i_ino
In reply to Jeff LaytonUpdate %lu/%ld to %llu/%lld in security audit logging functions that print inode->i_ino, since i_ino is now u64.
Files updated: apparmor/apparmorfs.c, integrity/integrity_audit.c, ipe/audit.c, lsm_audit.c.
--- security/apparmor/apparmorfs.c | 4 ++-- security/integrity/integrity_audit.c | 2 +- security/ipe/audit.c | 2 +- security/lsm_audit.c | 10 +++++----- security/selinux/hooks.c | 4 ++-- security/smack/smack_lsm.c | 12 ++++++------ 6 files changed, 17 insertions(+), 17 deletions(-)
security/apparmor/apparmorfs.c +2 -2
@@ -149,7 +149,7 @@ static int aafs_count;static int aafs_show_path (struct seq_file *seq,struct dentry *dentry) { -seq_printf (seq,"%s:[%lu]" ,AAFS_NAME ,d_inode (dentry)->i_ino); +seq_printf (seq,"%s:[%llu]" ,AAFS_NAME ,d_inode (dentry)->i_ino);return 0 ; }
@@ -2644,7 +2644,7 @@ static int policy_readlink(struct dentry *dentry, char __user *buffer,char name[32 ];int res; - res =snprintf (name,sizeof (name),"%s:[%lu]" ,AAFS_NAME , + res =snprintf (name,sizeof (name),"%s:[%llu]" ,AAFS_NAME ,d_inode (dentry)->i_ino);if (res >0 && res <sizeof (name)) res =readlink_copy (buffer, buflen, name,strlen (name));
security/integrity/integrity_audit.c +1 -1
@@ -62,7 +62,7 @@ void integrity_audit_message(int audit_msgno, struct inode *inode,if (inode) {audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino); }audit_log_format (ab," res=%d errno=%d" , !result, errno);audit_log_end (ab);
security/ipe/audit.c +1 -1
@@ -153,7 +153,7 @@ void ipe_audit_match(const struct ipe_eval_ctx *const ctx,if (inode) {audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino); }else {audit_log_format (ab," dev=? ino=?" ); }
security/lsm_audit.c +5 -5
@@ -202,7 +202,7 @@ void audit_log_lsm_data(struct audit_buffer *ab,if (inode) {audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino); }break ; }
@@ -215,7 +215,7 @@ void audit_log_lsm_data(struct audit_buffer *ab,if (inode) {audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino); }break ; }
@@ -228,7 +228,7 @@ void audit_log_lsm_data(struct audit_buffer *ab,if (inode) {audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino); }audit_log_format (ab," ioctlcmd=0x%hx" , a->u.op->cmd);
@@ -246,7 +246,7 @@ void audit_log_lsm_data(struct audit_buffer *ab,if (inode) {audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino); }break ; }
@@ -265,7 +265,7 @@ void audit_log_lsm_data(struct audit_buffer *ab, }audit_log_format (ab," dev=" );audit_log_untrustedstring (ab, inode->i_sb->s_id); -audit_log_format (ab," ino=%lu" , inode->i_ino); +audit_log_format (ab," ino=%llu" , inode->i_ino);rcu_read_unlock ();break ; }
security/selinux/hooks.c +2 -2
@@ -1400,7 +1400,7 @@ static int inode_doinit_use_xattr(struct inode *inode, struct dentry *dentry,if (rc <0 ) {kfree (context);if (rc != -ENODATA ) { -pr_warn ("SELinux: %s: getxattr returned %d for dev=%s ino=%ld\n" , +pr_warn ("SELinux: %s: getxattr returned %d for dev=%s ino=%lld\n" , __func__, -rc, inode->i_sb->s_id, inode->i_ino);return rc; }
@@ -3477,7 +3477,7 @@ static void selinux_inode_post_setxattr(struct dentry *dentry, const char *name, &newsid);if (rc) {pr_err ("SELinux: unable to map context to SID" -"for (%s, %lu), rc=%d\n" , +"for (%s, %llu), rc=%d\n" , inode->i_sb->s_id, inode->i_ino, -rc);return ; }
security/smack/smack_lsm.c +6 -6
@@ -182,7 +182,7 @@ static int smk_bu_inode(struct inode *inode, int mode, int rc)char acc[SMK_NUM_ACCESS_TYPE +1 ];if (isp->smk_flags &SMK_INODE_IMPURE ) -pr_info ("Smack Unconfined Corruption: inode=(%s %ld) %s\n" , +pr_info ("Smack Unconfined Corruption: inode=(%s %lld) %s\n" , inode->i_sb->s_id, inode->i_ino, current->comm);if (rc <=0 )
@@ -195,7 +195,7 @@ static int smk_bu_inode(struct inode *inode, int mode, int rc)smk_bu_mode (mode, acc); -pr_info ("Smack %s: (%s %s %s) inode=(%s %ld) %s\n" , smk_bu_mess[rc], +pr_info ("Smack %s: (%s %s %s) inode=(%s %lld) %s\n" , smk_bu_mess[rc], tsp->smk_task->smk_known, isp->smk_inode->smk_known, acc, inode->i_sb->s_id, inode->i_ino, current->comm);return 0 ;
@@ -214,7 +214,7 @@ static int smk_bu_file(struct file *file, int mode, int rc)char acc[SMK_NUM_ACCESS_TYPE +1 ];if (isp->smk_flags &SMK_INODE_IMPURE ) -pr_info ("Smack Unconfined Corruption: inode=(%s %ld) %s\n" , +pr_info ("Smack Unconfined Corruption: inode=(%s %lld) %s\n" , inode->i_sb->s_id, inode->i_ino, current->comm);if (rc <=0 )
@@ -223,7 +223,7 @@ static int smk_bu_file(struct file *file, int mode, int rc) rc =0 ;smk_bu_mode (mode, acc); -pr_info ("Smack %s: (%s %s %s) file=(%s %ld %pD) %s\n" , smk_bu_mess[rc], +pr_info ("Smack %s: (%s %s %s) file=(%s %lld %pD) %s\n" , smk_bu_mess[rc], sskp->smk_known,smk_of_inode (inode)->smk_known, acc, inode->i_sb->s_id, inode->i_ino, file, current->comm);
@@ -244,7 +244,7 @@ static int smk_bu_credfile(const struct cred *cred, struct file *file,char acc[SMK_NUM_ACCESS_TYPE +1 ];if (isp->smk_flags &SMK_INODE_IMPURE ) -pr_info ("Smack Unconfined Corruption: inode=(%s %ld) %s\n" , +pr_info ("Smack Unconfined Corruption: inode=(%s %lld) %s\n" , inode->i_sb->s_id, inode->i_ino, current->comm);if (rc <=0 )
@@ -253,7 +253,7 @@ static int smk_bu_credfile(const struct cred *cred, struct file *file, rc =0 ;smk_bu_mode (mode, acc); -pr_info ("Smack %s: (%s %s %s) file=(%s %ld %pD) %s\n" , smk_bu_mess[rc], +pr_info ("Smack %s: (%s %s %s) file=(%s %lld %pD) %s\n" , smk_bu_mess[rc], sskp->smk_known,smk_of_inode (inode)->smk_known, acc, inode->i_sb->s_id, inode->i_ino, file, current->comm);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 52/61 drm/amdgpu: update for u64 i_ino
In reply to Jeff LaytonUpdate %lu to %llu in drm_info() calls that print inode->i_ino, since i_ino is now u64.
--- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_object.c +2 -2
@@ -1676,9 +1676,9 @@ u64 amdgpu_bo_print_info(int id, struct amdgpu_bo *bo, struct seq_file *m) attachment =READ_ONCE (bo->tbo.base.import_attach);if (attachment) -seq_printf (m," imported from ino:%lu" ,file_inode (dma_buf->file)->i_ino); +seq_printf (m," imported from ino:%llu" ,file_inode (dma_buf->file)->i_ino);else if (dma_buf) -seq_printf (m," exported as ino:%lu" ,file_inode (dma_buf->file)->i_ino); +seq_printf (m," exported as ino:%llu" ,file_inode (dma_buf->file)->i_ino);amdgpu_bo_print_flag (m, bo,CPU_ACCESS_REQUIRED );amdgpu_bo_print_flag (m, bo,NO_CPU_ACCESS );
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 53/61 fsnotify: update fdinfo format strings for u64 i_ino
In reply to Jeff LaytonUpdate %lx to %llx in inotify and fanotify fdinfo output for printing inode->i_ino, since i_ino is now u64.
--- fs/notify/fdinfo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
fs/notify/fdinfo.c +2 -2
@@ -84,7 +84,7 @@ static void inotify_fdinfo(struct seq_file *m, struct fsnotify_mark *mark) inode_mark = container_of(mark, struct inotify_inode_mark, fsn_mark); inode =igrab (fsnotify_conn_inode (mark->connector));if (inode) { -seq_printf (m,"inotify wd:%x ino:%lx sdev:%x mask:%x ignored_mask:0 " , +seq_printf (m,"inotify wd:%x ino:%llx sdev:%x mask:%x ignored_mask:0 " , inode_mark->wd, inode->i_ino, inode->i_sb->s_dev,inotify_mark_user_mask (mark));show_mark_fhandle (m, inode);
@@ -111,7 +111,7 @@ static void fanotify_fdinfo(struct seq_file *m, struct fsnotify_mark *mark) inode =igrab (fsnotify_conn_inode (mark->connector));if (!inode)return ; -seq_printf (m,"fanotify ino:%lx sdev:%x mflags:%x mask:%x ignored_mask:%x " , +seq_printf (m,"fanotify ino:%llx sdev:%x mflags:%x mask:%x ignored_mask:%x " , inode->i_ino, inode->i_sb->s_dev, mflags, mark->mask, mark->ignore_mask);show_mark_fhandle (m, inode);
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 54/61 net: update socket dname format for u64 i_ino
In reply to Jeff LaytonUpdate %lu to %llu in sockfs_dname() for printing i_ino, since i_ino is now u64.
--- net/socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
net/socket.c +1 -1
@@ -399,7 +399,7 @@ static const struct super_operations sockfs_ops = {*/ static char *sockfs_dname (struct dentry *dentry,char *buffer,int buflen) { -return dynamic_dname (buffer, buflen,"socket:[%lu]" , +return dynamic_dname (buffer, buflen,"socket:[%llu]" ,d_inode (dentry)->i_ino); }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 55/61 uprobes: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate %lx to %llx in uprobe warning messages for printing inode->i_ino, since i_ino is now u64.
--- kernel/events/uprobes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
kernel/events/uprobes.c +2 -2
@@ -344,7 +344,7 @@ __update_ref_ctr(struct mm_struct *mm, unsigned long vaddr, short d)static void update_ref_ctr_warn (struct uprobe *uprobe,struct mm_struct *mm,short d) { - pr_warn("ref_ctr %s failed for inode: 0x%lx offset: " + pr_warn("ref_ctr %s failed for inode: 0x%llx offset: " "0x%llx ref_ctr_offset: 0x%llx of mm: 0x%p\n", d > 0 ? "increment" : "decrement", uprobe->inode->i_ino, (unsigned long long) uprobe->offset,
@@ -982,7 +982,7 @@ static struct uprobe *insert_uprobe(struct uprobe *uprobe)static void ref_ctr_mismatch_warn (struct uprobe *cur_uprobe,struct uprobe *uprobe) { - pr_warn("ref_ctr_offset mismatch. inode: 0x%lx offset: 0x%llx " + pr_warn("ref_ctr_offset mismatch. inode: 0x%llx offset: 0x%llx " "ref_ctr_offset(old): 0x%llx ref_ctr_offset(new): 0x%llx\n", uprobe->inode->i_ino, (unsigned long long) uprobe->offset, (unsigned long long) cur_uprobe->ref_ctr_offset,
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 56/61 dma-buf: update format string for u64 i_ino
In reply to Jeff LaytonUpdate %lu to %llu in debugfs seq_printf for printing i_ino, since i_ino is now u64.
--- drivers/dma-buf/dma-buf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma-buf/dma-buf.c +1 -1
@@ -1708,7 +1708,7 @@ static int dma_buf_debug_show(struct seq_file *s, void *unused)spin_lock (&buf_obj->name_lock); - seq_printf(s, "%08zu\t%08x\t%08x\t%08ld\t%s\t%08lu\t%s\n", + seq_printf(s, "%08zu\t%08x\t%08x\t%08ld\t%s\t%08llu\t%s\n", buf_obj->size, buf_obj->file->f_flags, buf_obj->file->f_mode, file_count(buf_obj->file),
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 57/61 fscrypt: update format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings from %lu to %llu for inode->i_ino now that i_ino is u64 instead of unsigned long.
--- fs/crypto/crypto.c | 2 +- fs/crypto/hooks.c | 2 +- fs/crypto/keysetup.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
fs/crypto/crypto.c +1 -1
@@ -365,7 +365,7 @@ void fscrypt_msg(const struct inode *inode, const char *level, vaf.fmt = fmt; vaf.va = &args;if (inode && inode->i_ino) -printk ("%sfscrypt (%s, inode %lu): %pV\n" , +printk ("%sfscrypt (%s, inode %llu): %pV\n" , level, inode->i_sb->s_id, inode->i_ino, &vaf);else if (inode)printk ("%sfscrypt (%s): %pV\n" , level, inode->i_sb->s_id, &vaf);
fs/crypto/hooks.c +1 -1
@@ -62,7 +62,7 @@ int fscrypt_file_open(struct inode *inode, struct file *filp) dentry_parent =dget_parent (dentry);if (!fscrypt_has_permitted_context (d_inode (dentry_parent), inode)) {fscrypt_warn (inode, -"Inconsistent encryption context (parent directory: %lu)" , +"Inconsistent encryption context (parent directory: %llu)" ,d_inode (dentry_parent)->i_ino); err = -EPERM ; }
fs/crypto/keysetup.c +1 -1
@@ -91,7 +91,7 @@ select_encryption_mode(const union fscrypt_policy *policy,if (S_ISDIR (inode->i_mode) ||S_ISLNK (inode->i_mode))return &fscrypt_modes[fscrypt_policy_fnames_mode (policy)]; -WARN_ONCE (1 ,"fscrypt: filesystem tried to load encryption info for inode %lu, which is not encryptable (file type %d)\n" , +WARN_ONCE (1 ,"fscrypt: filesystem tried to load encryption info for inode %llu, which is not encryptable (file type %d)\n" , inode->i_ino, (inode->i_mode &S_IFMT ));return ERR_PTR (-EINVAL ); }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 58/61 fsverity: update format string for u64 i_ino
In reply to Jeff LaytonUpdate format string from %lu to %llu for inode->i_ino now that i_ino is u64 instead of unsigned long.
--- fs/verity/init.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/verity/init.c +1 -1
@@ -50,7 +50,7 @@ void fsverity_msg(const struct inode *inode, const char *level, vaf.fmt = fmt; vaf.va = &args;if (inode) -printk ("%sfs-verity (%s, inode %lu): %pV\n" , +printk ("%sfs-verity (%s, inode %llu): %pV\n" , level, inode->i_sb->s_id, inode->i_ino, &vaf);else printk ("%sfs-verity: %pV\n" , level, &vaf);
Signature · 1 line
2.53.0
Mathieu Desnoyers
reviewerRe: [PATCH 24/61] cachefiles: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 2 lines · Jeff Layton
Update format strings and local variable types in cachefiles for the
i_inotype change from unsigned long to u64.
[ Trimming huge CC list. ]
May I recommend shrinking the CC list to the list of people who actually need to be CC'd on individual changes ? Yes, this is a big task on a 61 patches series, but it's part of the expected work that goes into submitting a large series like this.
Review
Quoted 3 lines
(quoted diff) +1
-1- _enter("%pD,%li,%llx,%zx/%llx", + _enter("%pD,%llu,%llx,%zx/%llx",
This changes from signed to unsigned without any mention of why in the commit message.
Thanks,
Mathieu
Signature · 3 lines
Mathieu Desnoyers EfficiOS Inc. https://www.efficios.com
Jeff Layton
maintainerPATCH 59/61 iomap: update format string for u64 i_ino
In reply to Jeff LaytonUpdate format string from %lu to %llu for inode->i_ino now that i_ino is u64 instead of unsigned long.
--- fs/iomap/ioend.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/iomap/ioend.c +1 -1
@@ -48,7 +48,7 @@ static u32 iomap_finish_ioend_buffered(struct iomap_ioend *ioend)mapping_set_error (inode->i_mapping, ioend->io_error);if (!bio_flagged (bio,BIO_QUIET )) {pr_err_ratelimited ( -"%s: writeback error on inode %lu, offset %lld, sector %llu" , +"%s: writeback error on inode %llu, offset %lld, sector %llu" , inode->i_sb->s_id, inode->i_ino, ioend->io_offset, ioend->io_sector); }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 60/61 net: update legacy protocol format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings from %ld to %lld and 0L literals to 0LL in x25, netrom, and rose proc output, now that i_ino is u64 instead of unsigned long.
--- net/netrom/af_netrom.c | 4 ++-- net/rose/af_rose.c | 4 ++-- net/x25/x25_proc.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-)
net/netrom/af_netrom.c +2 -2
@@ -1305,7 +1305,7 @@ static int nr_info_show(struct seq_file *seq, void *v)seq_printf (seq,"%-9s " ,ax2asc (buf, &nr->user_addr));seq_printf (seq,"%-9s " ,ax2asc (buf, &nr->dest_addr)); seq_printf(seq, -"%-9s %-3s %02X/%02X %02X/%02X %2d %3d %3d %3d %3lu/%03lu %2lu/%02lu %3lu/%03lu %3lu/%03lu %2d/%02d %3d %5d %5d %ld\n", +"%-9s %-3s %02X/%02X %02X/%02X %2d %3d %3d %3d %3lu/%03lu %2lu/%02lu %3lu/%03lu %3lu/%03lu %2d/%02d %3d %5d %5d %lld\n", ax2asc(buf, &nr->source_addr), devname, nr->my_index,
@@ -1329,7 +1329,7 @@ static int nr_info_show(struct seq_file *seq, void *v) nr->window,sk_wmem_alloc_get (s),sk_rmem_alloc_get (s), - s->sk_socket ? SOCK_INODE(s->sk_socket)->i_ino : 0L); + s->sk_socket ? SOCK_INODE(s->sk_socket)->i_ino : 0LL);bh_unlock_sock (s); }
net/rose/af_rose.c +2 -2
@@ -1479,7 +1479,7 @@ static int rose_info_show(struct seq_file *seq, void *v) callsign =ax2asc (buf, &rose->source_call); seq_printf(seq, - "%-10s %-9s %-5s %3.3X %05d %d %d %d %d %3lu %3lu %3lu %3lu %3lu %3lu/%03lu %5d %5d %ld\n", + "%-10s %-9s %-5s %3.3X %05d %d %d %d %d %3lu %3lu %3lu %3lu %3lu %3lu/%03lu %5d %5d %lld\n", rose2asc(rsbuf, &rose->source_addr), callsign, devname,
@@ -1498,7 +1498,7 @@ static int rose_info_show(struct seq_file *seq, void *v) rose->idle / (60 *HZ ),sk_wmem_alloc_get (s),sk_rmem_alloc_get (s), - s->sk_socket ? SOCK_INODE(s->sk_socket)->i_ino : 0L); + s->sk_socket ? SOCK_INODE(s->sk_socket)->i_ino : 0LL); }return 0 ;
net/x25/x25_proc.c +2 -2
@@ -96,7 +96,7 @@ static int x25_seq_socket_show(struct seq_file *seq, void *v) devname = x25->neighbour->dev->name; seq_printf(seq, "%-10s %-10s %-5s %3.3X %d %d %d %d %3lu %3lu " - "%3lu %3lu %3lu %5d %5d %ld\n", + "%3lu %3lu %3lu %5d %5d %lld\n", !x25->dest_addr.x25_addr[0] ? "*" : x25->dest_addr.x25_addr, !x25->source_addr.x25_addr[0] ? "*" : x25->source_addr.x25_addr, devname, x25->lci & 0x0FFF, x25->state, x25->vs, x25->vr,
@@ -104,7 +104,7 @@ static int x25_seq_socket_show(struct seq_file *seq, void *v) x25->t21 /HZ , x25->t22 /HZ , x25->t23 /HZ ,sk_wmem_alloc_get (s),sk_rmem_alloc_get (s), - s->sk_socket ? SOCK_INODE(s->sk_socket)->i_ino : 0L); + s->sk_socket ? SOCK_INODE(s->sk_socket)->i_ino : 0LL); out:return 0 ; }
Signature · 1 line
2.53.0
Jeff Layton
maintainerPATCH 61/61 vfs: update core format strings for u64 i_ino
In reply to Jeff LaytonUpdate format strings from %lu/%lx to %llu/%llx and 0UL literal to 0ULL in pipe, dcache, fserror, and eventpoll, now that i_ino is u64 instead of unsigned long.
--- fs/dcache.c | 4 ++-- fs/eventpoll.c | 2 +- fs/fserror.c | 2 +- fs/pipe.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-)
fs/dcache.c +2 -2
@@ -1637,11 +1637,11 @@ static enum d_walk_ret umount_check(void *_data, struct dentry *dentry)if (dentry == _data && dentry->d_lockref.count ==1 )return D_WALK_CONTINUE ; - WARN(1, "BUG: Dentry %p{i=%lx,n=%pd} " + WARN(1, "BUG: Dentry %p{i=%llx,n=%pd} " " still in use (%d) [unmount of %s %s]\n", dentry, dentry->d_inode ? - dentry->d_inode->i_ino : 0UL, + dentry->d_inode->i_ino : 0ULL, dentry, dentry->d_lockref.count, dentry->d_sb->s_type->name,
fs/eventpoll.c +1 -1
@@ -1080,7 +1080,7 @@ static void ep_show_fdinfo(struct seq_file *m, struct file *f)struct inode *inode =file_inode (epi->ffd.file); seq_printf(m, "tfd: %8d events: %8x data: %16llx " - " pos:%lli ino:%lx sdev:%x\n", + " pos:%lli ino:%llx sdev:%x\n", epi->ffd.fd, epi->event.events, (long long)epi->event.data, (long long)epi->ffd.file->f_pos,
fs/fserror.c +1 -1
@@ -176,7 +176,7 @@ void fserror_report(struct super_block *sb, struct inode *inode, lost:if (inode)pr_err_ratelimited ( -"%s: lost file I/O error report for ino %lu type %u pos 0x%llx len 0x%llx error %d" , +"%s: lost file I/O error report for ino %llu type %u pos 0x%llx len 0x%llx error %d" , sb->s_id, inode->i_ino, type, pos, len, error);else pr_err_ratelimited(
fs/pipe.c +1 -1
@@ -873,7 +873,7 @@ static struct vfsmount *pipe_mnt __ro_after_init;*/ static char *pipefs_dname (struct dentry *dentry,char *buffer,int buflen) { -return dynamic_dname (buffer, buflen,"pipe:[%lu]" , +return dynamic_dname (buffer, buflen,"pipe:[%llu]" ,d_inode (dentry)->i_ino); }
Signature · 1 line
2.53.0
Mathieu Desnoyers
reviewerRe: [PATCH 61/61] vfs: update core format strings for u64 i_ino
Quoted 3 lines · Jeff Layton
Update format strings from %lu/%lx to %llu/%llx and 0UL literal to 0ULL in pipe, dcache, fserror, and eventpoll, now that
i_inois u64 instead of unsigned long.
Doing this as a fixup at the end of the series breaks bissectability.
Thanks,
Mathieu
Signature · 3 lines
Mathieu Desnoyers EfficiOS Inc. https://www.efficios.com
Mathieu Desnoyers
reviewerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
In reply to Jeff LaytonQuoted 8 lines · Jeff Layton
Change the type of
i_inoin struct inode from unsigned long to u64.On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens
i_inofrom 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.
Quoted 6 lines
The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (
__u64). The existing overflow checks incp_new_stat(),cp_old_stat(), andcp_compat_stat()handle narrowing to 32-bitst_inowith-EOVERFLOW, so userspace ABI is preserved.struct inode will grow by 4 bytes on 32-bit architectures.
Changing this type first without changing its associated format strings breaks git bisect.
One alternative would be to introduce something like the PRIu64 macro but for printing inode values. This would allow gradually introducing the change without breaking the world as you do so.
Thanks,
Mathieu
Signature · 3 lines
Mathieu Desnoyers EfficiOS Inc. https://www.efficios.com
Re: [PATCH 59/61] iomap: update format string for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · Jeff Layton
Update format string from %lu to %llu for
inode->i_inonow thati_inois u64 instead of unsigned long.Signed-off-by Jeff Layton <[email protected]>
Looks fine to me, though I'm a bit sad there's no xfs_inode::i_ino -> inode::i_ino conversion patch... ;)
--D
Quoted 22 lines
--- fs/iomap/ioend.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fs/iomap/ioend.c +1
-1@@ -48,7 +48,7 @@ static u32 iomap_finish_ioend_buffered(struct iomap_ioend *ioend)mapping_set_error (inode->i_mapping, ioend->io_error);if (!bio_flagged (bio,BIO_QUIET )) {pr_err_ratelimited ( -"%s: writeback error on inode %lu, offset %lld, sector %llu" , +"%s: writeback error on inode %llu, offset %lld, sector %llu" , inode->i_sb->s_id, inode->i_ino, ioend->io_offset, ioend->io_sector); }Signature · 2 lines
-- 2.53.0
Re: [PATCH 61/61] vfs: update core format strings for u64 i_ino
In reply to Jeff LaytonQuoted 5 lines · Jeff Layton
Update format strings from %lu/%lx to %llu/%llx and 0UL literal to 0ULL in pipe, dcache, fserror, and eventpoll, now that
i_inois u64 instead of unsigned long.Signed-off-by Jeff Layton <[email protected]>
--D
Quoted 69 lines
--- fs/dcache.c | 4 ++-- fs/eventpoll.c | 2 +- fs/fserror.c | 2 +- fs/pipe.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-)fs/dcache.c +2
-2@@ -1637,11 +1637,11 @@ static enum d_walk_ret umount_check(void *_data, struct dentry *dentry)if (dentry == _data && dentry->d_lockref.count ==1 )return D_WALK_CONTINUE ; - WARN(1, "BUG: Dentry %p{i=%lx,n=%pd} " + WARN(1, "BUG: Dentry %p{i=%llx,n=%pd} " " still in use (%d) [unmount of %s %s]\n", dentry, dentry->d_inode ? - dentry->d_inode->i_ino : 0UL, + dentry->d_inode->i_ino : 0ULL, dentry, dentry->d_lockref.count, dentry->d_sb->s_type->name,fs/eventpoll.c +1
-1@@ -1080,7 +1080,7 @@ static void ep_show_fdinfo(struct seq_file *m, struct file *f)struct inode *inode =file_inode (epi->ffd.file); seq_printf(m, "tfd: %8d events: %8x data: %16llx " - " pos:%lli ino:%lx sdev:%x\n", + " pos:%lli ino:%llx sdev:%x\n", epi->ffd.fd, epi->event.events, (long long)epi->event.data, (long long)epi->ffd.file->f_pos,fs/fserror.c +1
-1@@ -176,7 +176,7 @@ void fserror_report(struct super_block *sb, struct inode *inode, lost:if (inode)pr_err_ratelimited ( -"%s: lost file I/O error report for ino %lu type %u pos 0x%llx len 0x%llx error %d" , +"%s: lost file I/O error report for ino %llu type %u pos 0x%llx len 0x%llx error %d" , sb->s_id, inode->i_ino, type, pos, len, error);else pr_err_ratelimited(fs/pipe.c +1
-1@@ -873,7 +873,7 @@ static struct vfsmount *pipe_mnt __ro_after_init;*/ static char *pipefs_dname (struct dentry *dentry,char *buffer,int buflen) { -return dynamic_dname (buffer, buflen,"pipe:[%lu]" , +return dynamic_dname (buffer, buflen,"pipe:[%llu]" ,d_inode (dentry)->i_ino); }Signature · 2 lines
-- 2.53.0
Re: [PATCH 38/61] jfs: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · Jeff Layton
Update format strings and local variable types in jfs for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>
Quoted 46 lines
--- fs/jfs/inode.c | 2 +- fs/jfs/jfs_imap.c | 2 +- fs/jfs/jfs_metapage.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)fs/jfs/inode.c +1
-1@@ -64,7 +64,7 @@ struct inode *jfs_iget(struct super_block *sb, unsigned long ino) inode->i_op = &jfs_file_inode_operations;init_special_inode (inode, inode->i_mode, inode->i_rdev); }else { -printk (KERN_DEBUG "JFS: Invalid file type 0%04o for inode %lu.\n" , +printk (KERN_DEBUG "JFS: Invalid file type 0%04o for inode %llu.\n" , inode->i_mode, inode->i_ino);iget_failed (inode);return ERR_PTR (-EIO );fs/jfs/jfs_imap.c +1
-1@@ -302,7 +302,7 @@ int diRead(struct inode *ip)unsigned long pageno;int rel_inode; -jfs_info ("diRead: ino = %ld" , ip->i_ino); +jfs_info ("diRead: ino = %lld" , ip->i_ino); ipimap = sbi->ipimap;JFS_IP (ip)->ipimap = ipimap;fs/jfs/jfs_metapage.c +1
-1@@ -692,7 +692,7 @@ struct metapage *__get_metapage(struct inode *inode, unsigned long lblock,unsigned long page_index;unsigned long page_offset; -jfs_info ("__get_metapage: ino = %ld, lblock = 0x%lx, abs=%d" , +jfs_info ("__get_metapage: ino = %lld, lblock = 0x%lx, abs=%d" , inode->i_ino, lblock, absolute); l2bsize = inode->i_blkbits;
Jeff Layton
maintainerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
In reply to Mathieu DesnoyersQuoted 14 lines · Mathieu Desnoyers
Quoted 13 lines · Jeff Layton
Change the type of
i_inoin struct inode from unsigned long to u64.On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens
i_inofrom 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (
__u64). The existing overflow checks incp_new_stat(),cp_old_stat(), andcp_compat_stat()handle narrowing to 32-bitst_inowith-EOVERFLOW, so userspace ABI is preserved.
Quoted 10 lines
Quoted 1 line
struct inode will grow by 4 bytes on 32-bit architectures.
Changing this type first without changing its associated format strings breaks git bisect.
One alternative would be to introduce something like the PRIu64 macro but for printing inode values. This would allow gradually introducing the change without breaking the world as you do so.
True, but it makes all of the format strings even harder to read. After the conversion, we could go back and eliminate the macro though and it would keep things more bisectable. I'm not sure what to do about tracepoints though. I guess we could declare a new typedef and change its definition when i_ino's type changes?
I'll let others chime in first, but I'm open to going back and doing it that way if we don't want to live with the compiler warnings during a bisect.
Signature · 1 line
Jeff Layton <[email protected]>
Mathieu Desnoyers
reviewerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
Quoted 26 lines · Jeff Layton
Quoted 14 lines · Mathieu Desnoyers
Quoted 13 lines · Jeff Layton
Change the type of
i_inoin struct inode from unsigned long to u64.On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens
i_inofrom 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (
__u64). The existing overflow checks incp_new_stat(),cp_old_stat(), andcp_compat_stat()handle narrowing to 32-bitst_inowith-EOVERFLOW, so userspace ABI is preserved.Quoted 10 lines
Quoted 1 line
struct inode will grow by 4 bytes on 32-bit architectures.
Changing this type first without changing its associated format strings breaks git bisect.
One alternative would be to introduce something like the PRIu64 macro but for printing inode values. This would allow gradually introducing the change without breaking the world as you do so.
Quoted 5 lines
True, but it makes all of the format strings even harder to read. After the conversion, we could go back and eliminate the macro though and it would keep things more bisectable. I'm not sure what to do about tracepoints though. I guess we could declare a new typedef and change its definition when i_ino's type changes?
For tracepoints there are two things: a TP_printk format string (which would be handled by a new pretty printing macro similar to PRIu64), and the type used within TP_STRUCT__entry. I don't see why you'd need to change from ino_t to u64 there. The conversion will happen when you flip the ino_t typedef from unsigned long to u64.
Quoted 4 lines
I'll let others chime in first, but I'm open to going back and doing it that way if we don't want to live with the compiler warnings during a bisect.
On 32-bit archs, I suspect it will do more than emit compiler warnings. Trying to boot a kernel in the middle of the series is likely to lead to interesting inode value printout results.
Thanks,
Mathieu
Signature · 3 lines
Mathieu Desnoyers EfficiOS Inc. https://www.efficios.com
Jeff Layton
maintainerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
Quoted 33 lines · Mathieu Desnoyers
Quoted 26 lines · Jeff Layton
Quoted 14 lines · Mathieu Desnoyers
Quoted 13 lines · Jeff Layton
Change the type of
i_inoin struct inode from unsigned long to u64.On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens
i_inofrom 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (
__u64). The existing overflow checks incp_new_stat(),cp_old_stat(), andcp_compat_stat()handle narrowing to 32-bitst_inowith-EOVERFLOW, so userspace ABI is preserved.Quoted 10 lines
Quoted 1 line
struct inode will grow by 4 bytes on 32-bit architectures.
Changing this type first without changing its associated format strings breaks git bisect.
One alternative would be to introduce something like the PRIu64 macro but for printing inode values. This would allow gradually introducing the change without breaking the world as you do so.
Quoted 5 lines
True, but it makes all of the format strings even harder to read. After the conversion, we could go back and eliminate the macro though and it would keep things more bisectable. I'm not sure what to do about tracepoints though. I guess we could declare a new typedef and change its definition when i_ino's type changes?
Quoted 6 lines
For tracepoints there are two things: a
TP_printkformat string (which would be handled by a new pretty printing macro similar to PRIu64), and the type used withinTP_STRUCT__entry. I don't see why you'd need to change fromino_tto u64 there. The conversion will happen when you flip theino_ttypedef from unsigned long to u64.
My worry here is that ino_t is a UAPI type, and I don't think we can change it there. I think we'll need a new (kernel-internal) typedef just for this.
Quoted 9 lines
Quoted 4 lines
I'll let others chime in first, but I'm open to going back and doing it that way if we don't want to live with the compiler warnings during a bisect.
On 32-bit archs, I suspect it will do more than emit compiler warnings. Trying to boot a kernel in the middle of the series is likely to lead to interesting inode value printout results.
Definitely. None of that would be trustworthy in the middle of the series.
Signature · 1 line
Jeff Layton <[email protected]>
Mathieu Desnoyers
reviewerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
Quoted 41 lines · Jeff Layton
Quoted 33 lines · Mathieu Desnoyers
Quoted 26 lines · Jeff Layton
Quoted 14 lines · Mathieu Desnoyers
Quoted 13 lines · Jeff Layton
Change the type of
i_inoin struct inode from unsigned long to u64.On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens
i_inofrom 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (
__u64). The existing overflow checks incp_new_stat(),cp_old_stat(), andcp_compat_stat()handle narrowing to 32-bitst_inowith-EOVERFLOW, so userspace ABI is preserved.Quoted 10 lines
Quoted 1 line
struct inode will grow by 4 bytes on 32-bit architectures.
Changing this type first without changing its associated format strings breaks git bisect.
One alternative would be to introduce something like the PRIu64 macro but for printing inode values. This would allow gradually introducing the change without breaking the world as you do so.
Quoted 5 lines
True, but it makes all of the format strings even harder to read. After the conversion, we could go back and eliminate the macro though and it would keep things more bisectable. I'm not sure what to do about tracepoints though. I guess we could declare a new typedef and change its definition when i_ino's type changes?
Quoted 6 lines
For tracepoints there are two things: a
TP_printkformat string (which would be handled by a new pretty printing macro similar to PRIu64), and the type used withinTP_STRUCT__entry. I don't see why you'd need to change fromino_tto u64 there. The conversion will happen when you flip theino_ttypedef from unsigned long to u64.
Quoted 3 lines
My worry here is that
ino_tis a UAPI type, and I don't think we can change it there. I think we'll need a new (kernel-internal) typedef just for this.
If ino_t is UAPI then it cannot be changed, but you can introduce a new kino_t or whatever naming is appropriate.
Thanks,
Mathieu
Signature · 3 lines
Mathieu Desnoyers EfficiOS Inc. https://www.efficios.com
Re: [PATCH 19/61] affs: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · Jeff Layton
Update format strings and local variable types in affs for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>
Matthew Wilcox
maintainerQuoted 4 lines · Jeff Layton
The bulk of the changes are to format strings and tracepoints, since the kernel itself doesn't care that much about the
i_inofield. The first patch changes some vfs function arguments, so check that one out carefully.
Why are the format strings all done as separate patches? Don't we get bisection hazards by splitting it apart this way?
______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Re: [PATCH 13/61] smb: store full 64-bit uniqueid in i_ino
In reply to Jeff LaytonQuoted 8 lines · Jeff Layton
With
i_inonow u64, CIFS/SMB can store the full 64-bit uniqueid ini_inowithout the XOR-folding hack previously needed on 32-bit architectures.- Simplify
cifs_uniqueid_to_ino_t()to return u64 directly
- Update hash variable type incifs_get_inode_info()
- Update format strings from %lu to %llu
Quoted 5 lines
Signed-off-by Jeff Layton <[email protected]>--- fs/smb/client/cifsfs.h | 12 +++--------- fs/smb/client/inode.c | 4 ++-- 2 files changed, 5 insertions(+), 11 deletions(-)
Re: [PATCH 14/61] smb: remove cifs_uniqueid_to_ino_t()
In reply to Jeff LaytonQuoted 7 lines · Jeff Layton
Now that
i_inois u64,cifs_uniqueid_to_ino_t()is a trivial identity function. Remove it and usefattr->cf_uniqueiddirectly at both call sites.Also remove the now-unused #include <
linux/hash.h>, which was only needed for the old XOR-folding logic.
Quoted 6 lines
Signed-off-by Jeff Layton <[email protected]>--- fs/smb/client/cifsfs.h | 11 ----------- fs/smb/client/inode.c | 2 +- fs/smb/client/readdir.c | 2 +- 3 files changed, 2 insertions(+), 13 deletions(-)
Re: [PATCH 01/61] vfs: widen inode hash/lookup functions to u64
In reply to Jeff LaytonQuoted 17 lines · Jeff Layton
Change the inode hash/lookup VFS API functions to accept u64 parameters instead of unsigned long for inode numbers and hash values. This is preparation for widening
i_inoitself to u64, which will allow filesystems to store full 64-bit inode numbers on 32-bit architectures.Since unsigned long implicitly widens to u64 on all architectures, this change is backward-compatible with all existing callers.
Functions updated:
-hash(),find_inode_fast(),find_inode_by_ino_rcu(),test_inode_iunique()
-__insert_inode_hash(),iget_locked(),iget5_locked(),iget5_locked_rcu()
-ilookup(),ilookup5(),ilookup5_nowait()
-find_inode_nowait(),find_inode_rcu()
-inode_insert5(),insert_inode_locked4()
-insert_inode_locked()(local variable)
-dump_mapping()(local variable and format string)
Quoted 1 line
Signed-off-by Jeff Layton <[email protected]>
Looks good. Feel free to add:
Honza
Quoted 267 lines
--- fs/inode.c | 46 +++++++++++++++++++++++----------------------- include/linux/fs.h | 26 +++++++++++++------------- 2 files changed, 36 insertions(+), 36 deletions(-)fs/inode.c +23
-23@@ -672,7 +672,7 @@ static inline void inode_sb_list_del(struct inode *inode) } } -static unsigned long hash (struct super_block *sb,unsigned long hashval) +static unsigned long hash (struct super_block *sb,u64 hashval) {unsigned long tmp;@@ -685,12 +685,12 @@ static unsigned long hash(struct super_block *sb, unsigned long hashval)/** * __insert_inode_hash - hash an inode * @inode: unhashed inode -* @hashval: unsigned long value used to locate this object in the +* @hashval: u64 value used to locate this object in the * inode_hashtable. * * Add an inode to the inode hash for this superblock. */ -void __insert_inode_hash (struct inode *inode,unsigned long hashval) +void __insert_inode_hash (struct inode *inode,u64 hashval) {struct hlist_head *b = inode_hashtable +hash (inode->i_sb, hashval);@@ -726,7 +726,7 @@ void dump_mapping(const struct address_space *mapping)struct dentry *dentry_ptr;struct dentry dentry;char fname[64 ] = {}; -unsigned long ino; +u64 ino;/* * If mapping is an invalid pointer, we don't want to crash @@ -750,14 +750,14 @@ void dump_mapping(const struct address_space *mapping) }if (!dentry_first) { -pr_warn ("aops:%ps ino:%lx\n" , a_ops, ino); +pr_warn ("aops:%ps ino:%llx\n" , a_ops, ino);return ; } dentry_ptr = container_of(dentry_first, struct dentry, d_u.d_alias);if (get_kernel_nofault (dentry, dentry_ptr) || !dentry.d_parent || !dentry.d_name.name) { -pr_warn ("aops:%ps ino:%lx invalid dentry:%px\n" , +pr_warn ("aops:%ps ino:%llx invalid dentry:%px\n" , a_ops, ino, dentry_ptr);return ; }@@ -768,7 +768,7 @@ void dump_mapping(const struct address_space *mapping)* Even if strncpy_from_kernel_nofault() succeeded, * the fname could be unreliable */ -pr_warn ("aops:%ps ino:%lx dentry name(?):\"%s\"\n" , +pr_warn ("aops:%ps ino:%llx dentry name(?):\"%s\"\n" , a_ops, ino, fname); }@@ -1087,7 +1087,7 @@ static struct inode *find_inode(struct super_block *sb,* iget_locked for details. */ static struct inode *find_inode_fast (struct super_block *sb, -struct hlist_head *head,unsigned long ino, +struct hlist_head *head,u64 ino,bool hash_locked,bool *isnew) {struct inode *inode =NULL ;@@ -1301,7 +1301,7 @@ EXPORT_SYMBOL(unlock_two_nondirectories);* Note that both @test and @set are called with the inode_hash_lock held, so * they can't sleep. */ -struct inode *inode_insert5 (struct inode *inode,unsigned long hashval, +struct inode *inode_insert5 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data) {@@ -1378,7 +1378,7 @@ EXPORT_SYMBOL(inode_insert5);* Note that both @test and @set are called with the inode_hash_lock held, so * they can't sleep. */ -struct inode *iget5_locked (struct super_block *sb,unsigned long hashval, +struct inode *iget5_locked (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data) {@@ -1408,7 +1408,7 @@ EXPORT_SYMBOL(iget5_locked);* This is equivalent to iget5_locked, except the @test callback must * tolerate the inode not being stable, including being mid-teardown. */ -struct inode *iget5_locked_rcu (struct super_block *sb,unsigned long hashval, +struct inode *iget5_locked_rcu (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data) {@@ -1455,7 +1455,7 @@ EXPORT_SYMBOL_GPL(iget5_locked_rcu);* hashed, and with the I_NEW flag set. The file system gets to fill it in * before unlocking it via unlock_new_inode(). */ -struct inode *iget_locked (struct super_block *sb,unsigned long ino) +struct inode *iget_locked (struct super_block *sb,u64 ino) {struct hlist_head *head = inode_hashtable +hash (sb, ino);struct inode *inode;@@ -1527,7 +1527,7 @@ EXPORT_SYMBOL(iget_locked);* * Returns 1 if the inode number is unique, 0 if it is not. */ -static int test_inode_iunique (struct super_block *sb,unsigned long ino) +static int test_inode_iunique (struct super_block *sb,u64 ino) {struct hlist_head *b = inode_hashtable +hash (sb, ino);struct inode *inode;@@ -1616,7 +1616,7 @@ EXPORT_SYMBOL(igrab);* * Note2: @test is called with the inode_hash_lock held, so can't sleep. */ -struct inode *ilookup5_nowait (struct super_block *sb,unsigned long hashval, +struct inode *ilookup5_nowait (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data,bool *isnew) {struct hlist_head *head = inode_hashtable +hash (sb, hashval);@@ -1647,7 +1647,7 @@ EXPORT_SYMBOL(ilookup5_nowait);* * Note: @test is called with the inode_hash_lock held, so can't sleep. */ -struct inode *ilookup5 (struct super_block *sb,unsigned long hashval, +struct inode *ilookup5 (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct inode *inode;@@ -1677,7 +1677,7 @@ EXPORT_SYMBOL(ilookup5);* Search for the inode @ino in the inode cache, and if the inode is in the * cache, the inode is returned with an incremented reference count. */ -struct inode *ilookup (struct super_block *sb,unsigned long ino) +struct inode *ilookup (struct super_block *sb,u64 ino) {struct hlist_head *head = inode_hashtable +hash (sb, ino);struct inode *inode;@@ -1726,8 +1726,8 @@ EXPORT_SYMBOL(ilookup);* very carefully implemented. */ struct inode *find_inode_nowait (struct super_block *sb, -unsigned long hashval, -int (*match)(struct inode *,unsigned long , +u64 hashval, +int (*match)(struct inode *,u64 ,void *),void *data) {@@ -1773,7 +1773,7 @@ EXPORT_SYMBOL(find_inode_nowait);* * The caller must hold the RCU read lock. */ -struct inode *find_inode_rcu (struct super_block *sb,unsigned long hashval, +struct inode *find_inode_rcu (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct hlist_head *head = inode_hashtable +hash (sb, hashval);@@ -1812,7 +1812,7 @@ EXPORT_SYMBOL(find_inode_rcu);* The caller must hold the RCU read lock. */ struct inode *find_inode_by_ino_rcu (struct super_block *sb, -unsigned long ino) +u64 ino) {struct hlist_head *head = inode_hashtable +hash (sb, ino);struct inode *inode;@@ -1833,7 +1833,7 @@ EXPORT_SYMBOL(find_inode_by_ino_rcu);int insert_inode_locked (struct inode *inode) {struct super_block *sb = inode->i_sb; -ino_t ino = inode->i_ino; +u64 ino = inode->i_ino;struct hlist_head *head = inode_hashtable +hash (sb, ino);bool isnew;@@ -1884,7 +1884,7 @@ int insert_inode_locked(struct inode *inode) }EXPORT_SYMBOL (insert_inode_locked); -int insert_inode_locked4 (struct inode *inode,unsigned long hashval, +int insert_inode_locked4 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct inode *old;@@ -2642,7 +2642,7 @@ void init_special_inode(struct inode *inode, umode_t mode, dev_t rdev)break ;default :printk (KERN_DEBUG "init_special_inode: bogus i_mode (%o) for" -" inode %s:%lu\n" , mode, inode->i_sb->s_id, +" inode %s:%llu\n" , mode, inode->i_sb->s_id, inode->i_ino);break ; }include/linux/fs.h +13
-13@@ -2935,32 +2935,32 @@ static inline int inode_generic_drop(struct inode *inode)extern void d_mark_dontcache (struct inode *inode);extern struct inode *ilookup5_nowait (struct super_block *sb, -unsigned long hashval,int (*test)(struct inode *,void *), +u64 hashval,int (*test)(struct inode *,void *),void *data,bool *isnew); -extern struct inode *ilookup5 (struct super_block *sb,unsigned long hashval, +extern struct inode *ilookup5 (struct super_block *sb,u64 hashval,int (*test)(struct inode *,void *),void *data); -extern struct inode *ilookup (struct super_block *sb,unsigned long ino); +extern struct inode *ilookup (struct super_block *sb,u64 ino); -extern struct inode *inode_insert5 (struct inode *inode,unsigned long hashval, +extern struct inode *inode_insert5 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *data); -struct inode *iget5_locked (struct super_block *,unsigned long , +struct inode *iget5_locked (struct super_block *,u64 ,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *); -struct inode *iget5_locked_rcu (struct super_block *,unsigned long , +struct inode *iget5_locked_rcu (struct super_block *,u64 ,int (*test)(struct inode *,void *),int (*set)(struct inode *,void *),void *); -extern struct inode *iget_locked (struct super_block *,unsigned long ); +extern struct inode *iget_locked (struct super_block *,u64 );extern struct inode *find_inode_nowait (struct super_block *, -unsigned long , +u64 ,int (*match)(struct inode *, -unsigned long ,void *), +u64 ,void *),void *data); -extern struct inode *find_inode_rcu (struct super_block *,unsigned long , +extern struct inode *find_inode_rcu (struct super_block *,u64 ,int (*)(struct inode *,void *),void *); -extern struct inode *find_inode_by_ino_rcu (struct super_block *,unsigned long ); -extern int insert_inode_locked4 (struct inode *,unsigned long ,int (*test)(struct inode *,void *),void *); +extern struct inode *find_inode_by_ino_rcu (struct super_block *,u64 ); +extern int insert_inode_locked4 (struct inode *,u64 ,int (*test)(struct inode *,void *),void *);extern int insert_inode_locked (struct inode *);#ifdef CONFIG_DEBUG_LOCK_ALLOC extern void lockdep_annotate_inode_mutex_key (struct inode *inode);@@ -3015,7 +3015,7 @@ int setattr_should_drop_sgid(struct mnt_idmap *idmap,*/ #define alloc_inode_sb (_sb, _cache, _gfp) kmem_cache_alloc_lru(_cache, &_sb->s_inode_lru, _gfp) -extern void __insert_inode_hash (struct inode *,unsigned long hashval); +extern void __insert_inode_hash (struct inode *,u64 hashval);static inline void insert_inode_hash (struct inode *inode) {__insert_inode_hash (inode, inode->i_ino);Signature · 2 lines
-- 2.53.0
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Jeff Layton
maintainerQuoted 8 lines · Matthew Wilcox
Quoted 4 lines · Jeff Layton
The bulk of the changes are to format strings and tracepoints, since the kernel itself doesn't care that much about the
i_inofield. The first patch changes some vfs function arguments, so check that one out carefully.Why are the format strings all done as separate patches? Don't we get bisection hazards by splitting it apart this way?
One big patch would be Yuuuuge. We could certainly do it that way, but it'll be nightmare if we ever do have to revert part of it. What do you suggest?
Signature · 1 line
Jeff Layton <[email protected]>
Jan Kara
maintainerRe: [PATCH 03/61] trace: update VFS-layer trace events for u64 i_ino
In reply to Jeff LaytonQuoted 13 lines · Jeff Layton
Update trace event definitions in VFS-layer trace headers to use u64 instead of ino_t/unsigned long for inode number fields, and change format strings from %lu/%lx to %llu/%llx to match.
This is needed because
i_inois now u64. Changing trace event field types changes the binary trace format, but the self-describing format metadata handles this transparently for modern trace-cmd and perf.Files updated:
-cachefiles.h,filelock.h,filemap.h,fs_dax.h,fsverity.h,hugetlbfs.h,netfs.h,readahead.h,timestamp.h,writeback.hSigned-off-by Jeff Layton <[email protected]>
...
Quoted 14 lines
include/trace/events/writeback.h +1
-1@@ -67,7 +67,7 @@ DECLARE_EVENT_CLASS(writeback_folio_template,TP_STRUCT__entry ( __array(char, name, 32) - __field(ino_t, ino) + __field(u64, ino)__field (pgoff_t, index) ),
include/trace/events/writeback.h DECLARE_EVENT_CLASS(writeback_folio_template, · line 84
Quoted 8 lines
include/trace/events/writeback.h +2
-2@@ -79,9 +79,9 @@ DECLARE_EVENT_CLASS(writeback_folio_template, __entry->index = folio->index; ), - TP_printk("bdi %s: ino=%lu index=%lu", + TP_printk("bdi %s: ino=%llu index=%lu", __entry->name, - (unsigned long)__entry->ino, + (unsigned long long)__entry->ino,
No need for explicit typing to ULL?
Quoted 13 lines
include/trace/events/writeback.h +1
-1__entry->index ) );@@ -108,7 +108,7 @@ DECLARE_EVENT_CLASS(writeback_dirty_inode_template,TP_STRUCT__entry ( __array(char, name, 32) - __field(ino_t, ino) + __field(u64, ino) __field(unsigned long, state) __field(unsigned long, flags) ),
include/trace/events/writeback.h DECLARE_EVENT_CLASS(writeback_dirty_inode_template, · line 128
Quoted 8 lines
include/trace/events/writeback.h +2
-2@@ -123,9 +123,9 @@ DECLARE_EVENT_CLASS(writeback_dirty_inode_template, __entry->flags = flags; ), - TP_printk("bdi %s: ino=%lu state=%s flags=%s", + TP_printk("bdi %s: ino=%llu state=%s flags=%s", __entry->name, - (unsigned long)__entry->ino, + (unsigned long long)__entry->ino,
And here as well? And many times below as well...
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Eric Biggers
maintainerRe: [PATCH 57/61] fscrypt: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 9 lines · Jeff Layton
Update format strings from %lu to %llu for
inode->i_inonow thati_inois u64 instead of unsigned long.Signed-off-by Jeff Layton <[email protected]>--- fs/crypto/crypto.c | 2 +- fs/crypto/hooks.c | 2 +- fs/crypto/keysetup.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
check_for_busy_inodes() needs to be updated too. It copies i_ino to a local variable of type 'unsigned long', then prints it with %lu.
Seems that there needs to be a search for other code that copies i_ino to a local variable, as this issue is unlikely to be unique to here.
- Eric
Jan Kara
maintainerRe: [PATCH 01/61] vfs: widen inode hash/lookup functions to u64
In reply to Jan KaraQuoted 18 lines · Jan Kara
Quoted 17 lines · Jeff Layton
Change the inode hash/lookup VFS API functions to accept u64 parameters instead of unsigned long for inode numbers and hash values. This is preparation for widening
i_inoitself to u64, which will allow filesystems to store full 64-bit inode numbers on 32-bit architectures.Since unsigned long implicitly widens to u64 on all architectures, this change is backward-compatible with all existing callers.
Functions updated:
-hash(),find_inode_fast(),find_inode_by_ino_rcu(),test_inode_iunique()
-__insert_inode_hash(),iget_locked(),iget5_locked(),iget5_locked_rcu()
-ilookup(),ilookup5(),ilookup5_nowait()
-find_inode_nowait(),find_inode_rcu()
-inode_insert5(),insert_inode_locked4()
-insert_inode_locked()(local variable)
-dump_mapping()(local variable and format string)
Quoted 5 lines
Quoted 1 line
Signed-off-by Jeff Layton <[email protected]>Looks good. Feel free to add:
Reviewed-by Jan Kara <[email protected]>
Thinking some more about this (and also seeing the discussion about patch
2) - maybe instead of using explicit u64 we should typedef kino_t as u64 and use that?
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Jan Kara
maintainerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
In reply to Jeff LaytonQuoted 7 lines · Jeff Layton
Quoted 6 lines · Mathieu Desnoyers
Quoted 4 lines · Jeff Layton
I'll let others chime in first, but I'm open to going back and doing it that way if we don't want to live with the compiler warnings during a bisect.
Quoted 7 lines
Quoted 4 lines
On 32-bit archs, I suspect it will do more than emit compiler warnings. Trying to boot a kernel in the middle of the series is likely to lead to interesting inode value printout results.
Definitely. None of that would be trustworthy in the middle of the series.
Yeah, I think defining kino_t in the beginning as unsigned long, convert everything (including special format string specifier) to it, then switch it to u64 and finally just 'sed-out' the format string specifier in the final patch shouldn't be harder than what you do here and should keep bisectability?
Honza
Signature · 2 lines
Jan Kara <[email protected]> SUSE Labs, CR
Steven Rostedt
maintainerRe: [PATCH 03/61] trace: update VFS-layer trace events for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · On Thu, 26 Feb 2026 10:55:05 -0500 Jeff Layton <[email protected]> wrote:
Update trace event definitions in VFS-layer trace headers to use u64 instead of ino_t/unsigned long for inode number fields, and change format strings from %lu/%lx to %llu/%llx to match.
Quoted 8 lines
This is needed because
i_inois now u64. Changing trace event field types changes the binary trace format, but the self-describing format metadata handles this transparently for modern trace-cmd and perf.Files updated:
-cachefiles.h,filelock.h,filemap.h,fs_dax.h,fsverity.h,hugetlbfs.h,netfs.h,readahead.h,timestamp.h,writeback.h
Hmm, on 32 bit systems, this will likely cause "holes" in a lot of these events.
Quoted 19 lines
Signed-off-by Jeff Layton <[email protected]>--- include/trace/events/cachefiles.h | 18 ++--- include/trace/events/filelock.h | 16 ++--- include/trace/events/filemap.h | 20 +++--- include/trace/events/fs_dax.h | 20 +++--- include/trace/events/fsverity.h | 30 ++++---- include/trace/events/hugetlbfs.h | 28 ++++---- include/trace/events/netfs.h | 4 +- include/trace/events/readahead.h | 12 ++-- include/trace/events/timestamp.h | 12 ++-- include/trace/events/writeback.h | 148 +++++++++++++++++++------------------- 10 files changed, 154 insertions(+), 154 deletions(-)include/trace/events/cachefiles.h +0
-0
include/trace/events/cachefiles.h TRACE_EVENT(cachefiles_lookup, · line 253
Quoted 3 lines
include/trace/events/cachefiles.h +0
-0@@ -251,8 +251,8 @@ TRACE_EVENT(cachefiles_lookup,TP_STRUCT__entry (__field (unsigned int ,obj ) __field(short, error)
There was already a 2 byte hole here, but that's not a big deal.
Quoted 17 lines
include/trace/events/cachefiles.h +3
-3- __field(unsigned long, dino) -__field (unsigned long , ino) + __field(u64, dino) +__field (u64, ino) ), TP_fast_assign(@@ -263,7 +263,7 @@ TRACE_EVENT(cachefiles_lookup, __entry->error =IS_ERR (de) ?PTR_ERR (de) :0 ; ), -TP_printk ("o=%08x dB=%lx B=%lx e=%d" , +TP_printk ("o=%08x dB=%llx B=%llx e=%d" , __entry->obj, __entry->dino, __entry->ino, __entry->error) );
include/trace/events/cachefiles.h TRACE_EVENT(cachefiles_mark_active, · line 582
Quoted 5 lines
include/trace/events/cachefiles.h +1
-1@@ -579,7 +579,7 @@ TRACE_EVENT(cachefiles_mark_active,/* Note that obj may be NULL */ TP_STRUCT__entry (__field (unsigned int ,obj ) - __field(ino_t, inode) + __field(u64, inode)
Might be better to reorder any of these that have int first.
u64 inode; int obj;
Will be packed tighter than:
int obj u64 inode;
Probably should have changed that before anyway.
Quoted 13 lines
include/trace/events/cachefiles.h +1
-1), TP_fast_assign(@@ -587,7 +587,7 @@ TRACE_EVENT(cachefiles_mark_active, __entry->inode = inode->i_ino; ), -TP_printk ("o=%08x B=%lx" , +TP_printk ("o=%08x B=%llx" , __entry->obj, __entry->inode) );
include/trace/events/cachefiles.h TRACE_EVENT(cachefiles_mark_failed, · line 603
Quoted 5 lines
include/trace/events/cachefiles.h +1
-1@@ -600,7 +600,7 @@ TRACE_EVENT(cachefiles_mark_failed,/* Note that obj may be NULL */ TP_STRUCT__entry (__field (unsigned int ,obj ) - __field(ino_t, inode) + __field(u64, inode)
Is ino_t being changed? Why the update here?
Quoted 13 lines
include/trace/events/cachefiles.h +1
-1), TP_fast_assign(@@ -608,7 +608,7 @@ TRACE_EVENT(cachefiles_mark_failed, __entry->inode = inode->i_ino; ), -TP_printk ("o=%08x B=%lx" , +TP_printk ("o=%08x B=%llx" , __entry->obj, __entry->inode) );
include/trace/events/cachefiles.h TRACE_EVENT(cachefiles_mark_inactive, · line 624
Quoted 5 lines
include/trace/events/cachefiles.h +1
-1@@ -621,7 +621,7 @@ TRACE_EVENT(cachefiles_mark_inactive,/* Note that obj may be NULL */ TP_STRUCT__entry (__field (unsigned int ,obj ) - __field(ino_t, inode) + __field(u64, inode)
Ditto.
Quoted 35 lines
include/trace/events/cachefiles.h +1
-1), TP_fast_assign(@@ -629,7 +629,7 @@ TRACE_EVENT(cachefiles_mark_inactive, __entry->inode = inode->i_ino; ), -TP_printk ("o=%08x B=%lx" , +TP_printk ("o=%08x B=%llx" , __entry->obj, __entry->inode) );include/trace/events/filelock.h +2
-2@@ -42,7 +42,7 @@ TRACE_EVENT(locks_get_lock_context, TP_ARGS(inode, type, ctx),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev) __field(unsigned char, type) __field(struct file_lock_context *, ctx)@@ -55,7 +55,7 @@ TRACE_EVENT(locks_get_lock_context, __entry->ctx = ctx; ), -TP_printk ("dev=0x%x:0x%x ino=0x%lx type=%s ctx=%p" , +TP_printk ("dev=0x%x:0x%x ino=0x%llx type=%s ctx=%p" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino,show_fl_type (__entry->type), __entry->ctx) );
include/trace/events/filelock.h DECLARE_EVENT_CLASS(filelock_lock, · line 70
Quoted 5 lines
include/trace/events/filelock.h +1
-1@@ -67,7 +67,7 @@ DECLARE_EVENT_CLASS(filelock_lock,TP_STRUCT__entry (__field (struct file_lock *,fl ) - __field(unsigned long, i_ino) + __field(u64, i_ino)
Having u64 before a pointer would be tighter on 32 bit systems, and leaves out any holes in the trace.
Quoted 13 lines
include/trace/events/filelock.h +1
-1__field(dev_t, s_dev) __field(struct file_lock_core *, blocker)__field (fl_owner_t, owner)@@ -93,7 +93,7 @@ DECLARE_EVENT_CLASS(filelock_lock, __entry->ret = ret; ), - TP_printk("fl=%p dev=0x%x:0x%x ino=0x%lx fl_blocker=%p fl_owner=%p fl_pid=%u fl_flags=%s fl_type=%s fl_start=%lld fl_end=%lld ret=%d", + TP_printk("fl=%p dev=0x%x:0x%x ino=0x%llx fl_blocker=%p fl_owner=%p fl_pid=%u fl_flags=%s fl_type=%s fl_start=%lld fl_end=%lld ret=%d", __entry->fl, MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->blocker, __entry->owner, __entry->pid, show_fl_flags(__entry->flags),
include/trace/events/filelock.h DECLARE_EVENT_CLASS(filelock_lease, · line 127
Quoted 5 lines
include/trace/events/filelock.h +1
-1@@ -124,7 +124,7 @@ DECLARE_EVENT_CLASS(filelock_lease,TP_STRUCT__entry (__field (struct file_lease *,fl ) - __field(unsigned long, i_ino) + __field(u64, i_ino)
Same here.
Quoted 35 lines
include/trace/events/filelock.h +3
-3__field(dev_t, s_dev) __field(struct file_lock_core *, blocker)__field (fl_owner_t, owner)@@ -146,7 +146,7 @@ DECLARE_EVENT_CLASS(filelock_lease, __entry->downgrade_time = fl ? fl->fl_downgrade_time :0 ; ), - TP_printk("fl=%p dev=0x%x:0x%x ino=0x%lx fl_blocker=%p fl_owner=%p fl_flags=%s fl_type=%s fl_break_time=%lu fl_downgrade_time=%lu", + TP_printk("fl=%p dev=0x%x:0x%x ino=0x%llx fl_blocker=%p fl_owner=%p fl_flags=%s fl_type=%s fl_break_time=%lu fl_downgrade_time=%lu", __entry->fl, MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->blocker, __entry->owner, show_fl_flags(__entry->flags),@@ -175,7 +175,7 @@ TRACE_EVENT(generic_add_lease,TP_ARGS (inode, fl),TP_STRUCT__entry ( - __field(unsigned long, i_ino) + __field(u64, i_ino) __field(int, wcount) __field(int, rcount) __field(int, icount)@@ -196,7 +196,7 @@ TRACE_EVENT(generic_add_lease, __entry->type = fl->c.flc_type; ), - TP_printk("dev=0x%x:0x%x ino=0x%lx wcount=%d rcount=%d icount=%d fl_owner=%p fl_flags=%s fl_type=%s", + TP_printk("dev=0x%x:0x%x ino=0x%llx wcount=%d rcount=%d icount=%d fl_owner=%p fl_flags=%s fl_type=%s", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->wcount, __entry->rcount, __entry->icount, __entry->owner,include/trace/events/filemap.h +0
-0
include/trace/events/filemap.h DECLARE_EVENT_CLASS(mm_filemap_op_page_cache, · line 24
Quoted 5 lines
include/trace/events/filemap.h +1
-1@@ -21,7 +21,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache,TP_STRUCT__entry (__field (unsigned long ,pfn ) - __field(unsigned long, i_ino) + __field(u64, i_ino)
Again, this would cause a 32 bit hole.
Quoted 67 lines
include/trace/events/filemap.h +7
-7__field(unsigned long, index) __field(dev_t, s_dev) __field(unsigned char, order)@@ -38,7 +38,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache, __entry->order =folio_order (folio); ), - TP_printk("dev %d:%d ino %lx pfn=0x%lx ofs=%lu order=%u", + TP_printk("dev %d:%d ino %llx pfn=0x%lx ofs=%lu order=%u", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, __entry->pfn,@@ -67,7 +67,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache_range, TP_ARGS(mapping, index, last_index),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev) __field(unsigned long, index) __field(unsigned long, last_index)@@ -85,7 +85,7 @@ DECLARE_EVENT_CLASS(mm_filemap_op_page_cache_range, ), TP_printk( - "dev=%d:%d ino=%lx ofs=%lld-%lld", + "dev=%d:%d ino=%llx ofs=%lld-%lld", MAJOR(__entry->s_dev), MINOR(__entry->s_dev), __entry->i_ino, ((loff_t)__entry->index) << PAGE_SHIFT,@@ -117,7 +117,7 @@ TRACE_EVENT(mm_filemap_fault, TP_ARGS(mapping, index),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev) __field(unsigned long, index) ),@@ -133,7 +133,7 @@ TRACE_EVENT(mm_filemap_fault, ),TP_printk ( -"dev=%d:%d ino=%lx ofs=%lld" , +"dev=%d:%d ino=%llx ofs=%lld" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, ((loff_t)__entry->index) << PAGE_SHIFT@@ -146,7 +146,7 @@ TRACE_EVENT(filemap_set_wb_err, TP_ARGS(mapping, eseq),TP_STRUCT__entry ( -__field (unsigned long ,i_ino ) +__field (u64 ,i_ino )__field (dev_t, s_dev)__field (errseq_t, errseq) ),@@ -160,7 +160,7 @@ TRACE_EVENT(filemap_set_wb_err, __entry->s_dev = mapping->host->i_rdev; ), -TP_printk ("dev=%d:%d ino=0x%lx errseq=0x%x" , +TP_printk ("dev=%d:%d ino=0x%llx errseq=0x%x" ,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, __entry->errseq) );
include/trace/events/filemap.h TRACE_EVENT(file_check_and_advance_wb_err, · line 175
Quoted 5 lines
include/trace/events/filemap.h +1
-1@@ -172,7 +172,7 @@ TRACE_EVENT(file_check_and_advance_wb_err,TP_STRUCT__entry (__field (struct file *,file ) - __field(unsigned long, i_ino) + __field(u64, i_ino)
Having a pointer after the u64 is better.
Quoted 111 lines
include/trace/events/filemap.h +1
-1__field(dev_t, s_dev) __field(errseq_t, old)__field (errseq_t, new)@@ -191,7 +191,7 @@ TRACE_EVENT(file_check_and_advance_wb_err, __entry->new = file->f_wb_err; ), -TP_printk ("file=%p dev=%d:%d ino=0x%lx old=0x%x new=0x%x" , +TP_printk ("file=%p dev=%d:%d ino=0x%llx old=0x%x new=0x%x" , __entry->file,MAJOR (__entry->s_dev),MINOR (__entry->s_dev), __entry->i_ino, __entry->old, __entry->new)include/trace/events/fs_dax.h +10
-10@@ -12,7 +12,7 @@ DECLARE_EVENT_CLASS(dax_pmd_fault_class, pgoff_t max_pgoff, int result),TP_ARGS (inode ,vmf ,max_pgoff ,result ),TP_STRUCT__entry ( - __field(unsigned long, ino) + __field(u64, ino)__field (unsigned long ,vm_start ) __field(unsigned long, vm_end) __field(vm_flags_t, vm_flags)@@ -35,7 +35,7 @@ DECLARE_EVENT_CLASS(dax_pmd_fault_class, __entry->max_pgoff = max_pgoff; __entry->result = result; ), - TP_printk("dev %d:%d ino %#lx %s %s address %#lx vm_start " + TP_printk("dev %d:%d ino %#llx %s %s address %#lx vm_start " "%#lx vm_end %#lx pgoff %#lx max_pgoff %#lx %s", MAJOR(__entry->dev), MINOR(__entry->dev),@@ -66,7 +66,7 @@ DECLARE_EVENT_CLASS(dax_pmd_load_hole_class, void *radix_entry),TP_ARGS (inode ,vmf ,zero_folio ,radix_entry ),TP_STRUCT__entry ( - __field(unsigned long, ino) + __field(u64, ino)__field (vm_flags_t ,vm_flags ) __field(unsigned long, address) __field(struct folio *, zero_folio)@@ -81,7 +81,7 @@ DECLARE_EVENT_CLASS(dax_pmd_load_hole_class, __entry->zero_folio = zero_folio; __entry->radix_entry = radix_entry; ), - TP_printk("dev %d:%d ino %#lx %s address %#lx zero_folio %p " + TP_printk("dev %d:%d ino %#llx %s address %#lx zero_folio %p " "radix_entry %#lx", MAJOR(__entry->dev), MINOR(__entry->dev),@@ -106,7 +106,7 @@ DECLARE_EVENT_CLASS(dax_pte_fault_class, TP_PROTO(struct inode *inode, struct vm_fault *vmf, int result), TP_ARGS(inode, vmf, result), TP_STRUCT__entry( - __field(unsigned long, ino) + __field(u64, ino) __field(vm_flags_t, vm_flags) __field(unsigned long, address) __field(pgoff_t, pgoff)@@ -123,7 +123,7 @@ DECLARE_EVENT_CLASS(dax_pte_fault_class, __entry->pgoff = vmf->pgoff; __entry->result = result; ), - TP_printk("dev %d:%d ino %#lx %s %s address %#lx pgoff %#lx %s", + TP_printk("dev %d:%d ino %#llx %s %s address %#lx pgoff %#lx %s", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino,@@ -150,7 +150,7 @@ DECLARE_EVENT_CLASS(dax_writeback_range_class, TP_PROTO(struct inode *inode, pgoff_t start_index, pgoff_t end_index), TP_ARGS(inode, start_index, end_index), TP_STRUCT__entry( - __field(unsigned long, ino) + __field(u64, ino) __field(pgoff_t, start_index) __field(pgoff_t, end_index) __field(dev_t, dev)@@ -161,7 +161,7 @@ DECLARE_EVENT_CLASS(dax_writeback_range_class, __entry->start_index = start_index; __entry->end_index = end_index; ), - TP_printk("dev %d:%d ino %#lx pgoff %#lx-%#lx", + TP_printk("dev %d:%d ino %#llx pgoff %#lx-%#lx", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino,@@ -182,7 +182,7 @@ TRACE_EVENT(dax_writeback_one, TP_PROTO(struct inode *inode, pgoff_t pgoff, pgoff_t pglen), TP_ARGS(inode, pgoff, pglen), TP_STRUCT__entry( - __field(unsigned long, ino) + __field(u64, ino) __field(pgoff_t, pgoff) __field(pgoff_t, pglen) __field(dev_t, dev)@@ -193,7 +193,7 @@ TRACE_EVENT(dax_writeback_one, __entry->pgoff = pgoff; __entry->pglen = pglen; ), - TP_printk("dev %d:%d ino %#lx pgoff %#lx pglen %#lx", + TP_printk("dev %d:%d ino %#llx pgoff %#lx pglen %#lx", MAJOR(__entry->dev), MINOR(__entry->dev), __entry->ino,include/trace/events/fsverity.h +0
-0
include/trace/events/fsverity.h TRACE_EVENT(fsverity_enable, · line 19
Quoted 5 lines
include/trace/events/fsverity.h +1
-1@@ -16,7 +16,7 @@ TRACE_EVENT(fsverity_enable, const struct merkle_tree_params *params),TP_ARGS (inode ,params ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)
Do you need to convert all these ino_t's?
Quoted 55 lines
include/trace/events/fsverity.h +8
-8__field(u64, data_size) __field(u64, tree_size) __field(unsigned int, merkle_block)@@ -29,8 +29,8 @@ TRACE_EVENT(fsverity_enable, __entry->merkle_block = params->block_size; __entry->num_levels = params->num_levels; ), - TP_printk("ino %lu data_size %llu tree_size %llu merkle_block %u levels %u", - (unsigned long) __entry->ino, + TP_printk("ino %llu data_size %llu tree_size %llu merkle_block %u levels %u", + __entry->ino, __entry->data_size, __entry->tree_size, __entry->merkle_block,@@ -42,7 +42,7 @@ TRACE_EVENT(fsverity_tree_done, const struct merkle_tree_params *params),TP_ARGS (inode ,vi ,params ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (u64 ,data_size )__field (u64, tree_size) __field(unsigned int, merkle_block)@@ -59,8 +59,8 @@ TRACE_EVENT(fsverity_tree_done,memcpy (__get_dynamic_array (root_hash), vi->root_hash,__get_dynamic_array_len (root_hash));memcpy (__get_dynamic_array (file_digest), vi->file_digest,__get_dynamic_array_len (file_digest)); ), - TP_printk("ino %lu data_size %llu tree_size %lld merkle_block %u levels %u root_hash %s digest %s", - (unsigned long) __entry->ino, + TP_printk("ino %llu data_size %llu tree_size %lld merkle_block %u levels %u root_hash %s digest %s", + __entry->ino, __entry->data_size, __entry->tree_size, __entry->merkle_block,@@ -75,7 +75,7 @@ TRACE_EVENT(fsverity_verify_data_block, u64 data_pos),TP_ARGS (inode ,params ,data_pos ),TP_STRUCT__entry ( - __field(ino_t, ino) + __field(u64, ino)__field (u64 ,data_pos ) __field(unsigned int, merkle_block) ),@@ -84,8 +84,8 @@ TRACE_EVENT(fsverity_verify_data_block, __entry->data_pos = data_pos; __entry->merkle_block = params->block_size; ), -TP_printk ("ino %lu data_pos %llu merkle_block %u" , - (unsigned long ) __entry->ino, +TP_printk ("ino %llu data_pos %llu merkle_block %u" , + __entry->ino, __entry->data_pos, __entry->merkle_block) );
include/trace/events/fsverity.h TRACE_EVENT(fsverity_merkle_hit, · line 100
Quoted 6 lines
include/trace/events/fsverity.h +1
-1@@ -96,7 +96,7 @@ TRACE_EVENT(fsverity_merkle_hit, unsigned int hidx), TP_ARGS(inode, data_pos, hblock_idx, level, hidx), TP_STRUCT__entry( - __field(ino_t, ino) + __field(u64, ino) __field(u64, data_pos)
Heh, this actually removed a hole, but again, why convert ino_t?
Anyway, I stopped here. But you get the idea.
-- Steve
Quoted 2 lines
include/trace/events/fsverity.h +0
-0__field(unsigned long, hblock_idx)__field (unsigned int , level)
Jeff Layton
maintainerRe: [PATCH 03/61] trace: update VFS-layer trace events for u64 i_ino
In reply to Jan KaraQuoted 66 lines · Jan Kara
Quoted 13 lines · Jeff Layton
Update trace event definitions in VFS-layer trace headers to use u64 instead of ino_t/unsigned long for inode number fields, and change format strings from %lu/%lx to %llu/%llx to match.
This is needed because
i_inois now u64. Changing trace event field types changes the binary trace format, but the self-describing format metadata handles this transparently for modern trace-cmd and perf.Files updated:
-cachefiles.h,filelock.h,filemap.h,fs_dax.h,fsverity.h,hugetlbfs.h,netfs.h,readahead.h,timestamp.h,writeback.hSigned-off-by Jeff Layton <[email protected]>...
Quoted 14 lines
include/trace/events/writeback.h +1
-1@@ -67,7 +67,7 @@ DECLARE_EVENT_CLASS(writeback_folio_template,TP_STRUCT__entry ( __array(char, name, 32) - __field(ino_t, ino) + __field(u64, ino)__field (pgoff_t, index) ),include/trace/events/writeback.h DECLARE_EVENT_CLASS(writeback_folio_template, · line 84
Quoted 8 lines
include/trace/events/writeback.h +2
-2@@ -79,9 +79,9 @@ DECLARE_EVENT_CLASS(writeback_folio_template, __entry->index = folio->index; ), - TP_printk("bdi %s: ino=%lu index=%lu", + TP_printk("bdi %s: ino=%llu index=%lu", __entry->name, - (unsigned long)__entry->ino, + (unsigned long long)__entry->ino,No need for explicit typing to ULL?
Quoted 13 lines
include/trace/events/writeback.h +1
-1__entry->index ) );@@ -108,7 +108,7 @@ DECLARE_EVENT_CLASS(writeback_dirty_inode_template,TP_STRUCT__entry ( __array(char, name, 32) - __field(ino_t, ino) + __field(u64, ino) __field(unsigned long, state) __field(unsigned long, flags) ),include/trace/events/writeback.h DECLARE_EVENT_CLASS(writeback_dirty_inode_template, · line 128
Quoted 8 lines
include/trace/events/writeback.h +2
-2@@ -123,9 +123,9 @@ DECLARE_EVENT_CLASS(writeback_dirty_inode_template, __entry->flags = flags; ), - TP_printk("bdi %s: ino=%lu state=%s flags=%s", + TP_printk("bdi %s: ino=%llu state=%s flags=%s", __entry->name, - (unsigned long)__entry->ino, + (unsigned long long)__entry->ino,And here as well? And many times below as well...
Quoted 1 line
Honza
Good catch. I'll clean those up.
Thanks,
Signature · 1 line
Jeff Layton <[email protected]>
Jeff Layton
maintainerRe: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
In reply to Jan KaraQuoted 13 lines · Jan Kara
Quoted 12 lines · Jeff Layton
Quoted 10 lines · Mathieu Desnoyers
Quoted 4 lines · Jeff Layton
I'll let others chime in first, but I'm open to going back and doing it that way if we don't want to live with the compiler warnings during a bisect.
On 32-bit archs, I suspect it will do more than emit compiler warnings. Trying to boot a kernel in the middle of the series is likely to lead to interesting inode value printout results.
Quoted 9 lines
Quoted 2 lines
Definitely. None of that would be trustworthy in the middle of the series.
Yeah, I think defining
kino_tin the beginning as unsigned long, convert everything (including special format string specifier) to it, then switch it to u64 and finally just 'sed-out' the format string specifier in the final patch shouldn't be harder than what you do here and should keep bisectability?
Ok. I'll look at doing it in a way that doesn't break bisectability.
Signature · 1 line
Jeff Layton <[email protected]>
Re: [PATCH 02/61] vfs: change i_ino from unsigned long to u64
In reply to Mathieu DesnoyersQuoted 14 lines · On Thu, 26 Feb 2026 11:16:50 -0500 Mathieu Desnoyers…
Quoted 13 lines · Jeff Layton
Change the type of
i_inoin struct inode from unsigned long to u64.On 64-bit architectures, unsigned long is already 64 bits, so this is effectively a type alias change with no runtime impact. On 32-bit architectures, this widens
i_inofrom 32 to 64 bits, allowing filesystems like NFS, CIFS, XFS, Ceph, and FUSE to store their native 64-bit inode numbers without folding/hashing.The VFS already handles 64-bit inode numbers in kstat.ino (u64) and statx.stx_ino (
__u64). The existing overflow checks incp_new_stat(),cp_old_stat(), andcp_compat_stat()handle narrowing to 32-bitst_inowith-EOVERFLOW, so userspace ABI is preserved.
Quoted 4 lines
Quoted 1 line
struct inode will grow by 4 bytes on 32-bit architectures.
Changing this type first without changing its associated format strings breaks git bisect.
Or find all the format strings, change to %llu and add (u64) casts. That should compile and run in both 32bit and 64bit.
At the end you could delete the casts.
David
Quoted 9 lines
One alternative would be to introduce something like the PRIu64 macro but for printing inode values. This would allow gradually introducing the change without breaking the world as you do so.
Thanks,
Mathieu
Re: [PATCH 28/61] ecryptfs: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · Jeff Layton
Update format strings and local variable types in ecryptfs for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>
Tyler
Quoted 53 lines
--- fs/ecryptfs/crypto.c | 6 +++--- fs/ecryptfs/file.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)fs/ecryptfs/crypto.c +3
-3@@ -1313,7 +1313,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry) rc =ecryptfs_read_xattr_region (page_virt, ecryptfs_inode);if (rc) {printk (KERN_DEBUG "Valid eCryptfs headers not found in " -"file header region or xattr region, inode %lu\n" , +"file header region or xattr region, inode %llu\n" , ecryptfs_inode->i_ino); rc = -EINVAL ; goto out;@@ -1323,7 +1323,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry) ECRYPTFS_DONT_VALIDATE_HEADER_SIZE);if (rc) {printk (KERN_DEBUG "Valid eCryptfs headers not found in " -"file xattr region either, inode %lu\n" , +"file xattr region either, inode %llu\n" , ecryptfs_inode->i_ino); rc = -EINVAL ; }@@ -1335,7 +1335,7 @@ int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry)"crypto metadata only in the extended attribute " "region, but eCryptfs was mounted without " "xattr support enabled. eCryptfs will not treat " -"this like an encrypted file, inode %lu\n" , +"this like an encrypted file, inode %llu\n" , ecryptfs_inode->i_ino); rc = -EINVAL ; }fs/ecryptfs/file.c +1
-1@@ -253,7 +253,7 @@ static int ecryptfs_open(struct inode *inode, struct file *file)if (rc) goto out_put;ecryptfs_printk (KERN_DEBUG ,"inode w/ addr = [0x%p], i_ino = " -"[0x%.16lx] size: [0x%.16llx]\n" , inode, inode->i_ino, +"[0x%.16llx] size: [0x%.16llx]\n" , inode, inode->i_ino, (unsigned long long )i_size_read (inode)); goto out; out_put:Signature · 2 lines
-- 2.53.0
Re: [PATCH 33/61] hfs: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 59 lines · Jeff Layton
Update format strings and local variable types in hfs for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>--- fs/hfs/catalog.c | 2 +- fs/hfs/extent.c | 4 ++-- fs/hfs/inode.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-)fs/hfs/catalog.c +1
-1@@ -417,7 +417,7 @@ int hfs_cat_move(u32 cnid, struct inode *src_dir, const struct qstr *src_name,int entry_size, type;int err; -hfs_dbg ("cnid %u - (ino %lu, name %s) - (ino %lu, name %s)\n" , +hfs_dbg ("cnid %u - (ino %llu, name %s) - (ino %llu, name %s)\n" , cnid, src_dir->i_ino, src_name->name, dst_dir->i_ino, dst_name->name); sb = src_dir->i_sb;fs/hfs/extent.c +2
-2@@ -411,7 +411,7 @@ int hfs_extend_file(struct inode *inode) goto out; } -hfs_dbg ("ino %lu, start %u, len %u\n" , inode->i_ino, start, len); +hfs_dbg ("ino %llu, start %u, len %u\n" , inode->i_ino, start, len);if (HFS_I (inode)->alloc_blocks ==HFS_I (inode)->first_blocks) {if (!HFS_I (inode)->first_blocks) { hfs_dbg("first_extent: start %u, len %u\n",@@ -482,7 +482,7 @@ void hfs_file_truncate(struct inode *inode)u32 size;int res; -hfs_dbg ("ino %lu, phys_size %llu -> i_size %llu\n" , +hfs_dbg ("ino %llu, phys_size %llu -> i_size %llu\n" , inode->i_ino, (long long )HFS_I (inode)->phys_size, inode->i_size);if (inode->i_size >HFS_I (inode)->phys_size) {fs/hfs/inode.c +1
-1@@ -270,7 +270,7 @@ void hfs_delete_inode(struct inode *inode) {struct super_block *sb = inode->i_sb; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino);if (S_ISDIR (inode->i_mode)) {atomic64_dec (&HFS_SB (sb)->folder_count);if (HFS_I (inode)->cat_key.ParID ==cpu_to_be32 (HFS_ROOT_CNID ))
fs/hfs/inode.c int hfs_write_inode(struct inode *inode, struct writeback_control *wbc) · line 461
Quoted 8 lines
fs/hfs/inode.c +1
-1@@ -455,7 +455,7 @@ int hfs_write_inode(struct inode *inode, struct writeback_control *wbc)hfs_cat_rec rec;int res; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino); res =hfs_ext_write_extent (inode);if (res)return res;
Looks good.
Thanks,
Slava.
Re: [PATCH 34/61] hfsplus: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 250 lines · Jeff Layton
Update format strings and local variable types in hfsplus for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>--- fs/hfsplus/attributes.c | 10 +++++----- fs/hfsplus/catalog.c | 2 +- fs/hfsplus/dir.c | 6 +++--- fs/hfsplus/extents.c | 6 +++--- fs/hfsplus/inode.c | 8 ++++---- fs/hfsplus/super.c | 6 +++--- fs/hfsplus/xattr.c | 10 +++++----- 7 files changed, 24 insertions(+), 24 deletions(-)fs/hfsplus/attributes.c +5
-5@@ -203,7 +203,7 @@ int hfsplus_create_attr_nolock(struct inode *inode, const char *name,int entry_size;int err; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (name) {@@ -255,7 +255,7 @@ int hfsplus_create_attr(struct inode *inode,hfsplus_attr_entry *entry_ptr;int err; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (!HFSPLUS_SB (sb)->attr_tree) {@@ -337,7 +337,7 @@ int hfsplus_delete_attr_nolock(struct inode *inode, const char *name,struct super_block *sb = inode->i_sb;int err; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (name) {@@ -367,7 +367,7 @@ int hfsplus_delete_attr(struct inode *inode, const char *name)struct super_block *sb = inode->i_sb;struct hfs_find_data fd; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (!HFSPLUS_SB (sb)->attr_tree) {@@ -436,7 +436,7 @@ int hfsplus_replace_attr(struct inode *inode,hfsplus_attr_entry *entry_ptr;int err =0 ; -hfs_dbg ("name %s, ino %ld\n" , +hfs_dbg ("name %s, ino %lld\n" , name ? name :NULL , inode->i_ino);if (!HFSPLUS_SB (sb)->attr_tree) {fs/hfsplus/catalog.c +1
-1@@ -441,7 +441,7 @@ int hfsplus_rename_cat(u32 cnid,int entry_size, type;int err; -hfs_dbg ("cnid %u - ino %lu, name %s - ino %lu, name %s\n" , +hfs_dbg ("cnid %u - ino %llu, name %s - ino %llu, name %s\n" , cnid, src_dir->i_ino, src_name->name, dst_dir->i_ino, dst_name->name); err =hfs_find_init (HFSPLUS_SB (sb)->cat_tree, &src_fd);fs/hfsplus/dir.c +3
-3@@ -313,7 +313,7 @@ static int hfsplus_link(struct dentry *src_dentry, struct inode *dst_dir,if (!S_ISREG (inode->i_mode))return -EPERM ; -hfs_dbg ("src_dir->i_ino %lu, dst_dir->i_ino %lu, inode->i_ino %lu\n" , +hfs_dbg ("src_dir->i_ino %llu, dst_dir->i_ino %llu, inode->i_ino %llu\n" , src_dir->i_ino, dst_dir->i_ino, inode->i_ino);mutex_lock (&sbi->vh_mutex);@@ -385,7 +385,7 @@ static int hfsplus_unlink(struct inode *dir, struct dentry *dentry)if (HFSPLUS_IS_RSRC (inode))return -EPERM ; -hfs_dbg ("dir->i_ino %lu, inode->i_ino %lu\n" , +hfs_dbg ("dir->i_ino %llu, inode->i_ino %llu\n" , dir->i_ino, inode->i_ino);mutex_lock (&sbi->vh_mutex);@@ -393,7 +393,7 @@ static int hfsplus_unlink(struct inode *dir, struct dentry *dentry)if (inode->i_ino == cnid &&atomic_read (&HFSPLUS_I (inode)->opencnt)) { str.name = name; - str.len =sprintf (name,"temp%lu" , inode->i_ino); + str.len =sprintf (name,"temp%llu" , inode->i_ino); res =hfsplus_rename_cat (inode->i_ino, dir, &dentry->d_name, sbi->hidden_dir, &str);fs/hfsplus/extents.c +3
-3@@ -275,7 +275,7 @@ int hfsplus_get_block(struct inode *inode, sector_t iblock,mutex_unlock (&hip->extents_lock); done: -hfs_dbg ("ino %lu, iblock %llu - dblock %u\n" , +hfs_dbg ("ino %llu, iblock %llu - dblock %u\n" , inode->i_ino, (long long )iblock, dblock); mask = (1 << sbi->fs_shift) -1 ;@@ -476,7 +476,7 @@ int hfsplus_file_extend(struct inode *inode, bool zeroout) goto out; } -hfs_dbg ("ino %lu, start %u, len %u\n" , inode->i_ino, start, len); +hfs_dbg ("ino %llu, start %u, len %u\n" , inode->i_ino, start, len);if (hip->alloc_blocks <= hip->first_blocks) {if (!hip->first_blocks) {@@ -545,7 +545,7 @@ void hfsplus_file_truncate(struct inode *inode)u32 alloc_cnt, blk_cnt, start;int res; -hfs_dbg ("ino %lu, phys_size %llu -> i_size %llu\n" , +hfs_dbg ("ino %llu, phys_size %llu -> i_size %llu\n" , inode->i_ino, (long long )hip->phys_size, inode->i_size);if (inode->i_size > hip->phys_size) {fs/hfsplus/inode.c +4
-4@@ -230,7 +230,7 @@ static int hfsplus_get_perms(struct inode *inode, inode->i_flags &= ~S_APPEND ;return 0 ; bad_type: -pr_err ("invalid file type 0%04o for inode %lu\n" , mode, inode->i_ino); +pr_err ("invalid file type 0%04o for inode %llu\n" , mode, inode->i_ino);return -EIO ; }@@ -328,7 +328,7 @@ int hfsplus_file_fsync(struct file *file, loff_t start, loff_t end,struct hfsplus_vh *vhdr = sbi->s_vhdr;int error =0 , error2; -hfs_dbg ("inode->i_ino %lu, start %llu, end %llu\n" , +hfs_dbg ("inode->i_ino %llu, start %llu, end %llu\n" , inode->i_ino, start, end); error =file_write_and_wait_range (file, start, end);@@ -639,7 +639,7 @@ int hfsplus_cat_write_inode(struct inode *inode)hfsplus_cat_entry entry;int res =0 ; -hfs_dbg ("inode->i_ino %lu\n" , inode->i_ino); +hfs_dbg ("inode->i_ino %llu\n" , inode->i_ino);if (HFSPLUS_IS_RSRC (inode)) main_inode =HFSPLUS_I (inode)->rsrc_inode;@@ -716,7 +716,7 @@ int hfsplus_cat_write_inode(struct inode *inode)if (!res) { res =hfs_btree_write (tree);if (res) { -pr_err ("b-tree write err: %d, ino %lu\n" , +pr_err ("b-tree write err: %d, ino %llu\n" , res, inode->i_ino); } }fs/hfsplus/super.c +3
-3@@ -156,7 +156,7 @@ static int hfsplus_system_write_inode(struct inode *inode)int err =hfs_btree_write (tree);if (err) { -pr_err ("b-tree write err: %d, ino %lu\n" , +pr_err ("b-tree write err: %d, ino %llu\n" , err, inode->i_ino);return err; }@@ -169,7 +169,7 @@ static int hfsplus_write_inode(struct inode *inode, {int err; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino); err =hfsplus_ext_write_extent (inode);if (err)@@ -184,7 +184,7 @@ static int hfsplus_write_inode(struct inode *inode,static void hfsplus_evict_inode (struct inode *inode) { -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino);truncate_inode_pages_final (&inode->i_data);clear_inode (inode);if (HFSPLUS_IS_RSRC (inode)) {fs/hfsplus/xattr.c +4
-4@@ -277,7 +277,7 @@ int __hfsplus_setxattr(struct inode *inode, const char *name,u16 folder_finderinfo_len =sizeof (DInfo) +sizeof (DXInfo);u16 file_finderinfo_len =sizeof (FInfo) +sizeof (FXInfo); -hfs_dbg ("ino %lu, name %s, value %p, size %zu\n" , +hfs_dbg ("ino %llu, name %s, value %p, size %zu\n" , inode->i_ino, name ? name :NULL , value, size);@@ -447,7 +447,7 @@ int hfsplus_setxattr(struct inode *inode, const char *name,NLS_MAX_CHARSET_SIZE *HFSPLUS_ATTR_MAX_STRLEN +1 ;int res; - hfs_dbg("ino %lu, name %s, prefix %s, prefixlen %zu, " + hfs_dbg("ino %llu, name %s, prefix %s, prefixlen %zu, " "value %p, size %zu\n", inode->i_ino, name ? name : NULL, prefix ? prefix : NULL, prefixlen,@@ -607,7 +607,7 @@ ssize_t hfsplus_getxattr(struct inode *inode, const char *name,int res;char *xattr_name; -hfs_dbg ("ino %lu, name %s, prefix %s\n" , +hfs_dbg ("ino %llu, name %s, prefix %s\n" , inode->i_ino, name ? name :NULL , prefix ? prefix :NULL );@@ -717,7 +717,7 @@ ssize_t hfsplus_listxattr(struct dentry *dentry, char *buffer, size_t size)size_t strbuf_size;int xattr_name_len; -hfs_dbg ("ino %lu\n" , inode->i_ino); +hfs_dbg ("ino %llu\n" , inode->i_ino);if (!is_xattr_operation_supported (inode))return -EOPNOTSUPP ;
fs/hfsplus/xattr.c static int hfsplus_removexattr(struct inode *inode, const char *name) · line 825
Quoted 8 lines
fs/hfsplus/xattr.c +1
-1@@ -819,7 +819,7 @@ static int hfsplus_removexattr(struct inode *inode, const char *name)int is_xattr_acl_deleted;int is_all_xattrs_deleted; -hfs_dbg ("ino %lu, name %s\n" , +hfs_dbg ("ino %llu, name %s\n" , inode->i_ino, name ? name :NULL );if (!HFSPLUS_SB (inode->i_sb)->attr_tree)
Looks good.
Thanks,
Slava.
Re: [PATCH 25/61] ceph: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 22 lines · Jeff Layton
Update format strings and local variable types in ceph for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>--- fs/ceph/crypto.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)fs/ceph/crypto.c +1
-1@@ -272,7 +272,7 @@ int ceph_encode_encrypted_dname(struct inode *parent, char *buf, int elen)/* To understand the 240 limit, see CEPH_NOHASH_NAME_MAX comments */ WARN_ON (elen >240 );if (dir != parent)// leading _ is already there; append _<inum> - elen +=1 +sprintf (p + elen,"_%ld" , dir->i_ino); + elen +=1 +sprintf (p + elen,"_%lld" , dir->i_ino); out:kfree (cryptbuf);
fs/ceph/crypto.c int ceph_fname_to_usr(const struct ceph_fname *fname, struct fscrypt_str *tname, · line 383
Quoted 8 lines
fs/ceph/crypto.c +1
-1@@ -377,7 +377,7 @@ int ceph_fname_to_usr(const struct ceph_fname *fname, struct fscrypt_str *tname,if (!ret && (dir != fname->dir)) {char tmp_buf[BASE64_CHARS (NAME_MAX )]; - name_len =snprintf (tmp_buf,sizeof (tmp_buf),"_%.*s_%ld" , + name_len =snprintf (tmp_buf,sizeof (tmp_buf),"_%.*s_%lld" , oname->len, oname->name, dir->i_ino);memcpy (oname->name, tmp_buf, name_len); oname->len = name_len;
Looks good.
Thanks,
Slava.
Re: [PATCH 17/61] nilfs2: update for u64 i_ino
In reply to Jeff LaytonQuoted 169 lines · Jeff Layton
Update nilfs2 trace events and filesystem code for u64
i_ino:- Change
__field(ino_t, ...)to__field(u64, ...)in trace events
- Update format strings from %lu to %llu
- Cast to (unsigned long long) inTP_printkSigned-off-by Jeff Layton <[email protected]>--- fs/nilfs2/alloc.c | 10 +++++----- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/btnode.c | 2 +- fs/nilfs2/btree.c | 12 ++++++------ fs/nilfs2/dir.c | 12 ++++++------ fs/nilfs2/direct.c | 4 ++-- fs/nilfs2/gcinode.c | 2 +- fs/nilfs2/inode.c | 8 ++++---- fs/nilfs2/mdt.c | 2 +- fs/nilfs2/namei.c | 2 +- fs/nilfs2/segment.c | 2 +- include/trace/events/nilfs2.h | 12 ++++++------ 12 files changed, 35 insertions(+), 35 deletions(-)fs/nilfs2/alloc.c +5
-5@@ -707,7 +707,7 @@ void nilfs_palloc_commit_free_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else @@ -748,7 +748,7 @@ void nilfs_palloc_abort_alloc_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else @@ -861,7 +861,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems)if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap)) {nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )entry_nrs[j]); }else {@@ -906,7 +906,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) last_nrs[k]);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting block that object (entry=%llu, ino=%lu) belongs to" , +"error %d deleting block that object (entry=%llu, ino=%llu) belongs to" , ret, (unsigned long long )last_nrs[k], inode->i_ino); }@@ -923,7 +923,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) ret =nilfs_palloc_delete_bitmap_block (inode, group);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting bitmap block of group=%lu, ino=%lu" , +"error %d deleting bitmap block of group=%lu, ino=%llu" , ret, group, inode->i_ino); } }fs/nilfs2/bmap.c +1
-1@@ -33,7 +33,7 @@ static int nilfs_bmap_convert_error(struct nilfs_bmap *bmap,if (err == -EINVAL ) {__nilfs_error (inode->i_sb, fname, -"broken bmap (inode number=%lu)" , inode->i_ino); +"broken bmap (inode number=%llu)" , inode->i_ino); err = -EIO ; }return err;fs/nilfs2/btnode.c +1
-1@@ -64,7 +64,7 @@ nilfs_btnode_create_block(struct address_space *btnc, __u64 blocknr)* clearing of an abandoned b-tree node is missing somewhere). */ nilfs_error (inode->i_sb, -"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%lu)" , +"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%llu)" , (unsigned long long )blocknr, inode->i_ino); goto failed; }fs/nilfs2/btree.c +6
-6@@ -353,7 +353,7 @@ static int nilfs_btree_node_broken(const struct nilfs_btree_node *node, nchildren <= 0 || nchildren > NILFS_BTREE_NODE_NCHILDREN_MAX(size))) {nilfs_crit (inode->i_sb, -"bad btree node (ino=%lu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree node (ino=%llu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, (unsigned long long )blocknr, level, flags, nchildren); ret =1 ;@@ -384,7 +384,7 @@ static int nilfs_btree_root_broken(const struct nilfs_btree_node *node, nchildren > NILFS_BTREE_ROOT_NCHILDREN_MAX || (nchildren == 0 && level > NILFS_BTREE_LEVEL_NODE_MIN))) {nilfs_crit (inode->i_sb, -"bad btree root (ino=%lu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree root (ino=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, level, flags, nchildren); ret =1 ; }@@ -453,7 +453,7 @@ static int nilfs_btree_bad_node(const struct nilfs_bmap *btree,if (unlikely (nilfs_btree_node_get_level (node) != level)) {dump_stack ();nilfs_crit (btree->b_inode->i_sb, -"btree level mismatch (ino=%lu): %d != %d" , +"btree level mismatch (ino=%llu): %d != %d" , btree->b_inode->i_ino,nilfs_btree_node_get_level (node), level);return 1 ;@@ -521,7 +521,7 @@ static int __nilfs_btree_get_block(const struct nilfs_bmap *btree, __u64 ptr, out_no_wait:if (!buffer_uptodate (bh)) {nilfs_err (btree->b_inode->i_sb, -"I/O error reading b-tree node block (ino=%lu, blocknr=%llu)" , +"I/O error reading b-tree node block (ino=%llu, blocknr=%llu)" , btree->b_inode->i_ino, (unsigned long long )ptr);brelse (bh);return -EIO ;@@ -2104,7 +2104,7 @@ static int nilfs_btree_propagate(struct nilfs_bmap *btree,if (ret <0 ) {if (unlikely (ret == -ENOENT )) {nilfs_crit (btree->b_inode->i_sb, -"writing node/leaf block does not appear in b-tree (ino=%lu) at key=%llu, level=%d" , +"writing node/leaf block does not appear in b-tree (ino=%llu) at key=%llu, level=%d" , btree->b_inode->i_ino, (unsigned long long )key, level); ret = -EINVAL ;@@ -2146,7 +2146,7 @@ static void nilfs_btree_add_dirty_buffer(struct nilfs_bmap *btree, level >= NILFS_BTREE_LEVEL_MAX) {dump_stack ();nilfs_warn (btree->b_inode->i_sb, -"invalid btree level: %d (key=%llu, ino=%lu, blocknr=%llu)" , +"invalid btree level: %d (key=%llu, ino=%llu, blocknr=%llu)" , level, (unsigned long long )key, btree->b_inode->i_ino, (unsigned long long )bh->b_blocknr);fs/nilfs2/dir.c +1
-1@@ -150,7 +150,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) Ebadsize:nilfs_error (sb, -"size of directory #%lu is not a multiple of chunk size" , +"size of directory #%llu is not a multiple of chunk size" , dir->i_ino); goto fail; Eshort:
fs/nilfs2/dir.c static bool nilfs_check_folio(struct folio *folio, char *kaddr) · line 172
Quoted 5 lines
fs/nilfs2/dir.c +1
-1@@ -169,7 +169,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) error ="disallowed inode number" ; bad_entry: nilfs_error(sb, - "bad entry in directory #%lu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d", + "bad entry in directory #%llu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d",
I think you missed 'inode=%lu' here.
fs/nilfs2/dir.c static bool nilfs_check_folio(struct folio *folio, char *kaddr) · line 180
Quoted 9 lines
fs/nilfs2/dir.c +1
-1dir->i_ino, error, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long )le64_to_cpu (p->inode), rec_len, p->name_len);@@ -177,7 +177,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) Eend: p = (struct nilfs_dir_entry *)(kaddr + offs); nilfs_error(sb, - "entry in directory #%lu spans the page boundary offset=%lu, inode=%lu", + "entry in directory #%llu spans the page boundary offset=%lu, inode=%lu",
Ditto. You missed 'inode=%lu' here.
Thanks,
Slava.
Quoted 201 lines
fs/nilfs2/dir.c +3
-3dir->i_ino, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long)le64_to_cpu(p->inode)); fail:@@ -251,7 +251,7 @@ static int nilfs_readdir(struct file *file, struct dir_context *ctx) kaddr =nilfs_get_folio (inode, n, &folio);if (IS_ERR (kaddr)) { -nilfs_error (sb,"bad page in #%lu" , inode->i_ino); +nilfs_error (sb,"bad page in #%llu" , inode->i_ino); ctx->pos +=PAGE_SIZE - offset;return -EIO ; }@@ -336,7 +336,7 @@ struct nilfs_dir_entry *nilfs_find_entry(struct inode *dir,/* next folio is past the blocks we've got */ if (unlikely (n > (dir->i_blocks >> (PAGE_SHIFT -9 )))) {nilfs_error (dir->i_sb, -"dir %lu size %lld exceeds block count %llu" , +"dir %llu size %lld exceeds block count %llu" , dir->i_ino, dir->i_size, (unsigned long long )dir->i_blocks); goto out;@@ -382,7 +382,7 @@ struct nilfs_dir_entry *nilfs_dotdot(struct inode *dir, struct folio **foliop)return next_de; fail: -nilfs_error (dir->i_sb,"directory #%lu %s" , dir->i_ino, msg); +nilfs_error (dir->i_sb,"directory #%llu %s" , dir->i_ino, msg);folio_release_kmap (folio, de);return NULL ; }fs/nilfs2/direct.c +2
-2@@ -338,7 +338,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, key =nilfs_bmap_data_get_key (bmap, *bh);if (unlikely (key >NILFS_DIRECT_KEY_MAX )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid key: %llu" , +"%s (ino=%llu): invalid key: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )key);return -EINVAL ;@@ -346,7 +346,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, ptr =nilfs_direct_get_ptr (bmap, key);if (unlikely (ptr ==NILFS_BMAP_INVALID_PTR )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid pointer: %llu" , +"%s (ino=%llu): invalid pointer: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )ptr);return -EINVAL ;fs/nilfs2/gcinode.c +1
-1@@ -137,7 +137,7 @@ int nilfs_gccache_wait_and_mark_dirty(struct buffer_head *bh)struct inode *inode = bh->b_folio->mapping->host;nilfs_err (inode->i_sb, -"I/O error reading %s block for GC (ino=%lu, vblocknr=%llu)" , +"I/O error reading %s block for GC (ino=%llu, vblocknr=%llu)" ,buffer_nilfs_node (bh) ?"node" :"data" , inode->i_ino, (unsigned long long )bh->b_blocknr);return -EIO ;fs/nilfs2/inode.c +4
-4@@ -108,7 +108,7 @@ int nilfs_get_block(struct inode *inode, sector_t blkoff,* be locked in this case. */ nilfs_warn (inode->i_sb, -"%s (ino=%lu): a race condition while inserting a data block at offset=%llu" , +"%s (ino=%llu): a race condition while inserting a data block at offset=%llu" , __func__, inode->i_ino, (unsigned long long )blkoff); err = -EAGAIN ;@@ -789,7 +789,7 @@ static void nilfs_truncate_bmap(struct nilfs_inode_info *ii, goto repeat; failed: -nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%lu)" , +nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%llu)" , ret, ii->vfs_inode.i_ino); }@@ -1026,7 +1026,7 @@ int nilfs_set_file_dirty(struct inode *inode, unsigned int nr_dirty)* this inode. */ nilfs_warn (inode->i_sb, -"cannot set file dirty (ino=%lu): the file is being freed" , +"cannot set file dirty (ino=%llu): the file is being freed" , inode->i_ino);spin_unlock (&nilfs->ns_inode_lock);return -EINVAL ;/* @@ -1057,7 +1057,7 @@ int __nilfs_mark_inode_dirty(struct inode *inode, int flags) err =nilfs_load_inode_block (inode, &ibh);if (unlikely (err)) {nilfs_warn (inode->i_sb, -"cannot mark inode dirty (ino=%lu): error %d loading inode block" , +"cannot mark inode dirty (ino=%llu): error %d loading inode block" , inode->i_ino, err);return err; }fs/nilfs2/mdt.c +1
-1@@ -203,7 +203,7 @@ static int nilfs_mdt_read_block(struct inode *inode, unsigned long block, err = -EIO ;if (!buffer_uptodate (first_bh)) {nilfs_err (inode->i_sb, -"I/O error reading meta-data file (ino=%lu, block-offset=%lu)" , +"I/O error reading meta-data file (ino=%llu, block-offset=%lu)" , inode->i_ino, block); goto failed_bh; }fs/nilfs2/namei.c +1
-1@@ -292,7 +292,7 @@ static int nilfs_do_unlink(struct inode *dir, struct dentry *dentry)if (!inode->i_nlink) {nilfs_warn (inode->i_sb, -"deleting nonexistent file (ino=%lu), %d" , +"deleting nonexistent file (ino=%llu), %d" , inode->i_ino, inode->i_nlink);set_nlink (inode,1 ); }fs/nilfs2/segment.c +1
-1@@ -2024,7 +2024,7 @@ static int nilfs_segctor_collect_dirty_files(struct nilfs_sc_info *sci, ifile, ii->vfs_inode.i_ino, &ibh);if (unlikely (err)) {nilfs_warn (sci->sc_super, -"log writer: error %d getting inode block (ino=%lu)" , +"log writer: error %d getting inode block (ino=%llu)" , err, ii->vfs_inode.i_ino);return err; }include/trace/events/nilfs2.h +6
-6@@ -165,14 +165,14 @@ TRACE_EVENT(nilfs2_segment_usage_freed, TRACE_EVENT(nilfs2_mdt_insert_new_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long block), TP_ARGS(inode, ino, block), TP_STRUCT__entry( __field(struct inode *, inode) - __field(unsigned long, ino) + __field(u64, ino) __field(unsigned long, block) ),@@ -182,7 +182,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, __entry->block = block; ), -TP_printk ("inode = %p ino = %lu block = %lu" , +TP_printk ("inode = %p ino = %llu block = %lu" , __entry->inode, __entry->ino, __entry->block)@@ -190,7 +190,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, TRACE_EVENT(nilfs2_mdt_submit_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long blkoff, enum req_op mode),@@ -198,7 +198,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block,TP_STRUCT__entry (__field (struct inode *,inode ) - __field(unsigned long, ino) +__field (u64, ino) __field(unsigned long, blkoff)/* * Use field_struct() to avoid is_signed_type() on the @@ -214,7 +214,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block, __entry->mode = mode; ), - TP_printk("inode = %p ino = %lu blkoff = %lu mode = %x", + TP_printk("inode = %p ino = %llu blkoff = %lu mode = %x", __entry->inode, __entry->ino, __entry->blkoff,
Re: [PATCH 12/61] nfsd: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 68 lines · Jeff Layton
Update format strings from %ld/%lu to %lld/%llu for
i_ino, which is now a u64.Signed-off-by Jeff Layton <[email protected]>--- fs/nfsd/export.c | 2 +- fs/nfsd/nfs4state.c | 4 ++-- fs/nfsd/nfsfh.c | 4 ++-- fs/nfsd/vfs.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-)fs/nfsd/export.c +1
-1@@ -1039,7 +1039,7 @@ exp_rootfh(struct net *net, struct auth_domain *clp, char *name, } inode =d_inode (path.dentry); -dprintk ("nfsd: exp_rootfh(%s [%p] %s:%s/%ld)\n" , +dprintk ("nfsd: exp_rootfh(%s [%p] %s:%s/%lld)\n" , name, path.dentry, clp->name, inode->i_sb->s_id, inode->i_ino); exp =exp_parent (cd, clp, &path);fs/nfsd/nfs4state.c +2
-2@@ -1253,7 +1253,7 @@ static void nfsd4_finalize_deleg_timestamps(struct nfs4_delegation *dp, struct fif (ret) {struct inode *inode =file_inode (f); -pr_notice_ratelimited ("nfsd: Unable to update timestamps on inode %02x:%02x:%lu: %d\n" , +pr_notice_ratelimited ("nfsd: Unable to update timestamps on inode %02x:%02x:%llu: %d\n" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino, ret);@@ -2888,7 +2888,7 @@ static void nfs4_show_superblock(struct seq_file *s, struct nfsd_file *f) {struct inode *inode =file_inode (f->nf_file); -seq_printf (s,"superblock: \"%02x:%02x:%ld\"" , +seq_printf (s,"superblock: \"%02x:%02x:%llu\"" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino);fs/nfsd/nfsfh.c +2
-2@@ -601,9 +601,9 @@ fh_compose(struct svc_fh *fhp, struct svc_export *exp, struct dentry *dentry,struct inode * inode =d_inode (dentry);dev_t ex_dev =exp_sb (exp)->s_dev; -dprintk ("nfsd: fh_compose(exp %02x:%02x/%ld %pd2, ino=%ld)\n" , +dprintk ("nfsd: fh_compose(exp %02x:%02x/%lld %pd2, ino=%lld)\n" ,MAJOR (ex_dev),MINOR (ex_dev), - (long )d_inode (exp->ex_path.dentry)->i_ino, + (long long )d_inode (exp->ex_path.dentry)->i_ino, dentry, (inode ? inode->i_ino :0 ));fs/nfsd/vfs.c +0
-0
fs/nfsd/vfs.c nfsd_direct_read(struct svc_rqst *rqstp, struct svc_fh *fhp, · line 1169
Quoted 8 lines
fs/nfsd/vfs.c +1
-1@@ -1163,7 +1163,7 @@ nfsd_direct_read(struct svc_rqst *rqstp, struct svc_fh *fhp, }else if (unlikely (host_err == -EINVAL )) {struct inode *inode =d_inode (fhp->fh_dentry); -pr_info_ratelimited ("nfsd: Direct I/O alignment failure on %s/%ld\n" , +pr_info_ratelimited ("nfsd: Direct I/O alignment failure on %s/%lld\n" , inode->i_sb->s_id, inode->i_ino); host_err = -ESERVERFAULT ; }
Suggestion: Let's use the %llu format specifier consistently for inode->i_ino, which is unsigned.
Signature · 1 line
Chuck Lever
Jeff Layton
maintainerRe: [PATCH 17/61] nilfs2: update for u64 i_ino
In reply to Viacheslav DubeykoQuoted 162 lines · Viacheslav Dubeyko
Quoted 161 lines · Jeff Layton
Update nilfs2 trace events and filesystem code for u64
i_ino:- Change
__field(ino_t, ...)to__field(u64, ...)in trace events
- Update format strings from %lu to %llu
- Cast to (unsigned long long) inTP_printkSigned-off-by Jeff Layton <[email protected]>--- fs/nilfs2/alloc.c | 10 +++++----- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/btnode.c | 2 +- fs/nilfs2/btree.c | 12 ++++++------ fs/nilfs2/dir.c | 12 ++++++------ fs/nilfs2/direct.c | 4 ++-- fs/nilfs2/gcinode.c | 2 +- fs/nilfs2/inode.c | 8 ++++---- fs/nilfs2/mdt.c | 2 +- fs/nilfs2/namei.c | 2 +- fs/nilfs2/segment.c | 2 +- include/trace/events/nilfs2.h | 12 ++++++------ 12 files changed, 35 insertions(+), 35 deletions(-)fs/nilfs2/alloc.c +5
-5@@ -707,7 +707,7 @@ void nilfs_palloc_commit_free_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else @@ -748,7 +748,7 @@ void nilfs_palloc_abort_alloc_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else @@ -861,7 +861,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems)if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap)) {nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )entry_nrs[j]); }else {@@ -906,7 +906,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) last_nrs[k]);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting block that object (entry=%llu, ino=%lu) belongs to" , +"error %d deleting block that object (entry=%llu, ino=%llu) belongs to" , ret, (unsigned long long )last_nrs[k], inode->i_ino); }@@ -923,7 +923,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) ret =nilfs_palloc_delete_bitmap_block (inode, group);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting bitmap block of group=%lu, ino=%lu" , +"error %d deleting bitmap block of group=%lu, ino=%llu" , ret, group, inode->i_ino); } }fs/nilfs2/bmap.c +1
-1@@ -33,7 +33,7 @@ static int nilfs_bmap_convert_error(struct nilfs_bmap *bmap,if (err == -EINVAL ) {__nilfs_error (inode->i_sb, fname, -"broken bmap (inode number=%lu)" , inode->i_ino); +"broken bmap (inode number=%llu)" , inode->i_ino); err = -EIO ; }return err;fs/nilfs2/btnode.c +1
-1@@ -64,7 +64,7 @@ nilfs_btnode_create_block(struct address_space *btnc, __u64 blocknr)* clearing of an abandoned b-tree node is missing somewhere). */ nilfs_error (inode->i_sb, -"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%lu)" , +"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%llu)" , (unsigned long long )blocknr, inode->i_ino); goto failed; }fs/nilfs2/btree.c +6
-6@@ -353,7 +353,7 @@ static int nilfs_btree_node_broken(const struct nilfs_btree_node *node, nchildren <= 0 || nchildren > NILFS_BTREE_NODE_NCHILDREN_MAX(size))) {nilfs_crit (inode->i_sb, -"bad btree node (ino=%lu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree node (ino=%llu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, (unsigned long long )blocknr, level, flags, nchildren); ret =1 ;@@ -384,7 +384,7 @@ static int nilfs_btree_root_broken(const struct nilfs_btree_node *node, nchildren > NILFS_BTREE_ROOT_NCHILDREN_MAX || (nchildren == 0 && level > NILFS_BTREE_LEVEL_NODE_MIN))) {nilfs_crit (inode->i_sb, -"bad btree root (ino=%lu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree root (ino=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, level, flags, nchildren); ret =1 ; }@@ -453,7 +453,7 @@ static int nilfs_btree_bad_node(const struct nilfs_bmap *btree,if (unlikely (nilfs_btree_node_get_level (node) != level)) {dump_stack ();nilfs_crit (btree->b_inode->i_sb, -"btree level mismatch (ino=%lu): %d != %d" , +"btree level mismatch (ino=%llu): %d != %d" , btree->b_inode->i_ino,nilfs_btree_node_get_level (node), level);return 1 ;@@ -521,7 +521,7 @@ static int __nilfs_btree_get_block(const struct nilfs_bmap *btree, __u64 ptr, out_no_wait:if (!buffer_uptodate (bh)) {nilfs_err (btree->b_inode->i_sb, -"I/O error reading b-tree node block (ino=%lu, blocknr=%llu)" , +"I/O error reading b-tree node block (ino=%llu, blocknr=%llu)" , btree->b_inode->i_ino, (unsigned long long )ptr);brelse (bh);return -EIO ;@@ -2104,7 +2104,7 @@ static int nilfs_btree_propagate(struct nilfs_bmap *btree,if (ret <0 ) {if (unlikely (ret == -ENOENT )) {nilfs_crit (btree->b_inode->i_sb, -"writing node/leaf block does not appear in b-tree (ino=%lu) at key=%llu, level=%d" , +"writing node/leaf block does not appear in b-tree (ino=%llu) at key=%llu, level=%d" , btree->b_inode->i_ino, (unsigned long long )key, level); ret = -EINVAL ;@@ -2146,7 +2146,7 @@ static void nilfs_btree_add_dirty_buffer(struct nilfs_bmap *btree, level >= NILFS_BTREE_LEVEL_MAX) {dump_stack ();nilfs_warn (btree->b_inode->i_sb, -"invalid btree level: %d (key=%llu, ino=%lu, blocknr=%llu)" , +"invalid btree level: %d (key=%llu, ino=%llu, blocknr=%llu)" , level, (unsigned long long )key, btree->b_inode->i_ino, (unsigned long long )bh->b_blocknr);fs/nilfs2/dir.c +0
-0@@ -150,7 +150,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr)
Quoted 15 lines
fs/nilfs2/dir.c static bool nilfs_check_folio(struct folio *folio, char *kaddr) · line 172
Quoted 13 lines
fs/nilfs2/dir.c +2
-2Ebadsize:nilfs_error (sb, -"size of directory #%lu is not a multiple of chunk size" , +"size of directory #%llu is not a multiple of chunk size" , dir->i_ino); goto fail; Eshort:@@ -169,7 +169,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) error ="disallowed inode number" ; bad_entry: nilfs_error(sb, - "bad entry in directory #%lu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d", + "bad entry in directory #%llu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d",I think you missed 'inode=%lu' here.
That is actually the placeholder for this:
(unsigned long)le64_to_cpu(p->inode)
...which is not inode->i_ino. I do agree that the cast probably no longer makes sense with this change, but I'd probably leave that to a later cleanup so we can keep this set focused on the i_ino change.
Quoted 13 lines
fs/nilfs2/dir.c static bool nilfs_check_folio(struct folio *folio, char *kaddr) · line 180
Quoted 9 lines
fs/nilfs2/dir.c +1
-1dir->i_ino, error, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long )le64_to_cpu (p->inode), rec_len, p->name_len);@@ -177,7 +177,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) Eend: p = (struct nilfs_dir_entry *)(kaddr + offs); nilfs_error(sb, - "entry in directory #%lu spans the page boundary offset=%lu, inode=%lu", + "entry in directory #%llu spans the page boundary offset=%lu, inode=%lu",Ditto. You missed 'inode=%lu' here.
Same here.
Quoted 201 lines
Quoted 201 lines
fs/nilfs2/dir.c +3
-3dir->i_ino, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long)le64_to_cpu(p->inode)); fail:@@ -251,7 +251,7 @@ static int nilfs_readdir(struct file *file, struct dir_context *ctx) kaddr =nilfs_get_folio (inode, n, &folio);if (IS_ERR (kaddr)) { -nilfs_error (sb,"bad page in #%lu" , inode->i_ino); +nilfs_error (sb,"bad page in #%llu" , inode->i_ino); ctx->pos +=PAGE_SIZE - offset;return -EIO ; }@@ -336,7 +336,7 @@ struct nilfs_dir_entry *nilfs_find_entry(struct inode *dir,/* next folio is past the blocks we've got */ if (unlikely (n > (dir->i_blocks >> (PAGE_SHIFT -9 )))) {nilfs_error (dir->i_sb, -"dir %lu size %lld exceeds block count %llu" , +"dir %llu size %lld exceeds block count %llu" , dir->i_ino, dir->i_size, (unsigned long long )dir->i_blocks); goto out;@@ -382,7 +382,7 @@ struct nilfs_dir_entry *nilfs_dotdot(struct inode *dir, struct folio **foliop)return next_de; fail: -nilfs_error (dir->i_sb,"directory #%lu %s" , dir->i_ino, msg); +nilfs_error (dir->i_sb,"directory #%llu %s" , dir->i_ino, msg);folio_release_kmap (folio, de);return NULL ; }fs/nilfs2/direct.c +2
-2@@ -338,7 +338,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, key =nilfs_bmap_data_get_key (bmap, *bh);if (unlikely (key >NILFS_DIRECT_KEY_MAX )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid key: %llu" , +"%s (ino=%llu): invalid key: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )key);return -EINVAL ;@@ -346,7 +346,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, ptr =nilfs_direct_get_ptr (bmap, key);if (unlikely (ptr ==NILFS_BMAP_INVALID_PTR )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid pointer: %llu" , +"%s (ino=%llu): invalid pointer: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )ptr);return -EINVAL ;fs/nilfs2/gcinode.c +1
-1@@ -137,7 +137,7 @@ int nilfs_gccache_wait_and_mark_dirty(struct buffer_head *bh)struct inode *inode = bh->b_folio->mapping->host;nilfs_err (inode->i_sb, -"I/O error reading %s block for GC (ino=%lu, vblocknr=%llu)" , +"I/O error reading %s block for GC (ino=%llu, vblocknr=%llu)" ,buffer_nilfs_node (bh) ?"node" :"data" , inode->i_ino, (unsigned long long )bh->b_blocknr);return -EIO ;fs/nilfs2/inode.c +4
-4@@ -108,7 +108,7 @@ int nilfs_get_block(struct inode *inode, sector_t blkoff,* be locked in this case. */ nilfs_warn (inode->i_sb, -"%s (ino=%lu): a race condition while inserting a data block at offset=%llu" , +"%s (ino=%llu): a race condition while inserting a data block at offset=%llu" , __func__, inode->i_ino, (unsigned long long )blkoff); err = -EAGAIN ;@@ -789,7 +789,7 @@ static void nilfs_truncate_bmap(struct nilfs_inode_info *ii, goto repeat; failed: -nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%lu)" , +nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%llu)" , ret, ii->vfs_inode.i_ino); }@@ -1026,7 +1026,7 @@ int nilfs_set_file_dirty(struct inode *inode, unsigned int nr_dirty)* this inode. */ nilfs_warn (inode->i_sb, -"cannot set file dirty (ino=%lu): the file is being freed" , +"cannot set file dirty (ino=%llu): the file is being freed" , inode->i_ino);spin_unlock (&nilfs->ns_inode_lock);return -EINVAL ;/* @@ -1057,7 +1057,7 @@ int __nilfs_mark_inode_dirty(struct inode *inode, int flags) err =nilfs_load_inode_block (inode, &ibh);if (unlikely (err)) {nilfs_warn (inode->i_sb, -"cannot mark inode dirty (ino=%lu): error %d loading inode block" , +"cannot mark inode dirty (ino=%llu): error %d loading inode block" , inode->i_ino, err);return err; }fs/nilfs2/mdt.c +1
-1@@ -203,7 +203,7 @@ static int nilfs_mdt_read_block(struct inode *inode, unsigned long block, err = -EIO ;if (!buffer_uptodate (first_bh)) {nilfs_err (inode->i_sb, -"I/O error reading meta-data file (ino=%lu, block-offset=%lu)" , +"I/O error reading meta-data file (ino=%llu, block-offset=%lu)" , inode->i_ino, block); goto failed_bh; }fs/nilfs2/namei.c +1
-1@@ -292,7 +292,7 @@ static int nilfs_do_unlink(struct inode *dir, struct dentry *dentry)if (!inode->i_nlink) {nilfs_warn (inode->i_sb, -"deleting nonexistent file (ino=%lu), %d" , +"deleting nonexistent file (ino=%llu), %d" , inode->i_ino, inode->i_nlink);set_nlink (inode,1 ); }fs/nilfs2/segment.c +1
-1@@ -2024,7 +2024,7 @@ static int nilfs_segctor_collect_dirty_files(struct nilfs_sc_info *sci, ifile, ii->vfs_inode.i_ino, &ibh);if (unlikely (err)) {nilfs_warn (sci->sc_super, -"log writer: error %d getting inode block (ino=%lu)" , +"log writer: error %d getting inode block (ino=%llu)" , err, ii->vfs_inode.i_ino);return err; }include/trace/events/nilfs2.h +6
-6@@ -165,14 +165,14 @@ TRACE_EVENT(nilfs2_segment_usage_freed, TRACE_EVENT(nilfs2_mdt_insert_new_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long block), TP_ARGS(inode, ino, block), TP_STRUCT__entry( __field(struct inode *, inode) - __field(unsigned long, ino) + __field(u64, ino) __field(unsigned long, block) ),@@ -182,7 +182,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, __entry->block = block; ), -TP_printk ("inode = %p ino = %lu block = %lu" , +TP_printk ("inode = %p ino = %llu block = %lu" , __entry->inode, __entry->ino, __entry->block)@@ -190,7 +190,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, TRACE_EVENT(nilfs2_mdt_submit_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long blkoff, enum req_op mode),@@ -198,7 +198,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block,TP_STRUCT__entry (__field (struct inode *,inode ) - __field(unsigned long, ino) +__field (u64, ino) __field(unsigned long, blkoff)/* * Use field_struct() to avoid is_signed_type() on the @@ -214,7 +214,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block, __entry->mode = mode; ), - TP_printk("inode = %p ino = %lu blkoff = %lu mode = %x", + TP_printk("inode = %p ino = %llu blkoff = %lu mode = %x", __entry->inode, __entry->ino, __entry->blkoff,
Signature · 1 line
Jeff Layton <[email protected]>
Jeff Layton
maintainerRe: [PATCH 12/61] nfsd: update format strings for u64 i_ino
In reply to Chuck LeverQuoted 81 lines · Chuck Lever
Quoted 68 lines · Jeff Layton
Update format strings from %ld/%lu to %lld/%llu for
i_ino, which is now a u64.Signed-off-by Jeff Layton <[email protected]>--- fs/nfsd/export.c | 2 +- fs/nfsd/nfs4state.c | 4 ++-- fs/nfsd/nfsfh.c | 4 ++-- fs/nfsd/vfs.c | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-)fs/nfsd/export.c +1
-1@@ -1039,7 +1039,7 @@ exp_rootfh(struct net *net, struct auth_domain *clp, char *name, } inode =d_inode (path.dentry); -dprintk ("nfsd: exp_rootfh(%s [%p] %s:%s/%ld)\n" , +dprintk ("nfsd: exp_rootfh(%s [%p] %s:%s/%lld)\n" , name, path.dentry, clp->name, inode->i_sb->s_id, inode->i_ino); exp =exp_parent (cd, clp, &path);fs/nfsd/nfs4state.c +2
-2@@ -1253,7 +1253,7 @@ static void nfsd4_finalize_deleg_timestamps(struct nfs4_delegation *dp, struct fif (ret) {struct inode *inode =file_inode (f); -pr_notice_ratelimited ("nfsd: Unable to update timestamps on inode %02x:%02x:%lu: %d\n" , +pr_notice_ratelimited ("nfsd: Unable to update timestamps on inode %02x:%02x:%llu: %d\n" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino, ret);@@ -2888,7 +2888,7 @@ static void nfs4_show_superblock(struct seq_file *s, struct nfsd_file *f) {struct inode *inode =file_inode (f->nf_file); -seq_printf (s,"superblock: \"%02x:%02x:%ld\"" , +seq_printf (s,"superblock: \"%02x:%02x:%llu\"" ,MAJOR (inode->i_sb->s_dev),MINOR (inode->i_sb->s_dev), inode->i_ino);fs/nfsd/nfsfh.c +2
-2@@ -601,9 +601,9 @@ fh_compose(struct svc_fh *fhp, struct svc_export *exp, struct dentry *dentry,struct inode * inode =d_inode (dentry);dev_t ex_dev =exp_sb (exp)->s_dev; -dprintk ("nfsd: fh_compose(exp %02x:%02x/%ld %pd2, ino=%ld)\n" , +dprintk ("nfsd: fh_compose(exp %02x:%02x/%lld %pd2, ino=%lld)\n" ,MAJOR (ex_dev),MINOR (ex_dev), - (long )d_inode (exp->ex_path.dentry)->i_ino, + (long long )d_inode (exp->ex_path.dentry)->i_ino, dentry, (inode ? inode->i_ino :0 ));fs/nfsd/vfs.c +0
-0fs/nfsd/vfs.c nfsd_direct_read(struct svc_rqst *rqstp, struct svc_fh *fhp, · line 1169
Quoted 8 lines
fs/nfsd/vfs.c +1
-1@@ -1163,7 +1163,7 @@ nfsd_direct_read(struct svc_rqst *rqstp, struct svc_fh *fhp, }else if (unlikely (host_err == -EINVAL )) {struct inode *inode =d_inode (fhp->fh_dentry); -pr_info_ratelimited ("nfsd: Direct I/O alignment failure on %s/%ld\n" , +pr_info_ratelimited ("nfsd: Direct I/O alignment failure on %s/%lld\n" , inode->i_sb->s_id, inode->i_ino); host_err = -ESERVERFAULT ; }Suggestion: Let's use the %llu format specifier consistently for
inode->i_ino, which is unsigned.
Quoted 2 lines
Reviewed-by Chuck Lever <[email protected]>
Good plan. I'll have claude do a pass for that in the next set.
Signature · 1 line
Jeff Layton <[email protected]>
Viacheslav Dubeyko
Reviewed-byRE: [PATCH 17/61] nilfs2: update for u64 i_ino
In reply to Jeff LaytonQuoted 179 lines · Jeff Layton
Quoted 162 lines · Viacheslav Dubeyko
Quoted 161 lines · Jeff Layton
Update nilfs2 trace events and filesystem code for u64
i_ino:- Change
__field(ino_t, ...)to__field(u64, ...)in trace events
- Update format strings from %lu to %llu
- Cast to (unsigned long long) inTP_printkSigned-off-by Jeff Layton <[email protected]>--- fs/nilfs2/alloc.c | 10 +++++----- fs/nilfs2/bmap.c | 2 +- fs/nilfs2/btnode.c | 2 +- fs/nilfs2/btree.c | 12 ++++++------ fs/nilfs2/dir.c | 12 ++++++------ fs/nilfs2/direct.c | 4 ++-- fs/nilfs2/gcinode.c | 2 +- fs/nilfs2/inode.c | 8 ++++---- fs/nilfs2/mdt.c | 2 +- fs/nilfs2/namei.c | 2 +- fs/nilfs2/segment.c | 2 +- include/trace/events/nilfs2.h | 12 ++++++------ 12 files changed, 35 insertions(+), 35 deletions(-)fs/nilfs2/alloc.c +5
-5@@ -707,7 +707,7 @@ void nilfs_palloc_commit_free_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else @@ -748,7 +748,7 @@ void nilfs_palloc_abort_alloc_entry(struct inode *inode,if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap))nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )req->pr_entry_nr);else @@ -861,7 +861,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems)if (!nilfs_clear_bit_atomic (lock, group_offset, bitmap)) {nilfs_warn (inode->i_sb, -"%s (ino=%lu): entry number %llu already freed" , +"%s (ino=%llu): entry number %llu already freed" , __func__, inode->i_ino, (unsigned long long )entry_nrs[j]); }else {@@ -906,7 +906,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) last_nrs[k]);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting block that object (entry=%llu, ino=%lu) belongs to" , +"error %d deleting block that object (entry=%llu, ino=%llu) belongs to" , ret, (unsigned long long )last_nrs[k], inode->i_ino); }@@ -923,7 +923,7 @@ int nilfs_palloc_freev(struct inode *inode, __u64 *entry_nrs, size_t nitems) ret =nilfs_palloc_delete_bitmap_block (inode, group);if (ret && ret != -ENOENT )nilfs_warn (inode->i_sb, -"error %d deleting bitmap block of group=%lu, ino=%lu" , +"error %d deleting bitmap block of group=%lu, ino=%llu" , ret, group, inode->i_ino); } }fs/nilfs2/bmap.c +1
-1@@ -33,7 +33,7 @@ static int nilfs_bmap_convert_error(struct nilfs_bmap *bmap,if (err == -EINVAL ) {__nilfs_error (inode->i_sb, fname, -"broken bmap (inode number=%lu)" , inode->i_ino); +"broken bmap (inode number=%llu)" , inode->i_ino); err = -EIO ; }return err;fs/nilfs2/btnode.c +1
-1@@ -64,7 +64,7 @@ nilfs_btnode_create_block(struct address_space *btnc, __u64 blocknr)* clearing of an abandoned b-tree node is missing somewhere). */ nilfs_error (inode->i_sb, -"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%lu)" , +"state inconsistency probably due to duplicate use of b-tree node block address %llu (ino=%llu)" , (unsigned long long )blocknr, inode->i_ino); goto failed; }fs/nilfs2/btree.c +6
-6@@ -353,7 +353,7 @@ static int nilfs_btree_node_broken(const struct nilfs_btree_node *node, nchildren <= 0 || nchildren > NILFS_BTREE_NODE_NCHILDREN_MAX(size))) {nilfs_crit (inode->i_sb, -"bad btree node (ino=%lu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree node (ino=%llu, blocknr=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, (unsigned long long )blocknr, level, flags, nchildren); ret =1 ;@@ -384,7 +384,7 @@ static int nilfs_btree_root_broken(const struct nilfs_btree_node *node, nchildren > NILFS_BTREE_ROOT_NCHILDREN_MAX || (nchildren == 0 && level > NILFS_BTREE_LEVEL_NODE_MIN))) {nilfs_crit (inode->i_sb, -"bad btree root (ino=%lu): level = %d, flags = 0x%x, nchildren = %d" , +"bad btree root (ino=%llu): level = %d, flags = 0x%x, nchildren = %d" , inode->i_ino, level, flags, nchildren); ret =1 ; }@@ -453,7 +453,7 @@ static int nilfs_btree_bad_node(const struct nilfs_bmap *btree,if (unlikely (nilfs_btree_node_get_level (node) != level)) {dump_stack ();nilfs_crit (btree->b_inode->i_sb, -"btree level mismatch (ino=%lu): %d != %d" , +"btree level mismatch (ino=%llu): %d != %d" , btree->b_inode->i_ino,nilfs_btree_node_get_level (node), level);return 1 ;@@ -521,7 +521,7 @@ static int __nilfs_btree_get_block(const struct nilfs_bmap *btree, __u64 ptr, out_no_wait:if (!buffer_uptodate (bh)) {nilfs_err (btree->b_inode->i_sb, -"I/O error reading b-tree node block (ino=%lu, blocknr=%llu)" , +"I/O error reading b-tree node block (ino=%llu, blocknr=%llu)" , btree->b_inode->i_ino, (unsigned long long )ptr);brelse (bh);return -EIO ;@@ -2104,7 +2104,7 @@ static int nilfs_btree_propagate(struct nilfs_bmap *btree,if (ret <0 ) {if (unlikely (ret == -ENOENT )) {nilfs_crit (btree->b_inode->i_sb, -"writing node/leaf block does not appear in b-tree (ino=%lu) at key=%llu, level=%d" , +"writing node/leaf block does not appear in b-tree (ino=%llu) at key=%llu, level=%d" , btree->b_inode->i_ino, (unsigned long long )key, level); ret = -EINVAL ;@@ -2146,7 +2146,7 @@ static void nilfs_btree_add_dirty_buffer(struct nilfs_bmap *btree, level >= NILFS_BTREE_LEVEL_MAX) {dump_stack ();nilfs_warn (btree->b_inode->i_sb, -"invalid btree level: %d (key=%llu, ino=%lu, blocknr=%llu)" , +"invalid btree level: %d (key=%llu, ino=%llu, blocknr=%llu)" , level, (unsigned long long )key, btree->b_inode->i_ino, (unsigned long long )bh->b_blocknr);fs/nilfs2/dir.c +0
-0@@ -150,7 +150,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr)Quoted 15 lines
fs/nilfs2/dir.c static bool nilfs_check_folio(struct folio *folio, char *kaddr) · line 172
Quoted 13 lines
fs/nilfs2/dir.c +2
-2Ebadsize:nilfs_error (sb, -"size of directory #%lu is not a multiple of chunk size" , +"size of directory #%llu is not a multiple of chunk size" , dir->i_ino); goto fail; Eshort:@@ -169,7 +169,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) error ="disallowed inode number" ; bad_entry: nilfs_error(sb, - "bad entry in directory #%lu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d", + "bad entry in directory #%llu: %s - offset=%lu, inode=%lu, rec_len=%zd, name_len=%d",I think you missed 'inode=%lu' here.
Quoted 7 lines
That is actually the placeholder for this:
(unsigned long)le64_to_cpu(p->inode)...which is not
inode->i_ino. I do agree that the cast probably no longer makes sense with this change, but I'd probably leave that to a later cleanup so we can keep this set focused on thei_inochange.
I see your point. Makes sense. The rest looks good.
Thanks,
Slava.
Quoted 219 lines
Quoted 15 lines
fs/nilfs2/dir.c static bool nilfs_check_folio(struct folio *folio, char *kaddr) · line 180
Quoted 11 lines
fs/nilfs2/dir.c +1
-1dir->i_ino, error, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long )le64_to_cpu (p->inode), rec_len, p->name_len);@@ -177,7 +177,7 @@ static bool nilfs_check_folio(struct folio *folio, char *kaddr) Eend: p = (struct nilfs_dir_entry *)(kaddr + offs); nilfs_error(sb, - "entry in directory #%lu spans the page boundary offset=%lu, inode=%lu", + "entry in directory #%llu spans the page boundary offset=%lu, inode=%lu",Ditto. You missed 'inode=%lu' here.
Same here.
Quoted 201 lines
Quoted 201 lines
fs/nilfs2/dir.c +3
-3dir->i_ino, (folio->index <<PAGE_SHIFT ) + offs, (unsigned long)le64_to_cpu(p->inode)); fail:@@ -251,7 +251,7 @@ static int nilfs_readdir(struct file *file, struct dir_context *ctx) kaddr =nilfs_get_folio (inode, n, &folio);if (IS_ERR (kaddr)) { -nilfs_error (sb,"bad page in #%lu" , inode->i_ino); +nilfs_error (sb,"bad page in #%llu" , inode->i_ino); ctx->pos +=PAGE_SIZE - offset;return -EIO ; }@@ -336,7 +336,7 @@ struct nilfs_dir_entry *nilfs_find_entry(struct inode *dir,/* next folio is past the blocks we've got */ if (unlikely (n > (dir->i_blocks >> (PAGE_SHIFT -9 )))) {nilfs_error (dir->i_sb, -"dir %lu size %lld exceeds block count %llu" , +"dir %llu size %lld exceeds block count %llu" , dir->i_ino, dir->i_size, (unsigned long long )dir->i_blocks); goto out;@@ -382,7 +382,7 @@ struct nilfs_dir_entry *nilfs_dotdot(struct inode *dir, struct folio **foliop)return next_de; fail: -nilfs_error (dir->i_sb,"directory #%lu %s" , dir->i_ino, msg); +nilfs_error (dir->i_sb,"directory #%llu %s" , dir->i_ino, msg);folio_release_kmap (folio, de);return NULL ; }fs/nilfs2/direct.c +2
-2@@ -338,7 +338,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, key =nilfs_bmap_data_get_key (bmap, *bh);if (unlikely (key >NILFS_DIRECT_KEY_MAX )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid key: %llu" , +"%s (ino=%llu): invalid key: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )key);return -EINVAL ;@@ -346,7 +346,7 @@ static int nilfs_direct_assign(struct nilfs_bmap *bmap, ptr =nilfs_direct_get_ptr (bmap, key);if (unlikely (ptr ==NILFS_BMAP_INVALID_PTR )) {nilfs_crit (bmap->b_inode->i_sb, -"%s (ino=%lu): invalid pointer: %llu" , +"%s (ino=%llu): invalid pointer: %llu" , __func__, bmap->b_inode->i_ino, (unsigned long long )ptr);return -EINVAL ;fs/nilfs2/gcinode.c +1
-1@@ -137,7 +137,7 @@ int nilfs_gccache_wait_and_mark_dirty(struct buffer_head *bh)struct inode *inode = bh->b_folio->mapping->host;nilfs_err (inode->i_sb, -"I/O error reading %s block for GC (ino=%lu, vblocknr=%llu)" , +"I/O error reading %s block for GC (ino=%llu, vblocknr=%llu)" ,buffer_nilfs_node (bh) ?"node" :"data" , inode->i_ino, (unsigned long long )bh->b_blocknr);return -EIO ;fs/nilfs2/inode.c +4
-4@@ -108,7 +108,7 @@ int nilfs_get_block(struct inode *inode, sector_t blkoff,* be locked in this case. */ nilfs_warn (inode->i_sb, -"%s (ino=%lu): a race condition while inserting a data block at offset=%llu" , +"%s (ino=%llu): a race condition while inserting a data block at offset=%llu" , __func__, inode->i_ino, (unsigned long long )blkoff); err = -EAGAIN ;@@ -789,7 +789,7 @@ static void nilfs_truncate_bmap(struct nilfs_inode_info *ii, goto repeat; failed: -nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%lu)" , +nilfs_warn (ii->vfs_inode.i_sb,"error %d truncating bmap (ino=%llu)" , ret, ii->vfs_inode.i_ino); }@@ -1026,7 +1026,7 @@ int nilfs_set_file_dirty(struct inode *inode, unsigned int nr_dirty)* this inode. */ nilfs_warn (inode->i_sb, -"cannot set file dirty (ino=%lu): the file is being freed" , +"cannot set file dirty (ino=%llu): the file is being freed" , inode->i_ino);spin_unlock (&nilfs->ns_inode_lock);return -EINVAL ;/* @@ -1057,7 +1057,7 @@ int __nilfs_mark_inode_dirty(struct inode *inode, int flags) err =nilfs_load_inode_block (inode, &ibh);if (unlikely (err)) {nilfs_warn (inode->i_sb, -"cannot mark inode dirty (ino=%lu): error %d loading inode block" , +"cannot mark inode dirty (ino=%llu): error %d loading inode block" , inode->i_ino, err);return err; }fs/nilfs2/mdt.c +1
-1@@ -203,7 +203,7 @@ static int nilfs_mdt_read_block(struct inode *inode, unsigned long block, err = -EIO ;if (!buffer_uptodate (first_bh)) {nilfs_err (inode->i_sb, -"I/O error reading meta-data file (ino=%lu, block-offset=%lu)" , +"I/O error reading meta-data file (ino=%llu, block-offset=%lu)" , inode->i_ino, block); goto failed_bh; }fs/nilfs2/namei.c +1
-1@@ -292,7 +292,7 @@ static int nilfs_do_unlink(struct inode *dir, struct dentry *dentry)if (!inode->i_nlink) {nilfs_warn (inode->i_sb, -"deleting nonexistent file (ino=%lu), %d" , +"deleting nonexistent file (ino=%llu), %d" , inode->i_ino, inode->i_nlink);set_nlink (inode,1 ); }fs/nilfs2/segment.c +1
-1@@ -2024,7 +2024,7 @@ static int nilfs_segctor_collect_dirty_files(struct nilfs_sc_info *sci, ifile, ii->vfs_inode.i_ino, &ibh);if (unlikely (err)) {nilfs_warn (sci->sc_super, -"log writer: error %d getting inode block (ino=%lu)" , +"log writer: error %d getting inode block (ino=%llu)" , err, ii->vfs_inode.i_ino);return err; }include/trace/events/nilfs2.h +6
-6@@ -165,14 +165,14 @@ TRACE_EVENT(nilfs2_segment_usage_freed, TRACE_EVENT(nilfs2_mdt_insert_new_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long block), TP_ARGS(inode, ino, block), TP_STRUCT__entry( __field(struct inode *, inode) - __field(unsigned long, ino) + __field(u64, ino) __field(unsigned long, block) ),@@ -182,7 +182,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, __entry->block = block; ), -TP_printk ("inode = %p ino = %lu block = %lu" , +TP_printk ("inode = %p ino = %llu block = %lu" , __entry->inode, __entry->ino, __entry->block)@@ -190,7 +190,7 @@ TRACE_EVENT(nilfs2_mdt_insert_new_block, TRACE_EVENT(nilfs2_mdt_submit_block, TP_PROTO(struct inode *inode, - unsigned long ino, + u64 ino, unsigned long blkoff, enum req_op mode),@@ -198,7 +198,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block,TP_STRUCT__entry (__field (struct inode *,inode ) - __field(unsigned long, ino) +__field (u64, ino) __field(unsigned long, blkoff)/* * Use field_struct() to avoid is_signed_type() on the @@ -214,7 +214,7 @@ TRACE_EVENT(nilfs2_mdt_submit_block, __entry->mode = mode; ), - TP_printk("inode = %p ino = %lu blkoff = %lu mode = %x", + TP_printk("inode = %p ino = %llu blkoff = %lu mode = %x", __entry->inode, __entry->ino, __entry->blkoff,
Re: [PATCH 47/61] ubifs: update format strings for u64 i_ino
In reply to Jeff Layton----- Ursprüngliche Mail -----
Quoted 6 lines
Von: "Jeff Layton" <[email protected]>
Update format strings and local variable types in ubifs for thei_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>---
Quoted 8 lines
fs/ubifs/debug.c | 8 ++++---- fs/ubifs/dir.c | 28 ++++++++++++++-------------- fs/ubifs/file.c | 28 ++++++++++++++-------------- fs/ubifs/journal.c | 6 +++--- fs/ubifs/super.c | 16 ++++++++-------- fs/ubifs/tnc.c | 4 ++-- fs/ubifs/xattr.c | 14 +++++++------- 7 files changed, 52 insertions(+), 52 deletions(-)
Thanks,
//richard
Re: [PATCH 37/61] jffs2: update format strings for u64 i_ino
In reply to Jeff Layton----- Ursprüngliche Mail -----
Quoted 10 lines
Von: "Jeff Layton" <[email protected]>
Update format strings and local variable types in jffs2 for thei_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>---
fs/jffs2/dir.c | 4 ++-- fs/jffs2/file.c | 4 ++-- fs/jffs2/fs.c | 18 +++++++++--------- 3 files changed, 13 insertions(+), 13 deletions(-)
Thanks,
//richard
Paul Moore
maintainerRe: [PATCH 51/61] security: update audit format strings for u64 i_ino
In reply to Jeff LaytonQuoted 16 lines · Jeff Layton
Update %lu/%ld to %llu/%lld in security audit logging functions that print
inode->i_ino, sincei_inois now u64.Files updated:
apparmor/apparmorfs.c,integrity/integrity_audit.c,ipe/audit.c,lsm_audit.c.Signed-off-by Jeff Layton <[email protected]>--- security/apparmor/apparmorfs.c | 4 ++-- security/integrity/integrity_audit.c | 2 +- security/ipe/audit.c | 2 +- security/lsm_audit.c | 10 +++++----- security/selinux/hooks.c | 4 ++-- security/smack/smack_lsm.c | 12 ++++++------ 6 files changed, 17 insertions(+), 17 deletions(-)
...
security/lsm_audit.c
Quoted 4 lines
security/lsm_audit.c +0
-0
Everything in security/lsm_audit.c looks okay.
security/selinux/hooks.c static int inode_doinit_use_xattr(struct inode *inode, struct dentry *dentry, · line 1406
Quoted 13 lines
security/selinux/hooks.c +1
-1@@ -1400,7 +1400,7 @@ static int inode_doinit_use_xattr(struct inode *inode, struct dentry *dentry,if (rc <0 ) {kfree (context);if (rc != -ENODATA ) { -pr_warn ("SELinux: %s: getxattr returned %d for dev=%s ino=%ld\n" , +pr_warn ("SELinux: %s: getxattr returned %d for dev=%s ino=%lld\n" , __func__, -rc, inode->i_sb->s_id, inode->i_ino);return rc; }
Additionally, later in this function there are pr_notice_ratelimited() and pr_warn() calls that print inode numbers and need to be updated.
Signature · 1 line
paul-moore.com
Re: [PATCH 50/61] zonefs: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · Jeff Layton
Update format strings and local variable types in zonefs for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>
Signature · 2 lines
Damien Le Moal Western Digital Research
Re: [PATCH 03/61] trace: update VFS-layer trace events for u64 i_ino
In reply to Jeff LaytonQuoted 13 lines · Jeff Layton
Update trace event definitions in VFS-layer trace headers to use u64 instead of ino_t/unsigned long for inode number fields, and change format strings from %lu/%lx to %llu/%llx to match.
This is needed because
i_inois now u64. Changing trace event field types changes the binary trace format, but the self-describing format metadata handles this transparently for modern trace-cmd and perf.Files updated:
-cachefiles.h,filelock.h,filemap.h,fs_dax.h,fsverity.h,hugetlbfs.h,netfs.h,readahead.h,timestamp.h,writeback.hSigned-off-by Jeff Layton <[email protected]>
[...]
include/trace/events/writeback.h TRACE_EVENT(balance_dirty_pages, · line 729
Quoted 6 lines
include/trace/events/writeback.h +1
-1@@ -726,7 +726,7 @@ TRACE_EVENT(balance_dirty_pages, __entry->pause,/* ms */ __entry->period,/* ms */ __entry->think,/* ms */ - (unsigned long )__entry->cgroup_ino + (unsigned long long )__entry->cgroup_ino
Do we really need this cast here ? (same comment for the following events).
Other than this, this looks OK to me.
Signature · 2 lines
Damien Le Moal Western Digital Research
Damien Le Moal
maintainerRe: [PATCH 01/61] vfs: widen inode hash/lookup functions to u64
In reply to Jeff LaytonQuoted 18 lines · Jeff Layton
Change the inode hash/lookup VFS API functions to accept u64 parameters instead of unsigned long for inode numbers and hash values. This is preparation for widening
i_inoitself to u64, which will allow filesystems to store full 64-bit inode numbers on 32-bit architectures.Since unsigned long implicitly widens to u64 on all architectures, this change is backward-compatible with all existing callers.
Functions updated:
-hash(),find_inode_fast(),find_inode_by_ino_rcu(),test_inode_iunique()
-__insert_inode_hash(),iget_locked(),iget5_locked(),iget5_locked_rcu()
-ilookup(),ilookup5(),ilookup5_nowait()
-find_inode_nowait(),find_inode_rcu()
-inode_insert5(),insert_inode_locked4()
-insert_inode_locked()(local variable)
-dump_mapping()(local variable and format string)Signed-off-by Jeff Layton <[email protected]>
[...]
fs/inode.c void init_special_inode(struct inode *inode, umode_t mode, dev_t rdev) · line 2645
Quoted 11 lines
fs/inode.c +2
-2-int insert_inode_locked4 (struct inode *inode,unsigned long hashval, +int insert_inode_locked4 (struct inode *inode,u64 hashval,int (*test)(struct inode *,void *),void *data) {struct inode *old;@@ -2642,7 +2642,7 @@ void init_special_inode(struct inode *inode, umode_t mode, dev_t rdev)break ;default : printk(KERN_DEBUG "init_special_inode: bogus i_mode (%o) for" - " inode %s:%lu\n", mode, inode->i_sb->s_id, + " inode %s:%llu\n", mode, inode->i_sb->s_id,
Hmmm. the type of ino in struct inode is changed in patch 2, not this patch. So this feels incorrect. Why not just squash patch 2 in here ?
While at it, maybe you could change this to use pr_debug() too ?
Signature · 2 lines
Damien Le Moal Western Digital Research
Re: [PATCH 47/61] ubifs: update format strings for u64 i_ino
In reply to Jeff LaytonQuoted 4 lines · Jeff Layton
Update format strings and local variable types in ubifs for the
i_inotype change from unsigned long to u64.Signed-off-by Jeff Layton <[email protected]>
Quoted 9 lines
--- fs/ubifs/debug.c | 8 ++++---- fs/ubifs/dir.c | 28 ++++++++++++++-------------- fs/ubifs/file.c | 28 ++++++++++++++-------------- fs/ubifs/journal.c | 6 +++--- fs/ubifs/super.c | 16 ++++++++-------- fs/ubifs/tnc.c | 4 ++-- fs/ubifs/xattr.c | 14 +++++++------- 7 files changed, 52 insertions(+), 52 deletions(-)
Quoted 487 lines
fs/ubifs/debug.c +4
-4@@ -230,7 +230,7 @@ void ubifs_dump_inode(struct ubifs_info *c, const struct inode *inode)int count =2 ;pr_err ("Dump in-memory inode:" ); -pr_err ("\tinode %lu\n" , inode->i_ino); +pr_err ("\tinode %llu\n" , inode->i_ino);pr_err ("\tsize %llu\n" , (unsigned long long )i_size_read (inode));pr_err ("\tnlink %u\n" , inode->i_nlink);@@ -1101,7 +1101,7 @@ int dbg_check_synced_i_size(const struct ubifs_info *c, struct inode *inode)if (ui->ui_size != ui->synced_i_size && !ui->dirty) {ubifs_err (c,"ui_size is %lld, synced_i_size is %lld, but inode is clean" , ui->ui_size, ui->synced_i_size); -ubifs_err (c,"i_ino %lu, i_mode %#x, i_size %lld" , inode->i_ino, +ubifs_err (c,"i_ino %llu, i_mode %#x, i_size %lld" , inode->i_ino, inode->i_mode,i_size_read (inode));dump_stack (); err = -EINVAL ;@@ -1163,7 +1163,7 @@ int dbg_check_dir(struct ubifs_info *c, const struct inode *dir)kfree (pdent);if (i_size_read (dir) != size) { -ubifs_err (c,"directory inode %lu has size %llu, but calculated size is %llu" , +ubifs_err (c,"directory inode %llu has size %llu, but calculated size is %llu" , dir->i_ino, (unsigned long long )i_size_read (dir), (unsigned long long )size);ubifs_dump_inode (c, dir);@@ -1171,7 +1171,7 @@ int dbg_check_dir(struct ubifs_info *c, const struct inode *dir)return -EINVAL ; }if (dir->i_nlink != nlink) { -ubifs_err (c,"directory inode %lu has nlink %u, but calculated nlink is %u" , +ubifs_err (c,"directory inode %llu has nlink %u, but calculated nlink is %u" , dir->i_ino, dir->i_nlink, nlink);ubifs_dump_inode (c, dir);dump_stack ();fs/ubifs/dir.c +14
-14@@ -223,7 +223,7 @@ static struct dentry *ubifs_lookup(struct inode *dir, struct dentry *dentry,struct ubifs_info *c = dir->i_sb->s_fs_info;struct fscrypt_name nm; -dbg_gen ("'%pd' in dir ino %lu" , dentry, dir->i_ino); +dbg_gen ("'%pd' in dir ino %llu" , dentry, dir->i_ino); err =fscrypt_prepare_lookup (dir, dentry, &nm);if (err == -ENOENT )@@ -281,7 +281,7 @@ static struct dentry *ubifs_lookup(struct inode *dir, struct dentry *dentry,if (IS_ENCRYPTED (dir) && (S_ISDIR (inode->i_mode) ||S_ISLNK (inode->i_mode)) && !fscrypt_has_permitted_context (dir, inode)) { -ubifs_warn (c,"Inconsistent encryption contexts: %lu/%lu" , +ubifs_warn (c,"Inconsistent encryption contexts: %llu/%llu" , dir->i_ino, inode->i_ino);iput (inode); inode =ERR_PTR (-EPERM );@@ -318,7 +318,7 @@ static int ubifs_create(struct mnt_idmap *idmap, struct inode *dir,* parent directory inode. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); err =ubifs_budget_space (c, &req);@@ -386,7 +386,7 @@ static struct inode *create_whiteout(struct inode *dir, struct dentry *dentry)* atomically. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); inode =ubifs_new_inode (c, dir, mode, false);@@ -460,7 +460,7 @@ static int ubifs_tmpfile(struct mnt_idmap *idmap, struct inode *dir,* be released via writeback. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); err =fscrypt_setup_filename (dir, &dentry->d_name,0 , &nm);@@ -589,7 +589,7 @@ static int ubifs_readdir(struct file *file, struct dir_context *ctx)bool encrypted =IS_ENCRYPTED (dir);struct ubifs_dir_data *data = file->private_data; -dbg_gen ("dir ino %lu, f_pos %#llx" , dir->i_ino, ctx->pos); +dbg_gen ("dir ino %llu, f_pos %#llx" , dir->i_ino, ctx->pos);if (ctx->pos >UBIFS_S_KEY_HASH_MASK || ctx->pos ==2 )/* @@ -764,7 +764,7 @@ static int ubifs_link(struct dentry *old_dentry, struct inode *dir,* changing the parent inode. */ -dbg_gen ("dent '%pd' to ino %lu (nlink %d) in dir ino %lu" , +dbg_gen ("dent '%pd' to ino %llu (nlink %d) in dir ino %llu" , dentry, inode->i_ino, inode->i_nlink, dir->i_ino);ubifs_assert (c,inode_is_locked (dir));@@ -836,7 +836,7 @@ static int ubifs_unlink(struct inode *dir, struct dentry *dentry)* deletions. */ -dbg_gen ("dent '%pd' from ino %lu (nlink %d) in dir ino %lu" , +dbg_gen ("dent '%pd' from ino %llu (nlink %d) in dir ino %llu" , dentry, inode->i_ino, inode->i_nlink, dir->i_ino);@@ -941,7 +941,7 @@ static int ubifs_rmdir(struct inode *dir, struct dentry *dentry)* because we have extra space reserved for deletions. */ -dbg_gen ("directory '%pd', ino %lu in dir ino %lu" , dentry, +dbg_gen ("directory '%pd', ino %llu in dir ino %llu" , dentry, inode->i_ino, dir->i_ino);ubifs_assert (c,inode_is_locked (dir));ubifs_assert (c,inode_is_locked (inode));@@ -1018,7 +1018,7 @@ static struct dentry *ubifs_mkdir(struct mnt_idmap *idmap, struct inode *dir,* directory inode. */ -dbg_gen ("dent '%pd', mode %#hx in dir ino %lu" , +dbg_gen ("dent '%pd', mode %#hx in dir ino %llu" , dentry, mode, dir->i_ino); err =ubifs_budget_space (c, &req);@@ -1096,7 +1096,7 @@ static int ubifs_mknod(struct mnt_idmap *idmap, struct inode *dir,* directory inode. */ -dbg_gen ("dent '%pd' in dir ino %lu" , dentry, dir->i_ino); +dbg_gen ("dent '%pd' in dir ino %llu" , dentry, dir->i_ino);if (S_ISBLK (mode) ||S_ISCHR (mode)) { dev = kmalloc_obj(union ubifs_dev_desc, GFP_NOFS);@@ -1183,7 +1183,7 @@ static int ubifs_symlink(struct mnt_idmap *idmap, struct inode *dir, .dirtied_ino = 1 };struct fscrypt_name nm; -dbg_gen ("dent '%pd', target '%s' in dir ino %lu" , dentry, +dbg_gen ("dent '%pd', target '%s' in dir ino %llu" , dentry, symname, dir->i_ino); err = fscrypt_prepare_symlink(dir, symname, len, UBIFS_MAX_INO_DATA,@@ -1349,7 +1349,7 @@ static int do_rename(struct inode *old_dir, struct dentry *old_dentry,* ino_req: marks the target inode as dirty and does not write it. */ -dbg_gen ("dent '%pd' ino %lu in dir ino %lu to dent '%pd' in dir ino %lu flags 0x%x" , +dbg_gen ("dent '%pd' ino %llu in dir ino %llu to dent '%pd' in dir ino %llu flags 0x%x" , old_dentry, old_inode->i_ino, old_dir->i_ino, new_dentry, new_dir->i_ino, flags);@@ -1597,7 +1597,7 @@ static int ubifs_xrename(struct inode *old_dir, struct dentry *old_dentry,* parent directory inodes. */ -dbg_gen ("dent '%pd' ino %lu in dir ino %lu exchange dent '%pd' ino %lu in dir ino %lu" , +dbg_gen ("dent '%pd' ino %llu in dir ino %llu exchange dent '%pd' ino %llu in dir ino %llu" , old_dentry, fst_inode->i_ino, old_dir->i_ino, new_dentry, snd_inode->i_ino, new_dir->i_ino);fs/ubifs/file.c +14
-14@@ -90,7 +90,7 @@ static int read_block(struct inode *inode, struct folio *folio, size_t offset,return 0 ; dump: -ubifs_err (c,"bad data node (block %u, inode %lu)" , +ubifs_err (c,"bad data node (block %u, inode %llu)" , block, inode->i_ino);ubifs_dump_node (c, dn,UBIFS_MAX_DATA_NODE_SZ );return -EINVAL ;@@ -106,7 +106,7 @@ static int do_readpage(struct folio *folio)loff_t i_size =i_size_read (inode);size_t offset =0 ; -dbg_gen ("ino %lu, pg %lu, i_size %lld, flags %#lx" , +dbg_gen ("ino %llu, pg %lu, i_size %lld, flags %#lx" , inode->i_ino, folio->index, i_size, folio->flags.f);ubifs_assert (c, !folio_test_checked (folio));ubifs_assert (c, !folio->private);@@ -162,7 +162,7 @@ static int do_readpage(struct folio *folio)dbg_gen ("hole" ); err =0 ; }else { -ubifs_err (c,"cannot read page %lu of inode %lu, error %d" , +ubifs_err (c,"cannot read page %lu of inode %llu, error %d" , folio->index, inode->i_ino, err); } }@@ -212,7 +212,7 @@ static int write_begin_slow(struct address_space *mapping,int err, appending = !!(pos + len > inode->i_size);struct folio *folio; -dbg_gen ("ino %lu, pos %llu, len %u, i_size %lld" , +dbg_gen ("ino %llu, pos %llu, len %u, i_size %lld" , inode->i_ino, pos, len, inode->i_size);/* @@ -526,7 +526,7 @@ static int ubifs_write_end(const struct kiocb *iocb,loff_t end_pos = pos + len;int appending = !!(end_pos > inode->i_size); -dbg_gen ("ino %lu, pos %llu, pg %lu, len %u, copied %d, i_size %lld" , +dbg_gen ("ino %llu, pos %llu, pg %lu, len %u, copied %d, i_size %lld" , inode->i_ino, pos, folio->index, len, copied, inode->i_size);if (unlikely (copied < len && !folio_test_uptodate (folio))) {@@ -599,7 +599,7 @@ static int populate_page(struct ubifs_info *c, struct folio *folio,size_t offset =0 ;pgoff_t end_index; -dbg_gen ("ino %lu, pg %lu, i_size %lld, flags %#lx" , +dbg_gen ("ino %llu, pg %lu, i_size %lld, flags %#lx" , inode->i_ino, folio->index, i_size, folio->flags.f); end_index = (i_size -1 ) >>PAGE_SHIFT ;@@ -680,7 +680,7 @@ static int populate_page(struct ubifs_info *c, struct folio *folio,return 0 ; out_err: -ubifs_err (c,"bad data node (block %u, inode %lu)" , +ubifs_err (c,"bad data node (block %u, inode %llu)" , page_block, inode->i_ino);return -EINVAL ; }@@ -913,7 +913,7 @@ static int do_writepage(struct folio *folio, size_t len) }if (err) {mapping_set_error (folio->mapping, err); -ubifs_err (c,"cannot write folio %lu of inode %lu, error %d" , +ubifs_err (c,"cannot write folio %lu of inode %llu, error %d" , folio->index, inode->i_ino, err);ubifs_ro_mode (c, err); }@@ -987,7 +987,7 @@ static int ubifs_writepage(struct folio *folio, struct writeback_control *wbc)loff_t i_size =i_size_read (inode), synced_i_size;int err, len =folio_size (folio); -dbg_gen ("ino %lu, pg %lu, pg flags %#lx" , +dbg_gen ("ino %llu, pg %lu, pg flags %#lx" , inode->i_ino, folio->index, folio->flags.f);ubifs_assert (c, folio->private !=NULL );@@ -1106,7 +1106,7 @@ static int do_truncation(struct ubifs_info *c, struct inode *inode,int offset = new_size & (UBIFS_BLOCK_SIZE -1 ), budgeted =1 ;struct ubifs_inode *ui =ubifs_inode (inode); -dbg_gen ("ino %lu, size %lld -> %lld" , inode->i_ino, old_size, new_size); +dbg_gen ("ino %llu, size %lld -> %lld" , inode->i_ino, old_size, new_size);memset (&req,0 ,sizeof (struct ubifs_budget_req ));/* @@ -1258,7 +1258,7 @@ int ubifs_setattr(struct mnt_idmap *idmap, struct dentry *dentry,struct inode *inode =d_inode (dentry);struct ubifs_info *c = inode->i_sb->s_fs_info; -dbg_gen ("ino %lu, mode %#x, ia_valid %#x" , +dbg_gen ("ino %llu, mode %#x, ia_valid %#x" , inode->i_ino, inode->i_mode, attr->ia_valid); err =setattr_prepare (&nop_mnt_idmap, dentry, attr);if (err)@@ -1308,7 +1308,7 @@ int ubifs_fsync(struct file *file, loff_t start, loff_t end, int datasync)struct ubifs_info *c = inode->i_sb->s_fs_info;int err; -dbg_gen ("syncing inode %lu" , inode->i_ino); +dbg_gen ("syncing inode %llu" , inode->i_ino);if (c->ro_mount)/* @@ -1495,7 +1495,7 @@ static vm_fault_t ubifs_vm_page_mkwrite(struct vm_fault *vmf)struct ubifs_budget_req req = { .new_page =1 };int err, update_time; -dbg_gen ("ino %lu, pg %lu, i_size %lld" , inode->i_ino, folio->index, +dbg_gen ("ino %llu, pg %lu, i_size %lld" , inode->i_ino, folio->index,i_size_read (inode));ubifs_assert (c, !c->ro_media && !c->ro_mount);@@ -1531,7 +1531,7 @@ static vm_fault_t ubifs_vm_page_mkwrite(struct vm_fault *vmf) err =ubifs_budget_space (c, &req);if (unlikely (err)) {if (err == -ENOSPC ) -ubifs_warn (c,"out of space for mmapped file (inode number %lu)" , +ubifs_warn (c,"out of space for mmapped file (inode number %llu)" , inode->i_ino);return VM_FAULT_SIGBUS ; }fs/ubifs/journal.c +3
-3@@ -982,7 +982,7 @@ int ubifs_jnl_write_inode(struct ubifs_info *c, const struct inode *inode)int kill_xattrs = ui->xattr_cnt && last_reference;u8 hash[UBIFS_HASH_ARR_SZ ]; -dbg_jnl ("ino %lu, nlink %u" , inode->i_ino, inode->i_nlink); +dbg_jnl ("ino %llu, nlink %u" , inode->i_ino, inode->i_nlink);if (kill_xattrs && ui->xattr_cnt >ubifs_xattr_max_cnt (c)) {ubifs_err (c,"Cannot delete inode, it has too many xattrs!" );@@ -1743,7 +1743,7 @@ int ubifs_jnl_truncate(struct ubifs_info *c, const struct inode *inode,int dn_len =le32_to_cpu (dn->size);if (dn_len <=0 || dn_len >UBIFS_BLOCK_SIZE ) { -ubifs_err (c,"bad data node (block %u, inode %lu)" , +ubifs_err (c,"bad data node (block %u, inode %llu)" , blk, inode->i_ino);ubifs_dump_node (c, dn, dn_size); err = -EUCLEAN ;@@ -1987,7 +1987,7 @@ int ubifs_jnl_change_xattr(struct ubifs_info *c, const struct inode *inode,u8 hash_host[UBIFS_HASH_ARR_SZ ];u8 hash[UBIFS_HASH_ARR_SZ ]; -dbg_jnl ("ino %lu, ino %lu" , host->i_ino, inode->i_ino); +dbg_jnl ("ino %llu, ino %llu" , host->i_ino, inode->i_ino);ubifs_assert (c, inode->i_nlink >0 );ubifs_assert (c,mutex_is_locked (&host_ui->ui_mutex));fs/ubifs/super.c +8
-8@@ -92,7 +92,7 @@ static int validate_inode(struct ubifs_info *c, const struct inode *inode)return 5 ;if (!ubifs_compr_present (c, ui->compr_type)) { -ubifs_warn (c,"inode %lu uses '%s' compression, but it was not compiled in" , +ubifs_warn (c,"inode %llu uses '%s' compression, but it was not compiled in" , inode->i_ino,ubifs_compr_name (c, ui->compr_type)); }@@ -248,14 +248,14 @@ struct inode *ubifs_iget(struct super_block *sb, unsigned long inum)return inode; out_invalid: -ubifs_err (c,"inode %lu validation failed, error %d" , inode->i_ino, err); +ubifs_err (c,"inode %llu validation failed, error %d" , inode->i_ino, err);ubifs_dump_node (c, ino,UBIFS_MAX_INO_NODE_SZ );ubifs_dump_inode (c, inode); err = -EINVAL ; out_ino:kfree (ino); out: -ubifs_err (c,"failed to read inode %lu, error %d" , inode->i_ino, err); +ubifs_err (c,"failed to read inode %llu, error %d" , inode->i_ino, err);iget_failed (inode);return ERR_PTR (err); }@@ -316,12 +316,12 @@ static int ubifs_write_inode(struct inode *inode, struct writeback_control *wbc)* As an optimization, do not write orphan inodes to the media just * because this is not needed. */ -dbg_gen ("inode %lu, mode %#x, nlink %u" , +dbg_gen ("inode %llu, mode %#x, nlink %u" , inode->i_ino, (int )inode->i_mode, inode->i_nlink);if (inode->i_nlink) { err =ubifs_jnl_write_inode (c, inode);if (err) -ubifs_err (c,"can't write inode %lu, error %d" , +ubifs_err (c,"can't write inode %llu, error %d" , inode->i_ino, err);else err =dbg_check_inode_size (c, inode, ui->ui_size);@@ -357,7 +357,7 @@ static void ubifs_evict_inode(struct inode *inode)*/ goto out; -dbg_gen ("inode %lu, mode %#x" , inode->i_ino, (int )inode->i_mode); +dbg_gen ("inode %llu, mode %#x" , inode->i_ino, (int )inode->i_mode);ubifs_assert (c, !icount_read (inode));truncate_inode_pages_final (&inode->i_data);@@ -375,7 +375,7 @@ static void ubifs_evict_inode(struct inode *inode)* Worst case we have a lost orphan inode wasting space, so a * simple error message is OK here. */ -ubifs_err (c,"can't delete inode %lu, error %d" , +ubifs_err (c,"can't delete inode %llu, error %d" , inode->i_ino, err); out:@@ -399,7 +399,7 @@ static void ubifs_dirty_inode(struct inode *inode, int flags)ubifs_assert (c,mutex_is_locked (&ui->ui_mutex));if (!ui->dirty) { ui->dirty =1 ; -dbg_gen ("inode %lu" , inode->i_ino); +dbg_gen ("inode %llu" , inode->i_ino); } }fs/ubifs/tnc.c +2
-2@@ -3561,8 +3561,8 @@ int dbg_check_inode_size(struct ubifs_info *c, const struct inode *inode, out_dump: block =key_block (c, key); -ubifs_err (c,"inode %lu has size %lld, but there are data at offset %lld" , - (unsigned long )inode->i_ino, size, +ubifs_err (c,"inode %llu has size %lld, but there are data at offset %lld" , + (unsigned long long )inode->i_ino, size, ((loff_t )block) <<UBIFS_BLOCK_SHIFT );mutex_unlock (&c->tnc_mutex);ubifs_dump_inode (c, inode);fs/ubifs/xattr.c +7
-7@@ -76,7 +76,7 @@ static int create_xattr(struct ubifs_info *c, struct inode *host, .dirtied_ino_d = ALIGN(host_ui->data_len, 8) };if (host_ui->xattr_cnt >=ubifs_xattr_max_cnt (c)) { -ubifs_err (c,"inode %lu already has too many xattrs (%d), cannot create more" , +ubifs_err (c,"inode %llu already has too many xattrs (%d), cannot create more" , host->i_ino, host_ui->xattr_cnt);return -ENOSPC ; }@@ -88,7 +88,7 @@ static int create_xattr(struct ubifs_info *c, struct inode *host,*/ names_len = host_ui->xattr_names + host_ui->xattr_cnt +fname_len (nm) +1 ;if (names_len >XATTR_LIST_MAX ) { -ubifs_err (c,"cannot add one more xattr name to inode %lu, total names length would become %d, max. is %d" , +ubifs_err (c,"cannot add one more xattr name to inode %llu, total names length would become %d, max. is %d" , host->i_ino, names_len,XATTR_LIST_MAX );return -ENOSPC ; }@@ -390,7 +390,7 @@ ssize_t ubifs_listxattr(struct dentry *dentry, char *buffer, size_t size)int err, len, written =0 ;struct fscrypt_name nm = {0 }; -dbg_gen ("ino %lu ('%pd'), buffer size %zd" , host->i_ino, +dbg_gen ("ino %llu ('%pd'), buffer size %zd" , host->i_ino, dentry, size);down_read (&host_ui->xattr_sem);@@ -498,7 +498,7 @@ int ubifs_purge_xattrs(struct inode *host)if (ubifs_inode (host)->xattr_cnt <=ubifs_xattr_max_cnt (c))return 0 ; -ubifs_warn (c,"inode %lu has too many xattrs, doing a non-atomic deletion" , +ubifs_warn (c,"inode %llu has too many xattrs, doing a non-atomic deletion" , host->i_ino);down_write (&ubifs_inode (host)->xattr_sem);@@ -641,7 +641,7 @@ int ubifs_init_security(struct inode *dentry, struct inode *inode, &init_xattrs, NULL);if (err) {struct ubifs_info *c = dentry->i_sb->s_fs_info; -ubifs_err (c,"cannot initialize security for inode %lu, error %d" , +ubifs_err (c,"cannot initialize security for inode %llu, error %d" , inode->i_ino, err); }return err;@@ -652,7 +652,7 @@ static int xattr_get(const struct xattr_handler *handler, struct dentry *dentry, struct inode *inode, const char *name, void *buffer, size_t size) { - dbg_gen("xattr '%s', ino %lu ('%pd'), buf size %zd", name, + dbg_gen("xattr '%s', ino %llu ('%pd'), buf size %zd", name, inode->i_ino, dentry, size); name =xattr_full_name (handler, name);@@ -665,7 +665,7 @@ static int xattr_set(const struct xattr_handler *handler, const char *name, const void *value, size_t size, int flags) { - dbg_gen("xattr '%s', host ino %lu ('%pd'), size %zd", + dbg_gen("xattr '%s', host ino %llu ('%pd'), size %zd", name, inode->i_ino, dentry, size); name =xattr_full_name (handler, name);