Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 117556
b: refs/heads/master
c: 6af3a56
h: refs/heads/master
v: v3
  • Loading branch information
Al Viro authored and Al Viro committed Oct 21, 2008
1 parent 7f5a1e2 commit 67a9885
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 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: 45048d0961cdbf7ddfba906797ad8cb42489e070
refs/heads/master: 6af3a56e1dd4d95836a47214e5c60d5b749a5501
5 changes: 3 additions & 2 deletions trunk/block/ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -343,10 +343,11 @@ int blkdev_ioctl(struct inode *inode, struct file *file, unsigned cmd,
return -EINVAL;
if (get_user(n, (int __user *) arg))
return -EFAULT;
if (bd_claim(bdev, file) < 0)
if (!(mode & FMODE_EXCL) && bd_claim(bdev, &bdev) < 0)
return -EBUSY;
ret = set_blocksize(bdev, n);
bd_release(bdev);
if (!(mode & FMODE_EXCL))
bd_release(bdev);
return ret;
case BLKPG:
lock_kernel();
Expand Down

0 comments on commit 67a9885

Please sign in to comment.