[PATCH v2 0/9] drm/msm: fold dpu_format into mdp_formats database

From: Dmitry Baryshkov
Date: Sat Apr 20 2024 - 00:01:26 EST


During the review of [1] Abhinav pointed out that mdp_rgb_formats and
mdp_rgb_yuv_formats arrays from patch 1 are directly based on the struct
mdp_format formats array. This was true, because MDP4 / MDP5 drivers
used their own (small) list of supported formats. The DPU driver,
supporting more formats, had larger database of the formats and their
properties. While we don't have plans to expand MDP5 formats support, it
make sense to merge these two databases into a common dataset.

[1] https://patchwork.freedesktop.org/series/120377/
--
Changes in v2:
- Rebased on top of msm-next
- Moved all formats data to the new header mdp_formats.h (Abhinav)
- Dropped the alpha_enable flag changes (Abhinav)
- Link to v1: https://lore.kernel.org/r/20231202214016.1257621-1-dmitry.baryshkov@xxxxxxxxxx

---
Dmitry Baryshkov (9):
drm/msm/dpu: use format-related definitions from mdp_common.xml.h
drm/msm: add arrays listing formats supported by MDP4/MDP5 hardware
drm/msm/dpu: in dpu_format replace bitmap with unsigned long field
drm/msm/dpu: pull format flag definitions to mdp_format.h
drm/msm: merge dpu_format and mdp_format in struct msm_format
drm/msm: convert msm_format::unpack_tight to the flag
drm/msm: convert msm_format::unpack_align_msb to the flag
drm/msm: merge dpu format database to MDP formats
drm/msm: drop msm_kms_funcs::get_format() callback

drivers/gpu/drm/msm/disp/dpu1/dpu_crtc.c | 12 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 20 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h | 2 +-
.../gpu/drm/msm/disp/dpu1/dpu_encoder_phys_vid.c | 8 +-
.../gpu/drm/msm/disp/dpu1/dpu_encoder_phys_wb.c | 10 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_formats.c | 658 +--------------------
drivers/gpu/drm/msm/disp/dpu1/dpu_formats.h | 27 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_cdm.c | 6 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_cdm.h | 4 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_intf.c | 16 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_intf.h | 2 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_mdss.h | 124 +---
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_sspp.c | 40 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_sspp.h | 6 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_util.c | 14 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_util.h | 4 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.c | 22 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_hw_wb.h | 2 +-
drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 1 -
drivers/gpu/drm/msm/disp/dpu1/dpu_plane.c | 75 +--
drivers/gpu/drm/msm/disp/mdp4/mdp4_crtc.c | 4 +-
drivers/gpu/drm/msm/disp/mdp4/mdp4_kms.c | 1 -
drivers/gpu/drm/msm/disp/mdp4/mdp4_plane.c | 86 ++-
drivers/gpu/drm/msm/disp/mdp5/mdp5_crtc.c | 7 +-
drivers/gpu/drm/msm/disp/mdp5/mdp5_kms.c | 1 -
drivers/gpu/drm/msm/disp/mdp5/mdp5_plane.c | 95 +--
drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.c | 4 +-
drivers/gpu/drm/msm/disp/mdp5/mdp5_smp.h | 2 +-
drivers/gpu/drm/msm/disp/mdp_format.c | 630 +++++++++++++++++---
drivers/gpu/drm/msm/disp/mdp_format.h | 77 +++
drivers/gpu/drm/msm/disp/mdp_kms.h | 18 +-
drivers/gpu/drm/msm/msm_drv.h | 4 +-
drivers/gpu/drm/msm/msm_fb.c | 2 +-
drivers/gpu/drm/msm/msm_kms.h | 4 -
34 files changed, 913 insertions(+), 1075 deletions(-)
---
base-commit: a35e92ef04c07bd473404b9b73d489aea19a60a8
change-id: 20240420-dpu-format-d655c60875df

Best regards,
--
Dmitry Baryshkov <dmitry.baryshkov@xxxxxxxxxx>