Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 79f14b7c authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'vfs' of git://git.kernel.org/pub/scm/linux/kernel/git/arnd/bkl: (30 commits)
  BKL: remove BKL from freevxfs
  BKL: remove BKL from qnx4
  autofs4: Only declare function when CONFIG_COMPAT is defined
  autofs: Only declare function when CONFIG_COMPAT is defined
  ncpfs: Lock socket in ncpfs while setting its callbacks
  fs/locks.c: prepare for BKL removal
  BKL: Remove BKL from ncpfs
  BKL: Remove BKL from OCFS2
  BKL: Remove BKL from squashfs
  BKL: Remove BKL from jffs2
  BKL: Remove BKL from ecryptfs
  BKL: Remove BKL from afs
  BKL: Remove BKL from USB gadgetfs
  BKL: Remove BKL from autofs4
  BKL: Remove BKL from isofs
  BKL: Remove BKL from fat
  BKL: Remove BKL from ext2 filesystem
  BKL: Remove BKL from do_new_mount()
  BKL: Remove BKL from cgroup
  BKL: Remove BKL from NTFS
  ...
parents c37927d4 6d7bccc2
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -33,7 +33,6 @@
#include <linux/sched.h>
#include <linux/slab.h>
#include <linux/poll.h>
#include <linux/smp_lock.h>

#include <linux/device.h>
#include <linux/moduleparam.h>
+7 −1
Original line number Diff line number Diff line
@@ -352,11 +352,15 @@ static int adfs_fill_super(struct super_block *sb, void *data, int silent)
	struct adfs_sb_info *asb;
	struct inode *root;

	lock_kernel();

	sb->s_flags |= MS_NODIRATIME;

	asb = kzalloc(sizeof(*asb), GFP_KERNEL);
	if (!asb)
	if (!asb) {
		unlock_kernel();
		return -ENOMEM;
	}
	sb->s_fs_info = asb;

	/* set default options */
@@ -474,6 +478,7 @@ static int adfs_fill_super(struct super_block *sb, void *data, int silent)
		goto error;
	} else
		sb->s_root->d_op = &adfs_dentry_operations;
	unlock_kernel();
	return 0;

error_free_bh:
@@ -481,6 +486,7 @@ static int adfs_fill_super(struct super_block *sb, void *data, int silent)
error:
	sb->s_fs_info = NULL;
	kfree(asb);
	unlock_kernel();
	return -EINVAL;
}

+4 −10
Original line number Diff line number Diff line
@@ -16,7 +16,6 @@
#include <linux/parser.h>
#include <linux/magic.h>
#include <linux/sched.h>
#include <linux/smp_lock.h>
#include <linux/slab.h>
#include "affs.h"

@@ -46,8 +45,6 @@ affs_put_super(struct super_block *sb)
	struct affs_sb_info *sbi = AFFS_SB(sb);
	pr_debug("AFFS: put_super()\n");

	lock_kernel();

	if (!(sb->s_flags & MS_RDONLY) && sb->s_dirt)
		affs_commit_super(sb, 1, 1);

@@ -56,8 +53,6 @@ affs_put_super(struct super_block *sb)
	affs_brelse(sbi->s_root_bh);
	kfree(sbi);
	sb->s_fs_info = NULL;

	unlock_kernel();
}

static void
@@ -302,6 +297,7 @@ static int affs_fill_super(struct super_block *sb, void *data, int silent)
	sbi = kzalloc(sizeof(struct affs_sb_info), GFP_KERNEL);
	if (!sbi)
		return -ENOMEM;

	sb->s_fs_info = sbi;
	mutex_init(&sbi->s_bmlock);
	spin_lock_init(&sbi->symlink_lock);
@@ -527,7 +523,7 @@ affs_remount(struct super_block *sb, int *flags, char *data)
		kfree(new_opts);
		return -EINVAL;
	}
	lock_kernel();

	replace_mount_options(sb, new_opts);

	sbi->s_flags = mount_flags;
@@ -543,17 +539,15 @@ affs_remount(struct super_block *sb, int *flags, char *data)
	memcpy(sbi->s_volume, volume, 32);
	spin_unlock(&sbi->symlink_lock);

	if ((*flags & MS_RDONLY) == (sb->s_flags & MS_RDONLY)) {
		unlock_kernel();
	if ((*flags & MS_RDONLY) == (sb->s_flags & MS_RDONLY))
		return 0;
	}

	if (*flags & MS_RDONLY) {
		affs_write_super(sb);
		affs_free_bitmap(sb);
	} else
		res = affs_init_bitmap(sb, flags);

	unlock_kernel();
	return res;
}

+2 −3
Original line number Diff line number Diff line
@@ -9,7 +9,6 @@
 * 2 of the License, or (at your option) any later version.
 */

#include <linux/smp_lock.h>
#include "internal.h"

#define AFS_LOCK_GRANTED	0
@@ -274,7 +273,7 @@ static int afs_do_setlk(struct file *file, struct file_lock *fl)

	type = (fl->fl_type == F_RDLCK) ? AFS_LOCK_READ : AFS_LOCK_WRITE;

	lock_kernel();
	lock_flocks();

	/* make sure we've got a callback on this file and that our view of the
	 * data version is up to date */
@@ -421,7 +420,7 @@ static int afs_do_setlk(struct file *file, struct file_lock *fl)
	afs_vnode_fetch_status(vnode, NULL, key);

error:
	unlock_kernel();
	unlock_flocks();
	_leave(" = %d", ret);
	return ret;

+0 −5
Original line number Diff line number Diff line
@@ -19,7 +19,6 @@
#include <linux/mount.h>
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/smp_lock.h>
#include <linux/fs.h>
#include <linux/pagemap.h>
#include <linux/parser.h>
@@ -453,12 +452,8 @@ static void afs_put_super(struct super_block *sb)

	_enter("");

	lock_kernel();

	afs_put_volume(as->volume);

	unlock_kernel();

	_leave("");
}

Loading