[media] davinci: vpbe: fix check for s_dv_preset function pointer
authorPrabhakar Lad <prabhakar.csengg@gmail.com>
Fri, 20 Jul 2012 13:00:57 +0000 (10:00 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Mon, 30 Jul 2012 23:34:13 +0000 (20:34 -0300)
fix check for s_dv_preset function pointer to be NULL.
return -EINVAL if function pointer is NULL.

Signed-off-by: Lad, Prabhakar <prabhakar.lad@ti.com>
Signed-off-by: Manjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/davinci/vpbe_display.c

index e106b72810a947f7d78b0f01681fe02c1d6d2934..f78ccc00bc4b6fa1f43cd2ae45cd0ad641784ec7 100644 (file)
@@ -1083,7 +1083,7 @@ vpbe_display_s_dv_preset(struct file *file, void *priv,
        }
 
        /* Set the given standard in the encoder */
-       if (NULL != vpbe_dev->ops.s_dv_preset)
+       if (!vpbe_dev->ops.s_dv_preset)
                return -EINVAL;
 
        ret = vpbe_dev->ops.s_dv_preset(vpbe_dev, preset);