From: Ye Bin <yebin10@xxxxxxxxxx> Use sb_for_each_inodes API foreach super_block->s_inodes. Signed-off-by: Ye Bin <yebin10@xxxxxxxxxx> --- security/landlock/fs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/security/landlock/fs.c b/security/landlock/fs.c index dd9a7297ea4e..ccb7951f1404 100644 --- a/security/landlock/fs.c +++ b/security/landlock/fs.c @@ -1217,7 +1217,7 @@ static void hook_sb_delete(struct super_block *const sb) return; spin_lock(&sb->s_inode_list_lock); - list_for_each_entry(inode, &sb->s_inodes, i_sb_list) { + sb_for_each_inodes(inode, &sb->s_inodes) { struct landlock_object *object; /* Only handles referenced inodes. */ -- 2.34.1