staging: atomisp: remove redudant condition in if-statement
authorDaeseok Youn <daeseok.youn@gmail.com>
Mon, 20 Mar 2017 14:42:23 +0000 (14:42 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 21 Mar 2017 07:04:33 +0000 (08:04 +0100)
The V4L2_FIELD_ANY is zero, so the (!field) is same meaning
with (field == V4L2_FIELD_ANY) in if-statement.

Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/media/atomisp/pci/atomisp2/atomisp_cmd.c

index 036413b68390e84720825f9b9349d5ee696587d5..0a2df3dc9bcdb3de58d2562c9dd45f143d2417fe 100644 (file)
@@ -5081,7 +5081,7 @@ atomisp_try_fmt_file(struct atomisp_device *isp, struct v4l2_format *f)
 
        depth = get_pixel_depth(pixelformat);
 
-       if (!field || field == V4L2_FIELD_ANY)
+       if (field == V4L2_FIELD_ANY)
                field = V4L2_FIELD_NONE;
        else if (field != V4L2_FIELD_NONE) {
                dev_err(isp->dev, "Wrong output field\n");