From 8655ce492fff8ebcc432cd841411634510ca09ac Mon Sep 17 00:00:00 2001 From: Brian Behlendorf Date: Wed, 10 Nov 2010 12:58:07 -0800 Subject: Linux 2.6.36 compat, use fops->unlocked_ioctl() As of linux-2.6.36 the last in-tree consumer of fops->ioctl() has been removed and thus fops()->ioctl() has also been removed. The replacement hook is fops->unlocked_ioctl() which has existed in kernel since 2.6.12. Since the SPL only contains support back to 2.6.18 vintage kernels, I'm not adding an autoconf check for this and simply moving everything to use fops->unlocked_ioctl(). --- module/splat/splat-ctl.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'module/splat') diff --git a/module/splat/splat-ctl.c b/module/splat/splat-ctl.c index ba68de212..de72b805f 100644 --- a/module/splat/splat-ctl.c +++ b/module/splat/splat-ctl.c @@ -445,9 +445,8 @@ splat_ioctl_cmd(struct file *file, unsigned int cmd, unsigned long arg) return rc; } -static int -splat_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) +static long +splat_unlocked_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { unsigned int minor = iminor(file->f_dentry->d_inode); int rc = 0; @@ -480,7 +479,7 @@ splat_ioctl(struct inode *inode, struct file *file, static long splat_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg) { - return splat_ioctl(NULL, file, cmd, arg); + return splat_unlocked_ioctl(file, cmd, arg); } #endif /* CONFIG_COMPAT */ @@ -601,7 +600,7 @@ static struct file_operations splat_fops = { .owner = THIS_MODULE, .open = splat_open, .release = splat_release, - .ioctl = splat_ioctl, + .unlocked_ioctl = splat_unlocked_ioctl, #ifdef CONFIG_COMPAT .compat_ioctl = splat_compat_ioctl, #endif -- cgit v1.2.3