Merge branch 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mjg59/platf...
[sfrench/cifs-2.6.git] / drivers / media / video / mem2mem_testdev.c
index 554eaf140128dd4abdb7fe033305a3f388ada55b..4525335f9bd416388484cbc5872ea0db3c3af768 100644 (file)
@@ -903,14 +903,14 @@ static int m2mtest_release(struct file *file)
 static unsigned int m2mtest_poll(struct file *file,
                                 struct poll_table_struct *wait)
 {
-       struct m2mtest_ctx *ctx = (struct m2mtest_ctx *)file->private_data;
+       struct m2mtest_ctx *ctx = file->private_data;
 
        return v4l2_m2m_poll(file, ctx->m2m_ctx, wait);
 }
 
 static int m2mtest_mmap(struct file *file, struct vm_area_struct *vma)
 {
-       struct m2mtest_ctx *ctx = (struct m2mtest_ctx *)file->private_data;
+       struct m2mtest_ctx *ctx = file->private_data;
 
        return v4l2_m2m_mmap(file, ctx->m2m_ctx, vma);
 }
@@ -988,6 +988,9 @@ static int m2mtest_probe(struct platform_device *pdev)
                goto err_m2m;
        }
 
+       q_data[V4L2_M2M_SRC].fmt = &formats[0];
+       q_data[V4L2_M2M_DST].fmt = &formats[0];
+
        return 0;
 
 err_m2m: