kernel_samsung_a53x/drivers/gpu/drm/msm
Jonathan Marek 34b9267737 drm/msm/dsi: fix 32-bit signed integer extension in pclk_rate calculation
[ Upstream commit 358b762400bd94db2a14a72dfcef74c7da6bd845 ]

When (mode->clock * 1000) is larger than (1<<31), int to unsigned long
conversion will sign extend the int to 64 bits and the pclk_rate value
will be incorrect.

Fix this by making the result of the multiplication unsigned.

Note that above (1<<32) would still be broken and require more changes, but
its unlikely anyone will need that anytime soon.

Fixes: c4d8cfe516dc ("drm/msm/dsi: add implementation for helper functions")
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Abhinav Kumar <quic_abhinavk@quicinc.com>
Patchwork: https://patchwork.freedesktop.org/patch/618434/
Link: https://lore.kernel.org/r/20241007050157.26855-2-jonathan@marek.ca
Signed-off-by: Abhinav Kumar <quic_abhinavk@quicinc.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-23 23:21:58 +01:00
..
adreno drm/msm/a5xx: workaround early ring-buffer emptiness check 2024-11-23 23:21:22 +01:00
disp drm/msm: fix %s null argument error 2024-11-23 23:21:22 +01:00
dp drm/msm/dp: reset the link phy params before link training 2024-11-23 23:20:49 +01:00
dsi drm/msm/dsi: fix 32-bit signed integer extension in pclk_rate calculation 2024-11-23 23:21:58 +01:00
edp
hdmi
Kconfig
Makefile
msm_atomic.c
msm_atomic_trace.h
msm_atomic_tracepoints.c
msm_debugfs.c drm/msm: Add priv->mm_lock to protect active/inactive lists 2024-11-23 23:21:22 +01:00
msm_debugfs.h
msm_drv.c drm/msm: Drop priv->lastctx 2024-11-23 23:21:22 +01:00
msm_drv.h drm/msm: Drop priv->lastctx 2024-11-23 23:21:22 +01:00
msm_fb.c
msm_fbdev.c
msm_fence.c
msm_fence.h
msm_gem.c drm/msm: Add priv->mm_lock to protect active/inactive lists 2024-11-23 23:21:22 +01:00
msm_gem.h
msm_gem_prime.c
msm_gem_shrinker.c drm/msm: Add priv->mm_lock to protect active/inactive lists 2024-11-23 23:21:22 +01:00
msm_gem_submit.c
msm_gem_vma.c
msm_gpu.c drm/msm: Drop priv->lastctx 2024-11-23 23:21:22 +01:00
msm_gpu.h drm/msm: Drop priv->lastctx 2024-11-23 23:21:22 +01:00
msm_gpu_trace.h
msm_gpu_tracepoints.c
msm_gpummu.c
msm_iommu.c
msm_kms.h
msm_mmu.h
msm_perf.c
msm_rd.c
msm_ringbuffer.c
msm_ringbuffer.h
msm_submitqueue.c
NOTES