From: Erik Gilling Date: Tue, 31 Aug 2010 01:14:14 +0000 (-0700) Subject: mfd: move cpcap to unlocked_ioctl X-Git-Tag: firefly_0821_release~9834^2~500 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=78a91fa99f0932673ca7e8cec423cbcebbb4c7da;p=firefly-linux-kernel-4.4.55.git mfd: move cpcap to unlocked_ioctl Change-Id: I2107e164e0d75f1b8e2011e4b28d312308549128 --- diff --git a/drivers/mfd/cpcap-core.c b/drivers/mfd/cpcap-core.c index fc25d84cd274..da12ce2b063e 100644 --- a/drivers/mfd/cpcap-core.c +++ b/drivers/mfd/cpcap-core.c @@ -34,8 +34,7 @@ struct cpcap_driver_info { struct platform_device *pdev; }; -static int ioctl(struct inode *inode, - struct file *file, unsigned int cmd, unsigned long arg); +static long ioctl(struct file *file, unsigned int cmd, unsigned long arg); static int __devinit cpcap_probe(struct spi_device *spi); static int __devexit cpcap_remove(struct spi_device *spi); @@ -46,7 +45,7 @@ static int cpcap_resume(struct spi_device *spi); const static struct file_operations cpcap_fops = { .owner = THIS_MODULE, - .ioctl = ioctl, + .unlocked_ioctl = ioctl, }; static struct miscdevice cpcap_dev = { @@ -358,7 +357,7 @@ static int __devexit cpcap_remove(struct spi_device *spi) } -static int test_ioctl(unsigned int cmd, unsigned long arg) +static long test_ioctl(unsigned int cmd, unsigned long arg) { int retval = -EINVAL; struct cpcap_regacc read_data; @@ -396,7 +395,7 @@ static int test_ioctl(unsigned int cmd, unsigned long arg) return retval; } -static int adc_ioctl(unsigned int cmd, unsigned long arg) +static long adc_ioctl(unsigned int cmd, unsigned long arg) { int retval = -EINVAL; struct cpcap_adc_phase phase; @@ -419,7 +418,7 @@ static int adc_ioctl(unsigned int cmd, unsigned long arg) return retval; } -static int accy_ioctl(unsigned int cmd, unsigned long arg) +static long accy_ioctl(unsigned int cmd, unsigned long arg) { int retval = -EINVAL; struct cpcap_whisper_request read_data; @@ -442,8 +441,7 @@ static int accy_ioctl(unsigned int cmd, unsigned long arg) return retval; } -static int ioctl(struct inode *inode, - struct file *file, unsigned int cmd, unsigned long arg) +static long ioctl(struct file *file, unsigned int cmd, unsigned long arg) { int retval = -ENOTTY; unsigned int cmd_num; diff --git a/drivers/mfd/cpcap-uc.c b/drivers/mfd/cpcap-uc.c index f554d0464df3..7d1113045506 100644 --- a/drivers/mfd/cpcap-uc.c +++ b/drivers/mfd/cpcap-uc.c @@ -76,8 +76,7 @@ struct cpcap_uc_data { static struct cpcap_uc_data *cpcap_uc_info; static int fops_open(struct inode *inode, struct file *file); -static int fops_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg); +static long fops_ioctl(struct file *file, unsigned int cmd, unsigned long arg); static ssize_t fops_write(struct file *file, const char *buf, size_t count, loff_t *ppos); static ssize_t fops_read(struct file *file, char *buf, @@ -86,7 +85,7 @@ static ssize_t fops_read(struct file *file, char *buf, static const struct file_operations fops = { .owner = THIS_MODULE, - .ioctl = fops_ioctl, + .unlocked_ioctl = fops_ioctl, .open = fops_open, .read = fops_read, .write = fops_write, @@ -545,8 +544,8 @@ err: return retval; } -static int fops_ioctl(struct inode *inode, struct file *file, - unsigned int cmd, unsigned long arg) +static long fops_ioctl(struct file *file, unsigned int cmd, + unsigned long arg) { int retval = -ENOTTY; struct cpcap_uc_data *data = file->private_data;