mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-30 08:02:30 +00:00
[media] V4L2: drivers implementing vidioc_default should also return -ENOTTY
If the vidioc_default implementation doesn't support the ioctl, then drivers must return -ENOTTY instead of -EINVAL. Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
parent
ee71e7b3ae
commit
d1c754a932
5 changed files with 5 additions and 5 deletions
|
@ -1137,7 +1137,7 @@ static long cx18_default(struct file *file, void *fh, bool valid_prio,
|
||||||
}
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return -EINVAL;
|
return -ENOTTY;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1761,7 +1761,7 @@ static long vpfe_param_handler(struct file *file, void *priv,
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
ret = -EINVAL;
|
ret = -ENOTTY;
|
||||||
}
|
}
|
||||||
unlock_out:
|
unlock_out:
|
||||||
mutex_unlock(&vpfe_dev->lock);
|
mutex_unlock(&vpfe_dev->lock);
|
||||||
|
|
|
@ -1827,7 +1827,7 @@ static long ivtv_default(struct file *file, void *fh, bool valid_prio,
|
||||||
return ivtv_decoder_ioctls(file, cmd, (void *)arg);
|
return ivtv_decoder_ioctls(file, cmd, (void *)arg);
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return -EINVAL;
|
return -ENOTTY;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1570,7 +1570,7 @@ static long vidioc_default(struct file *file, void *fh, bool valid_prio,
|
||||||
return meyeioc_stilljcapt((int *) arg);
|
return meyeioc_stilljcapt((int *) arg);
|
||||||
|
|
||||||
default:
|
default:
|
||||||
return -EINVAL;
|
return -ENOTTY;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -688,7 +688,7 @@ static long vidioc_default(struct file *file, void *fh, bool valid_prio,
|
||||||
/*
|
/*
|
||||||
DEB2(pr_err("does not handle this ioctl\n"));
|
DEB2(pr_err("does not handle this ioctl\n"));
|
||||||
*/
|
*/
|
||||||
return -ENOIOCTLCMD;
|
return -ENOTTY;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue