[PATCH] drm/msm/dpu: signedness bug in dpu_encoder_phys_cmd_tearcheck_config()
Dan Carpenter
dan.carpenter at linaro.org
Mon May 22 07:48:01 UTC 2023
The "vsync_hz" variable is used to store negative error codes so it
needs to be signed for the error checking to work correctly.
Fixes: 25fdd5933e4c ("drm/msm: Add SDM845 DPU support")
Signed-off-by: Dan Carpenter <dan.carpenter at linaro.org>
---
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c
index 74470d068622..b29e6d1ba7f6 100644
--- a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c
+++ b/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys_cmd.c
@@ -320,7 +320,7 @@ static void dpu_encoder_phys_cmd_tearcheck_config(
struct dpu_hw_tear_check tc_cfg = { 0 };
struct drm_display_mode *mode;
bool tc_enable = true;
- u32 vsync_hz;
+ int vsync_hz;
struct dpu_kms *dpu_kms;
if (!phys_enc->hw_pp) {
--
2.39.2
More information about the dri-devel
mailing list