Re: [patch] remove BKL from inode_setattr

Dave Kleikamp
2002-10-14T14:34:20Z

On Monday 14 October 2002 01:34, Andrew Morton wrote:

> --- 2.5.42/fs/jfs/file.c~truncate-bkl Sun Oct 13 21:11:06 2002
> +++ 2.5.42-akpm/fs/jfs/file.c Sun Oct 13 21:11:11 2002
> @@ -18,6 +18,7 @@
> */
>
> #include <linux/fs.h>
> +#include <linux/smp_lock.h>
> #include "jfs_incore.h"
> #include "jfs_dmap.h"
> #include "jfs_txnmgr.h"
> @@ -90,9 +91,11 @@ static void jfs_truncate(struct inode *i
> {
> jFYI(1, ("jfs_truncate: size = 0x%lx\n", (ulong) ip->i_size));
>
> + lock_kernel();
> IWRITE_LOCK(ip);
> jfs_truncate_nolock(ip, ip->i_size);
> IWRITE_UNLOCK(ip);
> + unlock_kernel();
> }
>
> static int jfs_open(struct inode *inode, struct file *file)

JFS does not need the BKL. It does it's own locking.

--
David Kleikamp
IBM Linux Technology Center