Commit 4ed9dd7f authored by Hsiao Chien Sung's avatar Hsiao Chien Sung Committed by Chun-Kuang Hu
Browse files

drm/mediatek: Remove less-than-zero comparison of an unsigned value



Fix a Coverity error that less-than-zero comparison of an unsigned value
is never true.

Fixes: 119f5173 ("drm/mediatek: Add DRM Driver for Mediatek SoC MT8173.")
Signed-off-by: default avatarHsiao Chien Sung <shawn.sung@mediatek.com>
Reviewed-by: default avatarCK Hu <ck.hu@mediatek.com>
Link: https://patchwork.kernel.org/project/dri-devel/patch/20240614034937.23978-1-shawn.sung@mediatek.com/


Signed-off-by: default avatarChun-Kuang Hu <chunkuang.hu@kernel.org>
parent e7df7a20
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -593,7 +593,7 @@ int mtk_ddp_comp_init(struct device_node *node, struct mtk_ddp_comp *comp,
	int ret;
#endif

	if (comp_id < 0 || comp_id >= DDP_COMPONENT_DRM_ID_MAX)
	if (comp_id >= DDP_COMPONENT_DRM_ID_MAX)
		return -EINVAL;

	type = mtk_ddp_matches[comp_id].type;