linux/fs/ocfs2
Gang He b73eba2a86 ocfs2: fix the crash due to call ocfs2_get_dlm_debug once less
Because ocfs2_get_dlm_debug() function is called once less here, ocfs2
file system will trigger the system crash, usually after ocfs2 file
system is unmounted.

This system crash is caused by a generic memory corruption, these crash
backtraces are not always the same, for exapmle,

    ocfs2: Unmounting device (253,16) on (node 172167785)
    general protection fault: 0000 [#1] SMP PTI
    CPU: 3 PID: 14107 Comm: fence_legacy Kdump:
    Hardware name: QEMU Standard PC (i440FX + PIIX, 1996)
    RIP: 0010:__kmalloc+0xa5/0x2a0
    Code: 00 00 4d 8b 07 65 4d 8b
    RSP: 0018:ffffaa1fc094bbe8 EFLAGS: 00010286
    RAX: 0000000000000000 RBX: d310a8800d7a3faf RCX: 0000000000000000
    RDX: 0000000000000000 RSI: 0000000000000dc0 RDI: ffff96e68fc036c0
    RBP: d310a8800d7a3faf R08: ffff96e6ffdb10a0 R09: 00000000752e7079
    R10: 000000000001c513 R11: 0000000004091041 R12: 0000000000000dc0
    R13: 0000000000000039 R14: ffff96e68fc036c0 R15: ffff96e68fc036c0
    FS:  00007f699dfba540(0000) GS:ffff96e6ffd80000(0000) knlGS:00000
    CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
    CR2: 000055f3a9d9b768 CR3: 000000002cd1c000 CR4: 00000000000006e0
    Call Trace:
     ext4_htree_store_dirent+0x35/0x100 [ext4]
     htree_dirblock_to_tree+0xea/0x290 [ext4]
     ext4_htree_fill_tree+0x1c1/0x2d0 [ext4]
     ext4_readdir+0x67c/0x9d0 [ext4]
     iterate_dir+0x8d/0x1a0
     __x64_sys_getdents+0xab/0x130
     do_syscall_64+0x60/0x1f0
     entry_SYSCALL_64_after_hwframe+0x49/0xbe
    RIP: 0033:0x7f699d33a9fb

This regression problem was introduced by commit e581595ea2 ("ocfs: no
need to check return value of debugfs_create functions").

Link: http://lkml.kernel.org/r/20191225061501.13587-1-ghe@suse.com
Fixes: e581595ea2 ("ocfs: no need to check return value of debugfs_create functions")
Signed-off-by: Gang He <ghe@suse.com>
Acked-by: Joseph Qi <joseph.qi@linux.alibaba.com>
Cc: Mark Fasheh <mark@fasheh.com>
Cc: Joel Becker <jlbec@evilplan.org>
Cc: Junxiao Bi <junxiao.bi@oracle.com>
Cc: Changwei Ge <gechangwei@live.cn>
Cc: Gang He <ghe@suse.com>
Cc: Jun Piao <piaojun@huawei.com>
Cc: <stable@vger.kernel.org>	[5.3+]
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2020-01-04 13:55:09 -08:00
..
cluster ocfs2: further debugfs cleanups 2019-09-24 15:54:07 -07:00
dlm ocfs2: wait for recovering done after direct unlock request 2019-09-24 15:54:07 -07:00
dlmfs
Kconfig
Makefile
acl.c ocfs2: fix passing zero to 'PTR_ERR' warning 2019-12-01 06:29:17 -08:00
acl.h
alloc.c ocfs2: Use accessor function for h_buffer_credits 2019-11-05 16:00:48 -05:00
alloc.h
aops.c Pipework for general notification queue 2019-11-30 14:12:13 -08:00
aops.h
blockcheck.c ocfs2: further debugfs cleanups 2019-09-24 15:54:07 -07:00
blockcheck.h
buffer_head_io.c
buffer_head_io.h
dcache.c
dcache.h
dir.c fs/ocfs2/dir.c: remove set but not used variables 2019-09-24 15:54:07 -07:00
dir.h
dlmglue.c ocfs2: fix the crash due to call ocfs2_get_dlm_debug once less 2020-01-04 13:55:09 -08:00
dlmglue.h
export.c
export.h
extent_map.c ocfs2: delete unnecessary checks before brelse() 2019-09-24 15:54:07 -07:00
extent_map.h
file.c ocfs2: protect extent tree in ocfs2_prepare_inode_for_write() 2019-11-06 08:47:08 -08:00
file.h
filecheck.c
filecheck.h
heartbeat.c
heartbeat.h
inode.c ocfs2: fix spelling mistake "ambigous" -> "ambiguous" 2019-09-24 15:54:07 -07:00
inode.h
ioctl.c compat_ioctl: remove most of fs/compat_ioctl.c 2019-12-01 13:46:15 -08:00
ioctl.h
journal.c ocfs2: call journal flush to mark journal as empty after journal recovery when mount 2020-01-04 13:55:09 -08:00
journal.h ocfs2: remove unused ocfs2_orphan_scan_exit() declaration 2019-09-24 15:54:07 -07:00
localalloc.c ocfs2: fix panic due to ocfs2_wq is null 2019-10-19 06:32:32 -04:00
localalloc.h
locks.c
locks.h
mmap.c
mmap.h
move_extents.c
move_extents.h
namei.c fs/ocfs2/namei.c: remove set but not used variables 2019-09-24 15:54:07 -07:00
namei.h
ocfs1_fs_compat.h
ocfs2.h ocfs2: further debugfs cleanups 2019-09-24 15:54:07 -07:00
ocfs2_fs.h
ocfs2_ioctl.h
ocfs2_lockid.h
ocfs2_lockingver.h
ocfs2_trace.h
quota.h
quota_global.c quota: Check that quota is not dirty before release 2019-10-31 19:07:42 +01:00
quota_local.c
refcounttree.c
refcounttree.h
reservations.c
reservations.h
resize.c
resize.h
slot_map.c
slot_map.h
stack_o2cb.c
stack_user.c
stackglue.c
stackglue.h
suballoc.c jbd2: Make state lock a spinlock 2019-10-21 09:16:46 -04:00
suballoc.h
super.c fs: Use dquot_load_quota_inode() from filesystems 2019-11-04 09:58:05 +01:00
super.h
symlink.c
symlink.h
sysfile.c
sysfile.h
uptodate.c
uptodate.h
xattr.c Revert "fs: ocfs2: fix possible null-pointer dereferences in ocfs2_xa_prepare_entry()" 2019-11-22 09:11:18 -08:00
xattr.h