V4L/DVB: v4l: mem2mem_testdev: fix errorenous comparison

Output buffer has to be at least the size of input buffer, not the other
way around.

Signed-off-by: Pawel Osciak <p.osciak@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
This commit is contained in:
Pawel Osciak 2010-09-10 02:02:32 -03:00 committed by Mauro Carvalho Chehab
parent 23f0cb62ba
commit b17a200f92

View File

@ -239,7 +239,7 @@ static int device_process(struct m2mtest_ctx *ctx,
return -EFAULT;
}
if (in_buf->vb.size < out_buf->vb.size) {
if (in_buf->vb.size > out_buf->vb.size) {
v4l2_err(&dev->v4l2_dev, "Output buffer is too small\n");
return -EINVAL;
}