aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/atom.c
diff options
context:
space:
mode:
authorViacheslav Dubeyko <[email protected]>2025-06-02 18:49:56 +0000
committerIlya Dryomov <[email protected]>2025-06-06 09:08:59 +0000
commitb828b4bf29d10a3e505a76a39c4daea969e19dc9 (patch)
tree010d485d305d0bdea8d082f9a1ebb2ecfcf89a3a /drivers/gpu/drm/amd/amdgpu/atom.c
parentceph: set superblock s_magic for IMA fsmagic matching (diff)
downloadkernel-b828b4bf29d10a3e505a76a39c4daea969e19dc9.tar.gz
kernel-b828b4bf29d10a3e505a76a39c4daea969e19dc9.zip
ceph: fix variable dereferenced before check in ceph_umount_begin()
smatch warnings: fs/ceph/super.c:1042 ceph_umount_begin() warn: variable dereferenced before check 'fsc' (see line 1041) vim +/fsc +1042 fs/ceph/super.c void ceph_umount_begin(struct super_block *sb) { struct ceph_fs_client *fsc = ceph_sb_to_fs_client(sb); doutc(fsc->client, "starting forced umount\n"); ^^^^^^^^^^^ Dereferenced if (!fsc) ^^^^ Checked too late. return; fsc->mount_state = CEPH_MOUNT_SHUTDOWN; __ceph_umount_begin(fsc); } The VFS guarantees that the superblock is still alive when it calls into ceph via ->umount_begin(). Finally, we don't need to check the fsc and it should be valid. This patch simply removes the fsc check. Reported-by: kernel test robot <[email protected]> Reported-by: Dan Carpenter <[email protected]> Closes: https://lore.kernel.org/r/[email protected]/ Signed-off-by: Viacheslav Dubeyko <[email protected]> Reviewed by: Alex Markuze <[email protected]> Signed-off-by: Ilya Dryomov <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/atom.c')
0 files changed, 0 insertions, 0 deletions