Skip to content

drm: Deduplicate fb format information (v2)

[email protected] dri-devel intel-gfx 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest37 patches 53 repliesIn review
  2. v132 patches 18 repliesSuperseded

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/37drm/i915: Add local 'fb' variablesdrivers/gpu/drm/i915/intel_overlay.c+12 -141 reply
2/37drm/radeon: Add local 'fb' variablesdrivers/gpu/drm/radeon/r100.c drivers/gpu/drm/radeon/radeon_legacy_crtc.c+10 -30 replies
3/37drm/radeon: Use DIV_ROUND_UP()drivers/gpu/drm/radeon/radeon_legacy_crtc.c+2 -30 replies
4/37drm/mgag200: Add local 'fb' variabledrivers/gpu/drm/mgag200/mgag200_mode.c+9 -81 reply
5/37drm/ast: Add local 'fb' variablesdrivers/gpu/drm/ast/ast_mode.c+10 -51 reply
6/37drm/gma500: Add some local 'fb' variablesdrivers/gpu/drm/gma500/gma_display.c drivers/gpu/drm/gma500/mdfld_intel_display.c drivers/gpu/drm/gma500/oaktrail_crtc.c+22 -191 reply
7/37drm/cirrus: Add some local 'fb' variablesdrivers/gpu/drm/cirrus/cirrus_mode.c+5 -41 reply
8/37drm/arcpgu: Add local 'fb' variablesdrivers/gpu/drm/arc/arcpgu_crtc.c+2 -12 replies
9/37drm/arm: Add local 'fb' variablesdrivers/gpu/drm/arm/hdlcd_crtc.c drivers/gpu/drm/arm/malidp_planes.c+13 -114 replies
10/37drm/nouveau: Fix crtc->primary->fb vs. drm_fb faildrivers/gpu/drm/nouveau/dispnv04/crtc.c+2 -21 reply
11/37drm/nouveau: Add local 'fb' variablesdrivers/gpu/drm/nouveau/dispnv04/crtc.c drivers/gpu/drm/nouveau/dispnv04/dfp.c+5 -31 reply
12/37drm/vmwgfx: Populate fb->dev before drm_framebuffer_init()drivers/gpu/drm/vmwgfx/vmwgfx_kms.c+2 -01 reply
12/37drm/vmwgfx: Populate fb->dev before drm_framebuffer_init()drivers/gpu/drm/vmwgfx/vmwgfx_kms.c+2 -00 replies
13/37drm: Pass 'dev' to drm_helper_mode_fill_fb_struct()drivers/gpu/drm/amd/amdgpu/amdgpu_display.c drivers/gpu/drm/armada/armada_fb.c drivers/gpu/drm/ast/ast_main.c +19 more+24 -220 replies
13/37drm: Pass 'dev' to drm_helper_mode_fill_fb_struct()drivers/gpu/drm/amd/amdgpu/amdgpu_display.c drivers/gpu/drm/armada/armada_fb.c drivers/gpu/drm/ast/ast_main.c +21 more+27 -250 replies
14/37drm/vmwgfx: Populate fb->pixel_formatdrivers/gpu/drm/vmwgfx/vmwgfx_kms.c+22 -11 reply
15/37drm/qxl: Call drm_helper_mode_fill_fb_struct() before drm_framebuffer_init()drivers/gpu/drm/qxl/qxl_display.c+1 -10 replies
16/37drm/virtio: Call drm_helper_mode_fill_fb_struct() before drm_framebuffer_init()drivers/gpu/drm/virtio/virtgpu_display.c+2 -11 reply
17/37drm/i915: Set fb->dev early on for inherited fbsdrivers/gpu/drm/i915/intel_display.c+6 -01 reply
18/37drm: Populate fb->dev from drm_helper_mode_fill_fb_struct()drivers/gpu/drm/drm_framebuffer.c drivers/gpu/drm/drm_modeset_helper.c+5 -10 replies
19/37drm: Store a pointer to drm_format_info under drm_framebufferdrivers/gpu/drm/drm_modeset_helper.c include/drm/drm_framebuffer.h+5 -01 reply
20/37drm/vmwgfx: Populate fb->format correctlydrivers/gpu/drm/vmwgfx/vmwgfx_kms.c+2 -05 replies
21/37drm/i915: Populate fb->format early for inherited fbsdrivers/gpu/drm/i915/intel_display.c+3 -03 replies
22/37drm: Reject fbs w/o format info in drm_framebuffer_init()drivers/gpu/drm/drm_framebuffer.c+1 -11 reply
23/37drm: Replace drm_format_num_planes() with fb->format->num_planesdrivers/gpu/drm/arm/malidp_planes.c drivers/gpu/drm/armada/armada_overlay.c drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_layer.c +9 more+19 -191 reply
23/37drm: Replace drm_format_num_planes() with fb->format->num_planesdrivers/gpu/drm/arm/malidp_planes.c drivers/gpu/drm/armada/armada_crtc.c drivers/gpu/drm/armada/armada_overlay.c +10 more+20 -200 replies
24/37drm/i915: Eliminate the ugly 'fb?:' constructs from the ilk/skl wm codedrivers/gpu/drm/i915/intel_pm.c+15 -82 replies
25/37drm: Replace drm_format_plane_cpp() with fb->format->cpp[]drivers/gpu/drm/arm/hdlcd_crtc.c drivers/gpu/drm/armada/armada_overlay.c drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c +12 more+45 -451 reply
25/37drm: Replace drm_format_plane_cpp() with fb->format->cpp[]drivers/gpu/drm/arm/hdlcd_crtc.c drivers/gpu/drm/armada/armada_crtc.c drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c +12 more+45 -460 replies
26/37drm/fb_cma_helper: Replace drm_format_info() with fb->formatdrivers/gpu/drm/drm_fb_cma_helper.c+1 -40 replies
27/37drm/nouveau: Use fb->format rather than drm_format_info()drivers/gpu/drm/nouveau/nv50_display.c+5 -71 reply
28/37drm/i915: Store a pointer to the pixel format info for fbcdrivers/gpu/drm/i915/i915_drv.h drivers/gpu/drm/i915/intel_fbc.c+9 -91 reply
29/37drm: Add drm_framebuffer_plane_{width,height}()drivers/gpu/drm/drm_framebuffer.c include/drm/drm_framebuffer.h+50 -00 replies
30/37drm/i915: Use drm_framebuffer_plane_{width, height}() where possibledrivers/gpu/drm/i915/intel_display.c+2 -32 replies
31/37drm: Nuke fb->depthdrivers/gpu/drm/amd/amdgpu/amdgpu_fb.c drivers/gpu/drm/armada/armada_fbdev.c drivers/gpu/drm/ast/ast_fb.c +33 more+56 -591 reply
31/37drm: Nuke fb->depthdrivers/gpu/drm/amd/amdgpu/amdgpu_fb.c drivers/gpu/drm/armada/armada_fbdev.c drivers/gpu/drm/ast/ast_fb.c +33 more+56 -570 replies
32/37drm: Nuke fb->bits_per_pixeldrivers/gpu/drm/amd/amdgpu/dce_v10_0.c drivers/gpu/drm/amd/amdgpu/dce_v11_0.c drivers/gpu/drm/amd/amdgpu/dce_v6_0.c +41 more+89 -1021 reply
33/37drm: Nuke fb->pixel_formatdrivers/gpu/drm/amd/amdgpu/dce_v10_0.c drivers/gpu/drm/amd/amdgpu/dce_v11_0.c drivers/gpu/drm/amd/amdgpu/dce_v6_0.c +50 more+143 -1512 replies
34/37drm: Replace 'format->format' comparisons to just 'format' comparisonsdrivers/gpu/drm/armada/armada_crtc.c drivers/gpu/drm/drm_crtc_helper.c drivers/gpu/drm/drm_plane.c +4 more+9 -101 reply
35/37drm: Eliminate the useless "non-RGB fb" debug messagedrivers/gpu/drm/drm_modeset_helper.c+1 -121 reply
36/37drm: Add mode_config .get_format_info() hookdrivers/gpu/drm/drm_fb_cma_helper.c drivers/gpu/drm/drm_fourcc.c drivers/gpu/drm/drm_framebuffer.c +3 more+55 -46 replies
36/37drm: Add mode_config .get_format_info() hookdrivers/gpu/drm/drm_fb_cma_helper.c drivers/gpu/drm/drm_fourcc.c drivers/gpu/drm/drm_framebuffer.c +3 more+54 -40 replies
37/37drm/i915: Implement .get_format_info() hook for CCSdrivers/gpu/drm/i915/intel_display.c include/uapi/drm/drm_fourcc.h+40 -05 replies

Reviews trailers per patch

39 of 43 patches have a Reviewed-by or Acked-by.

PatchAlex DeucherLaurent PinchartBrian StarkeyBen WidawskyLiviu DudauAlexey BrodkinSinclair YehDaniel Vetter
1/37R-b
2/37R-b
3/37R-b
4/37R-b
5/37R-b
6/37R-b
7/37R-b
8/37A-b A-b
9/37R-b A-b
10/37R-b
11/37R-b
12/37R-b R-b
12/37R-b R-b
13/37R-b R-b R-b R-b
13/37R-b R-b R-b R-b
14/37R-b
15/37
16/37R-b
17/37R-b
18/37R-b R-b
19/37R-b R-b
20/37
21/37R-b
22/37R-b
23/37R-b R-b
23/37R-b R-b
24/37R-b
25/37R-b R-b
25/37R-b R-b
26/37R-b
27/37R-b
28/37R-b
29/37R-b
30/37R-b
31/37R-b R-b R-b R-b R-b R-b
31/37R-b R-b R-b R-b R-b R-b
32/37R-b R-b R-b R-b
33/37R-b R-b R-b R-b
34/37R-b
35/37R-b
36/37
36/37
37/37R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 8 reviewers.

Read the v2 thread

Cover letter [PATCH v2 00/37] drm: Deduplicate fb format information (v2)

From: Ville Syrjälä <[email protected]>

Second installment of my effort to remove the duplicated depth/bpp/pixel_format from drm_framebuffer and just use struct drm_format_info instead.

I tried to address all of the review feedback, and collect up all the r-bs I already got. Thanks for the review, guys.

Changes since the last version are roughly:
* drm_framebuffer_init() now fails if the fb isn't properly prepared
* Applied mode cocciry all over to use fb->format more extensively
* Dropped a few i915 specific patches that were taken care of the previous item
* Took up Laurent's idea that we can just compare the fb->format pointers instead of comparing the fb->format->format values
* Added a new .get_format_info() hooks for drivers to provide custom format information + an quick example patch how we'd hook it up for i915 render compression support

Link to the previous version:
https://lists.freedesktop.org/archives/dri-devel/2016-November/124135.html

Entire series is available here:
git://github.com/vsyrjala/linux.git fb_format_dedup_2

Cc Alex Deucher <[email protected]>
Cc Alexey Brodkin <[email protected]>
Cc Ben Skeggs <[email protected]>
Cc Ben Widawsky <[email protected]>
Cc Brian Starkey <[email protected]>
Cc "Christian König" <[email protected]>
Cc Dave Airlie <[email protected]>
Cc Gerd Hoffmann <[email protected]>
Cc Laurent Pinchart <[email protected]>
Cc Liviu Dudau <[email protected]>
Cc Mali DP Maintainers <[email protected]>
Cc Patrik Jakobsson <[email protected]>
Cc Paulo Zanoni <[email protected]>
Cc Sinclair Yeh <[email protected]>
Cc Thomas Hellstrom <[email protected]>

Ville Syrjälä (37):
drm/i915: Add local 'fb' variables
drm/radeon: Add local 'fb' variables
drm/radeon: Use DIV_ROUND_UP()
drm/mgag200: Add local 'fb' variable
drm/ast: Add local 'fb' variables
drm/gma500: Add some local 'fb' variables
drm/cirrus: Add some local 'fb' variables
drm/arcpgu: Add local 'fb' variables
drm/arm: Add local 'fb' variables
drm/nouveau: Fix crtc->primary->fb vs. drm_fb fail drm/nouveau: Add local 'fb' variables
drm/vmwgfx: Populate fb->dev before drm_framebuffer_init()
drm: Pass 'dev' to drm_helper_mode_fill_fb_struct() drm/vmwgfx: Populate fb->pixel_format
drm/qxl: Call drm_helper_mode_fill_fb_struct() before
drm_framebuffer_init()
drm/virtio: Call drm_helper_mode_fill_fb_struct() before
drm_framebuffer_init()
drm/i915: Set fb->dev early on for inherited fbs
drm: Populate fb->dev from drm_helper_mode_fill_fb_struct()
drm: Store a pointer to drm_format_info under drm_framebuffer drm/vmwgfx: Populate fb->format correctly
drm/i915: Populate fb->format early for inherited fbs
drm: Reject fbs w/o format info in drm_framebuffer_init()
drm: Replace drm_format_num_planes() with fb->format->num_planes drm/i915: Eliminate the ugly 'fb?:' constructs from the ilk/skl wm
code
drm: Replace drm_format_plane_cpp() with fb->format->cpp[] drm/fb_cma_helper: Replace drm_format_info() with fb->format drm/nouveau: Use fb->format rather than drm_format_info() drm/i915: Store a pointer to the pixel format info for fbc
drm: Add drm_framebuffer_plane_{width,height}()
drm/i915: Use drm_framebuffer_plane_{width,height}() where possible
drm: Nuke fb->depth
drm: Nuke fb->bits_per_pixel
drm: Nuke fb->pixel_format
drm: Replace 'format->format' comparisons to just 'format' comparisons
drm: Eliminate the useless "non-RGB fb" debug message
drm: Add mode_config .get_format_info() hook
drm/i915: Implement .get_format_info() hook for CCS

 drivers/gpu/drm/amd/amdgpu/amdgpu_display.c     |   2 +-
 drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c          |   4 +-
 drivers/gpu/drm/amd/amdgpu/dce_v10_0.c          |   6 +-
 drivers/gpu/drm/amd/amdgpu/dce_v11_0.c          |   6 +-
 drivers/gpu/drm/amd/amdgpu/dce_v6_0.c           |   6 +-
 drivers/gpu/drm/amd/amdgpu/dce_v8_0.c           |   6 +-
 drivers/gpu/drm/arc/arcpgu_crtc.c               |   3 +-
 drivers/gpu/drm/arm/hdlcd_crtc.c                |  18 ++--
 drivers/gpu/drm/arm/malidp_planes.c             |  10 +--
 drivers/gpu/drm/armada/armada_crtc.c            |   6 +-
 drivers/gpu/drm/armada/armada_fb.c              |   2 +-
 drivers/gpu/drm/armada/armada_fbdev.c           |   5 +-
 drivers/gpu/drm/armada/armada_overlay.c         |   6 +-
 drivers/gpu/drm/ast/ast_fb.c                    |   4 +-
 drivers/gpu/drm/ast/ast_main.c                  |   2 +-
 drivers/gpu/drm/ast/ast_mode.c                  |  16 ++--
 drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_layer.c |   2 +-
 drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c |  22 ++---
 drivers/gpu/drm/bochs/bochs_fbdev.c             |   2 +-
 drivers/gpu/drm/bochs/bochs_mm.c                |   2 +-
 drivers/gpu/drm/cirrus/cirrus_fbdev.c           |   6 +-
 drivers/gpu/drm/cirrus/cirrus_main.c            |   2 +-
 drivers/gpu/drm/cirrus/cirrus_mode.c            |   9 +-
 drivers/gpu/drm/drm_atomic.c                    |   8 +-
 drivers/gpu/drm/drm_crtc.c                      |   4 +-
 drivers/gpu/drm/drm_crtc_helper.c               |   3 +-
 drivers/gpu/drm/drm_fb_cma_helper.c             |  13 ++-
 drivers/gpu/drm/drm_fb_helper.c                 |  10 +--
 drivers/gpu/drm/drm_fourcc.c                    |  25 ++++++
 drivers/gpu/drm/drm_framebuffer.c               |  62 +++++++++++--
 drivers/gpu/drm/drm_modeset_helper.c            |  22 +----
 drivers/gpu/drm/drm_plane.c                     |   6 +-
 drivers/gpu/drm/exynos/exynos5433_drm_decon.c   |   6 +-
 drivers/gpu/drm/exynos/exynos7_drm_decon.c      |   8 +-
 drivers/gpu/drm/exynos/exynos_drm_fb.c          |   2 +-
 drivers/gpu/drm/exynos/exynos_drm_fbdev.c       |   6 +-
 drivers/gpu/drm/exynos/exynos_drm_fimd.c        |   4 +-
 drivers/gpu/drm/exynos/exynos_mixer.c           |  12 +--
 drivers/gpu/drm/fsl-dcu/fsl_dcu_drm_plane.c     |   4 +-
 drivers/gpu/drm/gma500/accel_2d.c               |   2 +-
 drivers/gpu/drm/gma500/framebuffer.c            |   6 +-
 drivers/gpu/drm/gma500/gma_display.c            |  13 +--
 drivers/gpu/drm/gma500/mdfld_intel_display.c    |  17 ++--
 drivers/gpu/drm/gma500/oaktrail_crtc.c          |  13 +--
 drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c |   6 +-
 drivers/gpu/drm/i915/i915_debugfs.c             |  11 +--
 drivers/gpu/drm/i915/i915_drv.h                 |   4 +-
 drivers/gpu/drm/i915/intel_atomic_plane.c       |   4 +-
 drivers/gpu/drm/i915/intel_display.c            | 115 ++++++++++++++++--------
 drivers/gpu/drm/i915/intel_fbc.c                |  14 +--
 drivers/gpu/drm/i915/intel_fbdev.c              |  10 +--
 drivers/gpu/drm/i915/intel_overlay.c            |  26 +++---
 drivers/gpu/drm/i915/intel_pm.c                 |  67 +++++++-------
 drivers/gpu/drm/i915/intel_sprite.c             |  14 +--
 drivers/gpu/drm/imx/ipuv3-plane.c               |  40 ++++-----
 drivers/gpu/drm/mediatek/mtk_drm_fb.c           |   2 +-
 drivers/gpu/drm/mediatek/mtk_drm_plane.c        |   4 +-
 drivers/gpu/drm/mgag200/mgag200_fb.c            |   4 +-
 drivers/gpu/drm/mgag200/mgag200_main.c          |   2 +-
 drivers/gpu/drm/mgag200/mgag200_mode.c          |  23 ++---
 drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c       |   2 +-
 drivers/gpu/drm/msm/mdp/mdp5/mdp5_plane.c       |   4 +-
 drivers/gpu/drm/msm/msm_fb.c                    |  12 +--
 drivers/gpu/drm/msm/msm_fbdev.c                 |   2 +-
 drivers/gpu/drm/nouveau/dispnv04/crtc.c         |  17 ++--
 drivers/gpu/drm/nouveau/dispnv04/dfp.c          |   3 +-
 drivers/gpu/drm/nouveau/dispnv04/overlay.c      |   8 +-
 drivers/gpu/drm/nouveau/nouveau_display.c       |   4 +-
 drivers/gpu/drm/nouveau/nouveau_fbcon.c         |   3 +-
 drivers/gpu/drm/nouveau/nv50_display.c          |  14 ++-
 drivers/gpu/drm/omapdrm/omap_fb.c               |  12 +--
 drivers/gpu/drm/omapdrm/omap_fbdev.c            |   2 +-
 drivers/gpu/drm/qxl/qxl_display.c               |   2 +-
 drivers/gpu/drm/qxl/qxl_draw.c                  |   2 +-
 drivers/gpu/drm/qxl/qxl_fb.c                    |   5 +-
 drivers/gpu/drm/radeon/atombios_crtc.c          |  19 ++--
 drivers/gpu/drm/radeon/r100.c                   |  10 ++-
 drivers/gpu/drm/radeon/radeon_display.c         |   8 +-
 drivers/gpu/drm/radeon/radeon_fb.c              |   4 +-
 drivers/gpu/drm/radeon/radeon_legacy_crtc.c     |  16 ++--
 drivers/gpu/drm/rcar-du/rcar_du_plane.c         |   4 +-
 drivers/gpu/drm/rcar-du/rcar_du_vsp.c           |   4 +-
 drivers/gpu/drm/rockchip/rockchip_drm_fb.c      |   2 +-
 drivers/gpu/drm/rockchip/rockchip_drm_fbdev.c   |   5 +-
 drivers/gpu/drm/rockchip/rockchip_drm_vop.c     |  22 ++---
 drivers/gpu/drm/shmobile/shmob_drm_crtc.c       |   6 +-
 drivers/gpu/drm/shmobile/shmob_drm_plane.c      |   4 +-
 drivers/gpu/drm/sti/sti_gdp.c                   |  10 +--
 drivers/gpu/drm/sti/sti_hqvdp.c                 |   2 +-
 drivers/gpu/drm/sun4i/sun4i_backend.c           |   5 +-
 drivers/gpu/drm/tegra/dc.c                      |   8 +-
 drivers/gpu/drm/tegra/drm.c                     |   5 +-
 drivers/gpu/drm/tegra/fb.c                      |   6 +-
 drivers/gpu/drm/tilcdc/tilcdc_crtc.c            |   4 +-
 drivers/gpu/drm/tilcdc/tilcdc_plane.c           |   4 +-
 drivers/gpu/drm/udl/udl_fb.c                    |   6 +-
 drivers/gpu/drm/vc4/vc4_plane.c                 |   8 +-
 drivers/gpu/drm/virtio/virtgpu_display.c        |   3 +-
 drivers/gpu/drm/virtio/virtgpu_fb.c             |   4 +-
 drivers/gpu/drm/vmwgfx/vmwgfx_fb.c              |  13 +--
 drivers/gpu/drm/vmwgfx/vmwgfx_kms.c             |  29 ++++--
 drivers/gpu/drm/vmwgfx/vmwgfx_ldu.c             |   5 +-
 drivers/gpu/drm/vmwgfx/vmwgfx_scrn.c            |   4 +-
 drivers/gpu/drm/vmwgfx/vmwgfx_stdu.c            |   2 +-
 drivers/gpu/drm/zte/zx_plane.c                  |   4 +-
 include/drm/drm_fourcc.h                        |   6 ++
 include/drm/drm_framebuffer.h                   |  27 +++---
 include/drm/drm_mode_config.h                   |  15 ++++
 include/drm/drm_modeset_helper.h                |   3 +-
 include/uapi/drm/drm_fourcc.h                   |   3 +
 110 files changed, 641 insertions(+), 470 deletions(-)
Signature · 6 lines
2.7.4

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx