* [PATCH] debugfs: remove rmdir() non-empty complaint
@ 2007-07-11 12:53 Jens Axboe
0 siblings, 0 replies; only message in thread
From: Jens Axboe @ 2007-07-11 12:53 UTC (permalink / raw)
To: linux-kernel; +Cc: greg, Linus Torvalds
Hi,
This patch kills the pointless debugfs rmdir() printk() when called on a
non-empty directory. blktrace will sometimes have to call it a few times
when forcefully ending a trace, which polutes the log with pointless
warnings.
Rationale:
- It's more code to work-around this "problem" in the debugfs users, and
you would have to add code to check for empty directories to do so (or
assume that debugfs is using simple_ helpers, but that would be a
layering violation).
- Other rmdir() implementations don't complain about something this
silly.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
diff --git a/fs/debugfs/inode.c b/fs/debugfs/inode.c
index ec8896b..8f3c999 100644
--- a/fs/debugfs/inode.c
+++ b/fs/debugfs/inode.c
@@ -345,11 +345,6 @@ void debugfs_remove(struct dentry *dentry)
switch (dentry->d_inode->i_mode & S_IFMT) {
case S_IFDIR:
ret = simple_rmdir(parent->d_inode, dentry);
- if (ret)
- printk(KERN_ERR
- "DebugFS rmdir on %s failed : "
- "directory not empty.\n",
- dentry->d_name.name);
break;
case S_IFLNK:
kfree(dentry->d_inode->i_private);
--
Jens Axboe
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2007-07-11 12:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-11 12:53 [PATCH] debugfs: remove rmdir() non-empty complaint Jens Axboe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox