[PATCH v2 13/25] drm/msm: Compute dumb-buffer sizes with drm_mode_size_dumb()

Dmitry Baryshkov dmitry.baryshkov at linaro.org
Mon Jan 13 08:25:09 UTC 2025


On Thu, Jan 09, 2025 at 03:57:07PM +0100, Thomas Zimmermann wrote:
> Call drm_mode_size_dumb() to compute dumb-buffer scanline pitch and
> buffer size. The hardware requires the scnaline pitch to be a multiple
> of 32 pixels. Therefore compute the byte size of 32 pixels in the given
> color mode and align the pitch accordingly.

- scanline, not scnaline
- the statement about 32-pixel alignment needs an explanation that it is
  being currently handled by align_pitch().

With that in mind:

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov at linaro.org>

> Signed-off-by: Thomas Zimmermann <tzimmermann at suse.de>
> Cc: Rob Clark <robdclark at gmail.com>
> Cc: Abhinav Kumar <quic_abhinavk at quicinc.com>
> Cc: Dmitry Baryshkov <dmitry.baryshkov at linaro.org>
> Cc: Sean Paul <sean at poorly.run>
> Cc: Marijn Suijten <marijn.suijten at somainline.org>
> ---
>  drivers/gpu/drm/msm/msm_gem.c | 27 +++++++++++++++++++++++++--
>  1 file changed, 25 insertions(+), 2 deletions(-)
> 

-- 
With best wishes
Dmitry


More information about the Spice-devel mailing list