mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-02 02:47:31 -04:00
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: 119f517362 ("drm/mediatek: Add DRM Driver for Mediatek SoC MT8173.")
Signed-off-by: Hsiao Chien Sung <shawn.sung@mediatek.com>
Reviewed-by: CK Hu <ck.hu@mediatek.com>
Link: https://patchwork.kernel.org/project/dri-devel/patch/20240614034937.23978-1-shawn.sung@mediatek.com/
Signed-off-by: Chun-Kuang Hu <chunkuang.hu@kernel.org>
This commit is contained in:
committed by
Chun-Kuang Hu
parent
e7df7a200e
commit
4ed9dd7fde
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user