summaryrefslogtreecommitdiff
path: root/block/compat_ioctl.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2010-12-23 10:41:14 +0300
committerGrant Likely <grant.likely@secretlab.ca>2010-12-23 10:41:14 +0300
commitcfb13c5db08c90311a5defdde9a0328ee788cca5 (patch)
tree842cb60d1d19b99e550fdbc653723e4b13e51ee5 /block/compat_ioctl.c
parent4b6ba8aacbb3185703b797286547d0f8f3859b02 (diff)
parent90a8a73c06cc32b609a880d48449d7083327e11a (diff)
downloadlinux-cfb13c5db08c90311a5defdde9a0328ee788cca5.tar.xz
Merge commit 'v2.6.37-rc7' into devicetree/next
Diffstat (limited to 'block/compat_ioctl.c')
-rw-r--r--block/compat_ioctl.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/block/compat_ioctl.c b/block/compat_ioctl.c
index 119f07b74dc0..cc3eb78e333a 100644
--- a/block/compat_ioctl.c
+++ b/block/compat_ioctl.c
@@ -8,7 +8,6 @@
#include <linux/hdreg.h>
#include <linux/slab.h>
#include <linux/syscalls.h>
-#include <linux/smp_lock.h>
#include <linux/types.h>
#include <linux/uaccess.h>
@@ -744,13 +743,13 @@ long compat_blkdev_ioctl(struct file *file, unsigned cmd, unsigned long arg)
bdi->ra_pages = (arg * 512) / PAGE_CACHE_SIZE;
return 0;
case BLKGETSIZE:
- size = bdev->bd_inode->i_size;
+ size = i_size_read(bdev->bd_inode);
if ((size >> 9) > ~0UL)
return -EFBIG;
return compat_put_ulong(arg, size >> 9);
case BLKGETSIZE64_32:
- return compat_put_u64(arg, bdev->bd_inode->i_size);
+ return compat_put_u64(arg, i_size_read(bdev->bd_inode));
case BLKTRACESETUP32:
case BLKTRACESTART: /* compatible */