* [PATCH] nilfs2: remove BKL uses
@ 2010-07-04 5:22 Ryusuke Konishi
2010-07-05 14:50 ` Arnd Bergmann
0 siblings, 1 reply; 4+ messages in thread
From: Ryusuke Konishi @ 2010-07-04 5:22 UTC (permalink / raw)
To: linux-nilfs; +Cc: Ryusuke Konishi, Arnd Bergmann, linux-kernel, linux-fsdevel
Nilfs has BKL uses in its put_super and remount functions, but none of
them are necessary, just came from earlier push downs. This
eliminates the BKL uses from nilfs.
Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
---
fs/nilfs2/ioctl.c | 1 -
fs/nilfs2/super.c | 9 ---------
2 files changed, 0 insertions(+), 10 deletions(-)
diff --git a/fs/nilfs2/ioctl.c b/fs/nilfs2/ioctl.c
index f90a33d..0442ee3 100644
--- a/fs/nilfs2/ioctl.c
+++ b/fs/nilfs2/ioctl.c
@@ -22,7 +22,6 @@
#include <linux/fs.h>
#include <linux/wait.h>
-#include <linux/smp_lock.h> /* lock_kernel(), unlock_kernel() */
#include <linux/slab.h>
#include <linux/capability.h> /* capable() */
#include <linux/uaccess.h> /* copy_from_user(), copy_to_user() */
diff --git a/fs/nilfs2/super.c b/fs/nilfs2/super.c
index f2cfbba..29be735 100644
--- a/fs/nilfs2/super.c
+++ b/fs/nilfs2/super.c
@@ -45,7 +45,6 @@
#include <linux/parser.h>
#include <linux/random.h>
#include <linux/crc32.h>
-#include <linux/smp_lock.h>
#include <linux/vfs.h>
#include <linux/writeback.h>
#include <linux/kobject.h>
@@ -357,8 +356,6 @@ static void nilfs_put_super(struct super_block *sb)
struct nilfs_sb_info *sbi = NILFS_SB(sb);
struct the_nilfs *nilfs = sbi->s_nilfs;
- lock_kernel();
-
nilfs_detach_segment_constructor(sbi);
if (!(sb->s_flags & MS_RDONLY)) {
@@ -376,8 +373,6 @@ static void nilfs_put_super(struct super_block *sb)
sbi->s_super = NULL;
sb->s_fs_info = NULL;
nilfs_put_sbinfo(sbi);
-
- unlock_kernel();
}
static int nilfs_sync_fs(struct super_block *sb, int wait)
@@ -913,8 +908,6 @@ static int nilfs_remount(struct super_block *sb, int *flags, char *data)
struct nilfs_mount_options old_opts;
int was_snapshot, err;
- lock_kernel();
-
down_write(&nilfs->ns_super_sem);
old_sb_flags = sb->s_flags;
old_opts.mount_opt = sbi->s_mount_opt;
@@ -988,7 +981,6 @@ static int nilfs_remount(struct super_block *sb, int *flags, char *data)
}
out:
up_write(&nilfs->ns_super_sem);
- unlock_kernel();
return 0;
restore_opts:
@@ -996,7 +988,6 @@ static int nilfs_remount(struct super_block *sb, int *flags, char *data)
sbi->s_mount_opt = old_opts.mount_opt;
sbi->s_snapshot_cno = old_opts.snapshot_cno;
up_write(&nilfs->ns_super_sem);
- unlock_kernel();
return err;
}
--
1.6.6.2
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] nilfs2: remove BKL uses
2010-07-04 5:22 [PATCH] nilfs2: remove BKL uses Ryusuke Konishi
@ 2010-07-05 14:50 ` Arnd Bergmann
2010-07-05 14:53 ` Frederic Weisbecker
0 siblings, 1 reply; 4+ messages in thread
From: Arnd Bergmann @ 2010-07-05 14:50 UTC (permalink / raw)
To: Ryusuke Konishi; +Cc: linux-nilfs, linux-kernel, linux-fsdevel, Jan Blunck
On Sunday 04 July 2010, Ryusuke Konishi wrote:
> Nilfs has BKL uses in its put_super and remount functions, but none of
> them are necessary, just came from earlier push downs. This
> eliminates the BKL uses from nilfs.
>
> Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
This looks good, but there is a another patch series pushing the BKL
into the get_sb and fill_super operations, which should be the final
pushdown for file systems. I wonder if there is a way to find a
shortcut on this so we don't need to add it first just to have you
go through the effort of removing it again.
Arnd
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] nilfs2: remove BKL uses
2010-07-05 14:50 ` Arnd Bergmann
@ 2010-07-05 14:53 ` Frederic Weisbecker
2010-07-05 17:55 ` Ryusuke Konishi
0 siblings, 1 reply; 4+ messages in thread
From: Frederic Weisbecker @ 2010-07-05 14:53 UTC (permalink / raw)
To: Arnd Bergmann
Cc: Ryusuke Konishi, linux-nilfs, linux-kernel, linux-fsdevel,
Jan Blunck
On Mon, Jul 05, 2010 at 04:50:23PM +0200, Arnd Bergmann wrote:
> On Sunday 04 July 2010, Ryusuke Konishi wrote:
> > Nilfs has BKL uses in its put_super and remount functions, but none of
> > them are necessary, just came from earlier push downs. This
> > eliminates the BKL uses from nilfs.
> >
> > Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
>
> This looks good, but there is a another patch series pushing the BKL
> into the get_sb and fill_super operations, which should be the final
> pushdown for file systems. I wonder if there is a way to find a
> shortcut on this so we don't need to add it first just to have you
> go through the effort of removing it again.
I could take his patch in the mount pushdown series.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] nilfs2: remove BKL uses
2010-07-05 14:53 ` Frederic Weisbecker
@ 2010-07-05 17:55 ` Ryusuke Konishi
0 siblings, 0 replies; 4+ messages in thread
From: Ryusuke Konishi @ 2010-07-05 17:55 UTC (permalink / raw)
To: fweisbec
Cc: arnd, konishi.ryusuke, linux-nilfs, linux-kernel, linux-fsdevel,
jblunck
On Mon, 5 Jul 2010 16:53:29 +0200, Frederic Weisbecker wrote:
> On Mon, Jul 05, 2010 at 04:50:23PM +0200, Arnd Bergmann wrote:
> > On Sunday 04 July 2010, Ryusuke Konishi wrote:
> > > Nilfs has BKL uses in its put_super and remount functions, but none of
> > > them are necessary, just came from earlier push downs. This
> > > eliminates the BKL uses from nilfs.
> > >
> > > Signed-off-by: Ryusuke Konishi <konishi.ryusuke@lab.ntt.co.jp>
> >
> > This looks good, but there is a another patch series pushing the BKL
> > into the get_sb and fill_super operations, which should be the final
> > pushdown for file systems. I wonder if there is a way to find a
> > shortcut on this so we don't need to add it first just to have you
> > go through the effort of removing it again.
>
>
> I could take his patch in the mount pushdown series.
OK, please treat this patch as needed.
I've forgotten the additional BKL push down patch and Jan's BKL
removal patch on nilfs, but yes, it looks omissible to add BKL and
remove it again there.
For now, I will drop my patch from my tree.
Thanks,
Ryusuke Konishi
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-07-05 17:55 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-07-04 5:22 [PATCH] nilfs2: remove BKL uses Ryusuke Konishi
2010-07-05 14:50 ` Arnd Bergmann
2010-07-05 14:53 ` Frederic Weisbecker
2010-07-05 17:55 ` Ryusuke Konishi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox