Skip to content

Commit b27b281

Browse files
ubifs: Remove obsolete TODO from dfs_file_write()
AFAICT this kind of problems are no longer possible since debugfs gained file removal protection via e9117a5 ("debugfs: implement per-file removal protection"). Cc: Christoph Hellwig <hch@lst.de> Cc: Nicolai Stange <nicstange@gmail.com> Signed-off-by: Richard Weinberger <richard@nod.at>
1 parent 0997187 commit b27b281

1 file changed

Lines changed: 0 additions & 12 deletions

File tree

‎fs/ubifs/debug.c‎

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2737,18 +2737,6 @@ static ssize_t dfs_file_write(struct file *file, const char __user *u,
27372737
struct dentry *dent = file->f_path.dentry;
27382738
int val;
27392739

2740-
/*
2741-
* TODO: this is racy - the file-system might have already been
2742-
* unmounted and we'd oops in this case. The plan is to fix it with
2743-
* help of 'iterate_supers_type()' which we should have in v3.0: when
2744-
* a debugfs opened, we rember FS's UUID in file->private_data. Then
2745-
* whenever we access the FS via a debugfs file, we iterate all UBIFS
2746-
* superblocks and fine the one with the same UUID, and take the
2747-
* locking right.
2748-
*
2749-
* The other way to go suggested by Al Viro is to create a separate
2750-
* 'ubifs-debug' file-system instead.
2751-
*/
27522740
if (file->f_path.dentry == d->dfs_dump_lprops) {
27532741
ubifs_dump_lprops(c);
27542742
return count;

0 commit comments

Comments
 (0)