kernel_samsung_a53x/fs/ocfs2
Alessandro Zanni da4803a973 fs: Fix uninitialized value issue in from_kuid and from_kgid
[ Upstream commit 15f34347481648a567db67fb473c23befb796af5 ]

ocfs2_setattr() uses attr->ia_mode, attr->ia_uid and attr->ia_gid in
a trace point even though ATTR_MODE, ATTR_UID and ATTR_GID aren't set.

Initialize all fields of newattrs to avoid uninitialized variables, by
checking if ATTR_MODE, ATTR_UID, ATTR_GID are initialized, otherwise 0.

Reported-by: syzbot+6c55f725d1bdc8c52058@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=6c55f725d1bdc8c52058
Signed-off-by: Alessandro Zanni <alessandro.zanni87@gmail.com>
Link: https://lore.kernel.org/r/20241017120553.55331-1-alessandro.zanni87@gmail.com
Reviewed-by: Jan Kara <jack@suse.cz>
Signed-off-by: Christian Brauner <brauner@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-30 02:33:28 +01:00
..
cluster Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dlm Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dlmfs Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acl.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
acl.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
alloc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
alloc.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
aops.c Revert "ocfs2: fix uninit-value in ocfs2_get_block()" 2024-11-24 00:23:03 +01:00
aops.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
blockcheck.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
blockcheck.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
buffer_head_io.c Revert "ocfs2: remove unreasonable unlock in ocfs2_read_blocks" 2024-11-24 00:23:02 +01:00
buffer_head_io.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dcache.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dcache.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dir.c ocfs2: add bounds checking to ocfs2_check_dir_entry() 2024-11-19 14:19:51 +01:00
dir.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dlmglue.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dlmglue.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
export.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
export.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
extent_map.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
extent_map.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
file.c fs: Fix uninitialized value issue in from_kuid and from_kgid 2024-11-30 02:33:28 +01:00
file.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
filecheck.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
filecheck.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
heartbeat.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
heartbeat.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
inode.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
inode.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ioctl.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ioctl.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
journal.c Revert "ocfs2: fix null-ptr-deref when journal load failed." 2024-11-24 00:23:02 +01:00
journal.h ocfs2: fix DIO failure due to insufficient transaction credits 2024-11-19 14:19:33 +01:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
localalloc.c Revert "ocfs2: fix the la space leak when unmounting an ocfs2 volume" 2024-11-24 00:23:03 +01:00
localalloc.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
locks.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
locks.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
mmap.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
mmap.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
move_extents.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
move_extents.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
namei.c ocfs2: use coarse time for new created files 2024-11-19 14:19:04 +01:00
namei.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs1_fs_compat.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs2.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs2_fs.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs2_ioctl.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs2_lockid.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs2_lockingver.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ocfs2_trace.h ocfs2: fix DIO failure due to insufficient transaction credits 2024-11-19 14:19:33 +01:00
quota.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
quota_global.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
quota_local.c Revert "ocfs2: cancel dqi_sync_work before freeing oinfo" 2024-11-24 00:23:03 +01:00
refcounttree.c Revert "ocfs2: reserve space for inline xattr before attaching reflink tree" 2024-11-24 00:23:03 +01:00
refcounttree.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
reservations.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
reservations.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
resize.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
resize.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
slot_map.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
slot_map.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
stack_o2cb.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
stack_user.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
stackglue.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
stackglue.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
suballoc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
suballoc.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
super.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
super.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
symlink.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
symlink.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sysfile.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
sysfile.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
uptodate.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
uptodate.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
xattr.c ocfs2: remove entry once instead of null-ptr-dereference in ocfs2_xa_remove() 2024-11-30 02:33:26 +01:00
xattr.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00