[media] tlg2300: index is unsigned, so never below zero

drivers/media/usb/tlg2300/pd-video.c:891:2: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits]
drivers/media/usb/tlg2300/pd-video.c:926:2: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits]

Cc: Huang Shijie <shijie8@gmail.com>
Cc: Kang Yong <kangyong@telegent.com>
Cc: Zhang Xiaobing <xbzhang@telegent.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
Mauro Carvalho Chehab 2012-10-27 16:23:03 -03:00
Родитель 2869a318ce
Коммит 1ab9058702
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -888,7 +888,7 @@ static int vidioc_enum_input(struct file *file, void *fh, struct v4l2_input *in)
{ {
struct front_face *front = fh; struct front_face *front = fh;
if (in->index < 0 || in->index >= POSEIDON_INPUTS) if (in->index >= POSEIDON_INPUTS)
return -EINVAL; return -EINVAL;
strcpy(in->name, pd_inputs[in->index].name); strcpy(in->name, pd_inputs[in->index].name);
in->type = V4L2_INPUT_TYPE_TUNER; in->type = V4L2_INPUT_TYPE_TUNER;
@ -923,7 +923,7 @@ static int vidioc_s_input(struct file *file, void *fh, unsigned int i)
struct poseidon *pd = front->pd; struct poseidon *pd = front->pd;
s32 ret, cmd_status; s32 ret, cmd_status;
if (i < 0 || i >= POSEIDON_INPUTS) if (i >= POSEIDON_INPUTS)
return -EINVAL; return -EINVAL;
ret = send_set_req(pd, SGNL_SRC_SEL, ret = send_set_req(pd, SGNL_SRC_SEL,
pd_inputs[i].tlg_src, &cmd_status); pd_inputs[i].tlg_src, &cmd_status);