MLK-20209 hdmi rx: fixed unsigned compare against less than zero
authorOliver Brown <oliver.brown@nxp.com>
Fri, 22 Mar 2019 18:44:37 +0000 (13:44 -0500)
committerSandor Yu <Sandor.yu@nxp.com>
Fri, 19 Apr 2019 02:40:50 +0000 (10:40 +0800)
Fixed CID 3411368, Unsigned compared against 0. Removed comparison with
no effect.

Signed-off-by: Oliver Brown <oliver.brown@nxp.com>
drivers/media/platform/imx8/hdmi/mxc-hdmi-rx.c

index 1eb48c1..c4361ce 100644 (file)
@@ -401,7 +401,7 @@ static int mxc_hdmi_enum_frame_interval(struct v4l2_subdev *sd,
 {
        struct mxc_hdmi_rx_dev *hdmi_rx = imx_sd_to_hdmi(sd);
 
-       if (fie->index < 0 || fie->index > 8)
+       if (fie->index > 8)
                return -EINVAL;
 
        if (fie->width == 0 || fie->height == 0 ||