Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 212916
b: refs/heads/master
c: cfdb00a
h: refs/heads/master
v: v3
  • Loading branch information
Arnd Bergmann committed Sep 26, 2010
1 parent 871d029 commit 12d45ba
Show file tree
Hide file tree
Showing 4 changed files with 3 additions and 27 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 54066a57c584ee8ce767053116fc4943ed1168b5
refs/heads/master: cfdb00a77ea7d5fb922fd985e5dfbcb36873411b
6 changes: 0 additions & 6 deletions trunk/drivers/s390/block/dasd.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@
#include <linux/hdreg.h>
#include <linux/async.h>
#include <linux/mutex.h>
#include <linux/smp_lock.h>

#include <asm/ccwdev.h>
#include <asm/ebcdic.h>
Expand Down Expand Up @@ -2236,7 +2235,6 @@ static int dasd_open(struct block_device *bdev, fmode_t mode)
if (!block)
return -ENODEV;

lock_kernel();
base = block->base;
atomic_inc(&block->open_count);
if (test_bit(DASD_FLAG_OFFLINE, &base->flags)) {
Expand Down Expand Up @@ -2271,25 +2269,21 @@ static int dasd_open(struct block_device *bdev, fmode_t mode)
goto out;
}

unlock_kernel();
return 0;

out:
module_put(base->discipline->owner);
unlock:
atomic_dec(&block->open_count);
unlock_kernel();
return rc;
}

static int dasd_release(struct gendisk *disk, fmode_t mode)
{
struct dasd_block *block = disk->private_data;

lock_kernel();
atomic_dec(&block->open_count);
module_put(block->base->discipline->owner);
unlock_kernel();
return 0;
}

Expand Down
17 changes: 2 additions & 15 deletions trunk/drivers/s390/block/dasd_ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <linux/major.h>
#include <linux/fs.h>
#include <linux/blkpg.h>
#include <linux/smp_lock.h>
#include <linux/slab.h>
#include <asm/compat.h>
#include <asm/ccwdev.h>
Expand Down Expand Up @@ -370,9 +369,8 @@ static int dasd_ioctl_readall_cmb(struct dasd_block *block, unsigned int cmd,
return ret;
}

static int
dasd_do_ioctl(struct block_device *bdev, fmode_t mode,
unsigned int cmd, unsigned long arg)
int dasd_ioctl(struct block_device *bdev, fmode_t mode,
unsigned int cmd, unsigned long arg)
{
struct dasd_block *block = bdev->bd_disk->private_data;
void __user *argp;
Expand Down Expand Up @@ -430,14 +428,3 @@ dasd_do_ioctl(struct block_device *bdev, fmode_t mode,
return -EINVAL;
}
}

int dasd_ioctl(struct block_device *bdev, fmode_t mode,
unsigned int cmd, unsigned long arg)
{
int rc;

lock_kernel();
rc = dasd_do_ioctl(bdev, mode, cmd, arg);
unlock_kernel();
return rc;
}
5 changes: 0 additions & 5 deletions trunk/drivers/s390/block/dcssblk.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#include <linux/init.h>
#include <linux/slab.h>
#include <linux/blkdev.h>
#include <linux/smp_lock.h>
#include <linux/completion.h>
#include <linux/interrupt.h>
#include <linux/platform_device.h>
Expand Down Expand Up @@ -776,7 +775,6 @@ dcssblk_open(struct block_device *bdev, fmode_t mode)
struct dcssblk_dev_info *dev_info;
int rc;

lock_kernel();
dev_info = bdev->bd_disk->private_data;
if (NULL == dev_info) {
rc = -ENODEV;
Expand All @@ -786,7 +784,6 @@ dcssblk_open(struct block_device *bdev, fmode_t mode)
bdev->bd_block_size = 4096;
rc = 0;
out:
unlock_kernel();
return rc;
}

Expand All @@ -797,7 +794,6 @@ dcssblk_release(struct gendisk *disk, fmode_t mode)
struct segment_info *entry;
int rc;

lock_kernel();
if (!dev_info) {
rc = -ENODEV;
goto out;
Expand All @@ -815,7 +811,6 @@ dcssblk_release(struct gendisk *disk, fmode_t mode)
up_write(&dcssblk_devices_sem);
rc = 0;
out:
unlock_kernel();
return rc;
}

Expand Down

0 comments on commit 12d45ba

Please sign in to comment.