Yi Li
0d3ad773b4
ocfs2: fix panic due to ocfs2_wq is null
commit b918c43021 upstream.
mount.ocfs2 failed when reading ocfs2 filesystem superblock encounters
an error. ocfs2_initialize_super() returns before allocating ocfs2_wq.
ocfs2_dismount_volume() triggers the following panic.
Oct 15 16:09:27 cnwarekv-205120 kernel: On-disk corruption discovered.Please run fsck.ocfs2 once the filesystem is unmounted.
Oct 15 16:09:27 cnwarekv-205120 kernel: (mount.ocfs2,22804,44): ocfs2_read_locked_inode:537 ERROR: status = -30
Oct 15 16:09:27 cnwarekv-205120 kernel: (mount.ocfs2,22804,44): ocfs2_init_global_system_inodes:458 ERROR: status = -30
Oct 15 16:09:27 cnwarekv-205120 kernel: (mount.ocfs2,22804,44): ocfs2_init_global_system_inodes:491 ERROR: status = -30
Oct 15 16:09:27 cnwarekv-205120 kernel: (mount.ocfs2,22804,44): ocfs2_initialize_super:2313 ERROR: status = -30
Oct 15 16:09:27 cnwarekv-205120 kernel: (mount.ocfs2,22804,44): ocfs2_fill_super:1033 ERROR: status = -30
------------[ cut here ]------------
Oops: 0002 [#1] SMP NOPTI
CPU: 1 PID: 11753 Comm: mount.ocfs2 Tainted: G E
4.14.148-200.ckv.x86_64 #1
Hardware name: Sugon H320-G30/35N16-US, BIOS 0SSDX017 12/21/2018
task: ffff967af0520000 task.stack: ffffa5f05484000
RIP: 0010:mutex_lock+0x19/0x20
Call Trace:
flush_workqueue+0x81/0x460
ocfs2_shutdown_local_alloc+0x47/0x440 [ocfs2]
ocfs2_dismount_volume+0x84/0x400 [ocfs2]
ocfs2_fill_super+0xa4/0x1270 [ocfs2]
? ocfs2_initialize_super.isa.211+0xf20/0xf20 [ocfs2]
mount_bdev+0x17f/0x1c0
mount_fs+0x3a/0x160
Link: http://lkml.kernel.org/r/1571139611-24107-1-git-send-email-yili@winhong.com
Signed-off-by: Yi Li <yilikernel@gmail.com>
Reviewed-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>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-10-29 09:19:38 +01:00
..
2019-10-11 18:21:13 +02:00
2019-08-06 19:06:49 +02:00
2019-09-10 10:33:52 +01:00
2019-03-13 14:02:32 -07:00
2018-06-15 18:10:01 -03:00
2018-12-01 09:37:27 +01:00
2019-10-17 13:45:27 -07:00
2018-12-17 09:24:40 +01:00
2019-10-11 18:21:15 +02:00
2019-10-17 13:45:24 -07:00
2019-08-06 19:06:51 +02:00
2019-06-22 08:15:17 +02:00
2018-11-13 11:08:55 -08:00
2019-07-26 09:14:02 +02:00
2019-05-08 07:21:48 +02:00
2019-03-23 20:09:59 +01:00
2019-07-31 07:27:07 +02:00
2019-07-26 09:14:29 +02:00
2018-07-22 14:13:44 +02:00
2018-11-27 16:13:00 +01:00
2018-12-17 09:24:35 +01:00
2019-03-23 20:10:03 +01:00
2019-10-07 18:57:05 +02:00
2019-10-17 13:44:47 -07:00
2019-10-07 18:57:14 +02:00
2018-12-17 09:24:40 +01:00
2019-10-11 18:21:20 +02:00
2019-10-05 13:10:07 +02:00
2018-12-17 09:24:41 +01:00
2018-12-17 09:24:41 +01:00
2018-08-17 16:20:28 -07:00
2018-08-25 12:42:33 -07:00
2019-05-22 07:37:40 +02:00
2018-08-21 11:37:41 +02:00
2019-07-28 08:29:29 +02:00
2019-05-08 07:21:48 +02:00
2018-08-15 22:47:23 -07:00
2019-05-16 19:41:18 +02:00
2019-06-09 09:17:22 +02:00
2019-10-17 13:45:30 -07:00
2019-07-10 09:53:47 +02:00
2018-09-04 16:45:02 -07:00
2019-07-31 07:27:08 +02:00
2018-08-17 16:20:27 -07:00
2019-10-29 09:19:38 +01:00
2018-08-14 12:07:14 -04:00
2019-10-05 13:10:08 +02:00
2019-08-04 09:30:56 +02:00
2019-10-07 18:56:59 +02:00
2019-07-14 08:11:15 +02:00
2018-11-27 16:12:59 +01:00
2018-08-02 09:34:02 -07:00
2018-08-18 11:44:53 -07:00
2018-12-17 09:24:30 +01:00
2018-07-31 11:32:44 -04:00
2019-09-19 09:09:37 +02:00
2019-07-14 08:11:16 +02:00
2019-05-25 18:23:46 +02:00
2019-10-01 08:26:12 +02:00
2019-05-02 09:58:59 +02:00
2018-07-12 10:04:27 -04:00
2018-07-03 16:44:45 -04:00
2018-07-12 10:04:20 -04:00
2018-06-12 16:19:22 -07:00
2019-10-05 13:10:06 +02:00
2019-07-03 13:14:44 +02:00
2018-07-10 23:29:03 -04:00
2019-02-15 09:09:54 +01:00
2019-04-17 08:38:52 +02:00
2019-04-05 22:33:00 +02:00
2019-05-31 06:46:27 -07:00
2019-08-09 17:52:34 +02:00
2018-06-05 19:23:26 +02:00
2019-08-16 10:12:52 +02:00
2019-05-25 18:23:26 +02:00
2019-03-05 17:58:50 +01:00
2019-03-13 14:02:32 -07:00
2018-06-28 10:40:47 -07:00
2019-02-12 19:47:19 +01:00
2019-08-04 09:30:56 +02:00
2018-08-15 23:03:20 -05:00
2018-08-21 18:19:09 -07:00
2019-04-05 22:32:59 +02:00
2019-07-26 09:14:08 +02:00
2019-06-22 08:15:21 +02:00
2019-05-31 06:46:05 -07:00
2018-11-21 09:19:14 +01:00
2019-03-13 14:02:29 -07:00
2018-06-11 08:22:34 -07:00
2018-08-02 08:06:55 +09:00
2019-10-17 13:45:35 -07:00
2018-08-21 18:19:09 -07:00
2018-06-11 08:22:34 -07:00
2018-06-12 16:19:22 -07:00
2018-08-17 16:20:29 -07:00
2018-12-29 13:37:54 +01:00
2018-11-21 09:19:22 +01:00
2019-05-25 18:23:26 +02:00
2019-07-31 07:27:11 +02:00
2019-05-04 09:20:11 +02:00
2019-09-10 10:33:47 +01:00
2018-06-28 10:40:47 -07:00
2019-08-25 10:47:43 +02:00
2018-06-16 16:21:50 +09:00
2019-05-04 09:20:11 +02:00
2019-10-11 18:21:39 +02:00
2018-08-26 11:48:42 -07:00
2018-08-13 20:56:23 -07:00
2019-08-29 08:28:52 +02:00
2018-09-18 07:30:48 -04:00