File tree Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Expand file tree Collapse file tree 1 file changed +10
-5
lines changed Original file line number Diff line number Diff line change @@ -1176,18 +1176,23 @@ static void ext4_put_super(struct super_block *sb)
1176
1176
int aborted = 0 ;
1177
1177
int i , err ;
1178
1178
1179
- ext4_unregister_li_request (sb );
1180
- ext4_quota_off_umount (sb );
1181
-
1182
- destroy_workqueue (sbi -> rsv_conversion_wq );
1183
-
1184
1179
/*
1185
1180
* Unregister sysfs before destroying jbd2 journal.
1186
1181
* Since we could still access attr_journal_task attribute via sysfs
1187
1182
* path which could have sbi->s_journal->j_task as NULL
1183
+ * Unregister sysfs before flush sbi->s_error_work.
1184
+ * Since user may read /proc/fs/ext4/xx/mb_groups during umount, If
1185
+ * read metadata verify failed then will queue error work.
1186
+ * flush_stashed_error_work will call start_this_handle may trigger
1187
+ * BUG_ON.
1188
1188
*/
1189
1189
ext4_unregister_sysfs (sb );
1190
1190
1191
+ ext4_unregister_li_request (sb );
1192
+ ext4_quota_off_umount (sb );
1193
+
1194
+ destroy_workqueue (sbi -> rsv_conversion_wq );
1195
+
1191
1196
if (sbi -> s_journal ) {
1192
1197
aborted = is_journal_aborted (sbi -> s_journal );
1193
1198
err = jbd2_journal_destroy (sbi -> s_journal );
You can’t perform that action at this time.
0 commit comments