Re: [REVIEWv2 PATCH 04/19] bttv: remove g/s_audio since there is only one audio input.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hmm... G/S_AUDIO is also used to query/set the capabilities and the mode
of an input, which IMHO makes sense even if the input is the only one
the device has ?
Don't you think that it's also somehow inconsistent, because for the
video inputs (G/S_INPUT) the spec says:
"This ioctl will fail only when there are no video inputs, returning
EINVAL." ?


Regards,
Frank



Am 10.02.2013 13:49, schrieb Hans Verkuil:
> From: Hans Verkuil <hans.verkuil@xxxxxxxxx>
>
> Signed-off-by: Hans Verkuil <hans.verkuil@xxxxxxxxx>
> ---
>  drivers/media/pci/bt8xx/bttv-driver.c |   19 -------------------
>  1 file changed, 19 deletions(-)
>
> diff --git a/drivers/media/pci/bt8xx/bttv-driver.c b/drivers/media/pci/bt8xx/bttv-driver.c
> index 6e61dbd..a02c031 100644
> --- a/drivers/media/pci/bt8xx/bttv-driver.c
> +++ b/drivers/media/pci/bt8xx/bttv-driver.c
> @@ -3138,23 +3138,6 @@ static int bttv_s_crop(struct file *file, void *f, const struct v4l2_crop *crop)
>  	return 0;
>  }
>  
> -static int bttv_g_audio(struct file *file, void *priv, struct v4l2_audio *a)
> -{
> -	if (unlikely(a->index))
> -		return -EINVAL;
> -
> -	strcpy(a->name, "audio");
> -	return 0;
> -}
> -
> -static int bttv_s_audio(struct file *file, void *priv, const struct v4l2_audio *a)
> -{
> -	if (unlikely(a->index))
> -		return -EINVAL;
> -
> -	return 0;
> -}
> -
>  static ssize_t bttv_read(struct file *file, char __user *data,
>  			 size_t count, loff_t *ppos)
>  {
> @@ -3390,8 +3373,6 @@ static const struct v4l2_ioctl_ops bttv_ioctl_ops = {
>  	.vidioc_g_fmt_vbi_cap           = bttv_g_fmt_vbi_cap,
>  	.vidioc_try_fmt_vbi_cap         = bttv_try_fmt_vbi_cap,
>  	.vidioc_s_fmt_vbi_cap           = bttv_s_fmt_vbi_cap,
> -	.vidioc_g_audio                 = bttv_g_audio,
> -	.vidioc_s_audio                 = bttv_s_audio,
>  	.vidioc_cropcap                 = bttv_cropcap,
>  	.vidioc_reqbufs                 = bttv_reqbufs,
>  	.vidioc_querybuf                = bttv_querybuf,

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux