File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -184,7 +184,15 @@ static int remove_save_link_only(struct super_block *s,
184
184
static int reiserfs_quota_on_mount (struct super_block * , int );
185
185
#endif
186
186
187
- /* look for uncompleted unlinks and truncates and complete them */
187
+ /*
188
+ * Look for uncompleted unlinks and truncates and complete them
189
+ *
190
+ * Called with superblock write locked. If quotas are enabled, we have to
191
+ * release/retake lest we call dquot_quota_on_mount(), proceed to
192
+ * schedule_on_each_cpu() in invalidate_bdev() and deadlock waiting for the per
193
+ * cpu worklets to complete flush_async_commits() that in turn wait for the
194
+ * superblock write lock.
195
+ */
188
196
static int finish_unfinished (struct super_block * s )
189
197
{
190
198
INITIALIZE_PATH (path );
@@ -231,7 +239,9 @@ static int finish_unfinished(struct super_block *s)
231
239
quota_enabled [i ] = 0 ;
232
240
continue ;
233
241
}
242
+ reiserfs_write_unlock (s );
234
243
ret = reiserfs_quota_on_mount (s , i );
244
+ reiserfs_write_lock (s );
235
245
if (ret < 0 )
236
246
reiserfs_warning (s , "reiserfs-2500" ,
237
247
"cannot turn on journaled "
You can’t perform that action at this time.
0 commit comments