Also fix the unknown ioctl return code
Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-static int auerchar_ioctl (struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg)
+static long auerchar_ioctl(struct file *file, unsigned int cmd,
+ unsigned long arg)
{
pauerchar_t ccp = (pauerchar_t) file->private_data;
int ret = 0;
{
pauerchar_t ccp = (pauerchar_t) file->private_data;
int ret = 0;
mutex_unlock(&ccp->mutex);
return -ENODEV;
}
mutex_unlock(&ccp->mutex);
return -ENODEV;
}
switch (cmd) {
/* return != 0 if Transmitt channel ready to send */
switch (cmd) {
/* return != 0 if Transmitt channel ready to send */
default:
dbg ("IOCTL_AU_UNKNOWN");
default:
dbg ("IOCTL_AU_UNKNOWN");
/* release the mutexes */
mutex_unlock(&cp->mutex);
mutex_unlock(&ccp->mutex);
/* release the mutexes */
mutex_unlock(&cp->mutex);
mutex_unlock(&ccp->mutex);
.llseek = no_llseek,
.read = auerchar_read,
.write = auerchar_write,
.llseek = no_llseek,
.read = auerchar_read,
.write = auerchar_write,
- .ioctl = auerchar_ioctl,
+ .unlocked_ioctl = auerchar_ioctl,
.open = auerchar_open,
.release = auerchar_release,
};
.open = auerchar_open,
.release = auerchar_release,
};