diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-24 11:01:10 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-05-24 11:01:10 -0400 |
commit | f13771187b9423b824f32518319f6da85d819003 (patch) | |
tree | c431cf16c286065a302d5f3fb43fc1abac7e4047 /drivers/macintosh | |
parent | 15953654cc312429740fd58fb37a5a3d63a54376 (diff) | |
parent | 9f37af654fda88a8dcca74c785f6c20e52758866 (diff) |
Merge branch 'bkl/ioctl' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/random-tracing
* 'bkl/ioctl' of git://git.kernel.org/pub/scm/linux/kernel/git/frederic/random-tracing:
uml: Pushdown the bkl from harddog_kern ioctl
sunrpc: Pushdown the bkl from sunrpc cache ioctl
sunrpc: Pushdown the bkl from ioctl
autofs4: Pushdown the bkl from ioctl
uml: Convert to unlocked_ioctls to remove implicit BKL
ncpfs: BKL ioctl pushdown
coda: Clean-up whitespace problems in pioctl.c
coda: BKL ioctl pushdown
drivers: Push down BKL into various drivers
isdn: Push down BKL into ioctl functions
scsi: Push down BKL into ioctl functions
dvb: Push down BKL into ioctl functions
smbfs: Push down BKL into ioctl function
coda/psdev: Remove BKL from ioctl function
um/mmapper: Remove BKL usage
sn_hwperf: Kill BKL usage
hfsplus: Push down BKL into ioctl function
Diffstat (limited to 'drivers/macintosh')
-rw-r--r-- | drivers/macintosh/nvram.c | 2 | ||||
-rw-r--r-- | drivers/macintosh/via-pmu.c | 17 |
2 files changed, 15 insertions, 4 deletions
diff --git a/drivers/macintosh/nvram.c b/drivers/macintosh/nvram.c index c876349c32d..a271c8218d8 100644 --- a/drivers/macintosh/nvram.c +++ b/drivers/macintosh/nvram.c | |||
@@ -100,7 +100,7 @@ const struct file_operations nvram_fops = { | |||
100 | .llseek = nvram_llseek, | 100 | .llseek = nvram_llseek, |
101 | .read = read_nvram, | 101 | .read = read_nvram, |
102 | .write = write_nvram, | 102 | .write = write_nvram, |
103 | .ioctl = nvram_ioctl, | 103 | .unlocked_ioctl = nvram_ioctl, |
104 | }; | 104 | }; |
105 | 105 | ||
106 | static struct miscdevice nvram_dev = { | 106 | static struct miscdevice nvram_dev = { |
diff --git a/drivers/macintosh/via-pmu.c b/drivers/macintosh/via-pmu.c index 42764849eb7..3d4fc0f7b00 100644 --- a/drivers/macintosh/via-pmu.c +++ b/drivers/macintosh/via-pmu.c | |||
@@ -2273,8 +2273,7 @@ static int register_pmu_pm_ops(void) | |||
2273 | device_initcall(register_pmu_pm_ops); | 2273 | device_initcall(register_pmu_pm_ops); |
2274 | #endif | 2274 | #endif |
2275 | 2275 | ||
2276 | static int | 2276 | static int pmu_ioctl(struct file *filp, |
2277 | pmu_ioctl(struct inode * inode, struct file *filp, | ||
2278 | u_int cmd, u_long arg) | 2277 | u_int cmd, u_long arg) |
2279 | { | 2278 | { |
2280 | __u32 __user *argp = (__u32 __user *)arg; | 2279 | __u32 __user *argp = (__u32 __user *)arg; |
@@ -2337,11 +2336,23 @@ pmu_ioctl(struct inode * inode, struct file *filp, | |||
2337 | return error; | 2336 | return error; |
2338 | } | 2337 | } |
2339 | 2338 | ||
2339 | static long pmu_unlocked_ioctl(struct file *filp, | ||
2340 | u_int cmd, u_long arg) | ||
2341 | { | ||
2342 | int ret; | ||
2343 | |||
2344 | lock_kernel(); | ||
2345 | ret = pmu_ioctl(filp, cmd, arg); | ||
2346 | unlock_kernel(); | ||
2347 | |||
2348 | return ret; | ||
2349 | } | ||
2350 | |||
2340 | static const struct file_operations pmu_device_fops = { | 2351 | static const struct file_operations pmu_device_fops = { |
2341 | .read = pmu_read, | 2352 | .read = pmu_read, |
2342 | .write = pmu_write, | 2353 | .write = pmu_write, |
2343 | .poll = pmu_fpoll, | 2354 | .poll = pmu_fpoll, |
2344 | .ioctl = pmu_ioctl, | 2355 | .unlocked_ioctl = pmu_unlocked_ioctl, |
2345 | .open = pmu_open, | 2356 | .open = pmu_open, |
2346 | .release = pmu_release, | 2357 | .release = pmu_release, |
2347 | }; | 2358 | }; |