Add DRM_COLOROP_3D_LUT_DMA for fast-loading 3D LUT
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest13 patches 2 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/13 | drm/colorop: Add DRM_COLOROP_3D_LUT_DMAdrivers/ drivers/ include/ | +85 | 0 replies | |
| 2/13 | drm/colorop: add DRM_COLOROP_3D_LUT_DMA object and statedrivers/ include/ | +142 | 0 replies | |
| 3/13 | drm/atomic: wire up DMA 3D LUT colorop propertiesdrivers/ drivers/ drivers/ +1 more | +76 | 0 replies | |
| 4/13 | drm/atomic: validate DMA 3D LUT colorop framebufferdrivers/ | +62 | 0 replies | |
| 5/13 | drm/atomic: add colorop prepare_fb and cleanup_fb helper hooksdrivers/ drivers/ drivers/ +4 more | +290 | 0 replies | |
| 6/13 | drm/tests: test colorop prepare_fb and cleanup_fb helpersdrivers/ drivers/ | +398 | 0 replies | |
| 7/13 | drm/amd/display: advertise a DMA 3D LUT color pipelinedrivers/ drivers/ drivers/ +2 more | +71 | 0 replies | |
| 8/13 | drm/amd/display: pin the DMA 3D LUT framebufferdrivers/ drivers/ drivers/ | +129 | 0 replies | |
| 9/13 | drm/amd/display: program the DMA 3D LUT coloropdrivers/ | +51 | 0 replies | |
| 10/13 | drm/amd/display: add 3D LUT DMA pitch alignment capdrivers/ drivers/ drivers/ | +6 | 0 replies | |
| 11/13 | drm/amd/display: derive the DMA 3D LUT pitch from DC capsdrivers/ drivers/ drivers/ +1 more | +21 | 0 replies | |
| 12/13 | drm/amd/display: reject direct 3D LUT loading mode changesdrivers/ drivers/ | +79 | 0 replies | |
| 13/13 | drm/amd/display: add KUnit tests for the DMA 3D LUT coloropdrivers/ drivers/ | +284 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH v1 00/13] Add DRM_COLOROP_3D_LUT_DMA for fast-loading 3D LUT
Loading a DRM_COLOROP_3D_LUT on AMD HW takes a long time because the driver has to load the entire 3D LUT via register writes.
Starting with DCN 4 the HW has the ability to load a 3D LUT via DMA, which only requires an address update for programming the 3D LUT.
I propose exposing a new DRM_COLOROP_3D_LUT_DMA type to support this DMA 3D LUT loading mechanism. Users of the DRM_COLOROP_3D_LUT_DMA will parse the supported formats via the LUT_3D_FORMATS blob property, select the desired format via LUT_3D_FORMAT property, and pass the 3D LUT buffer as a drm_framebuffer via FB_ID on the colorop.
For details see the patches and/or posted branches.
In addition to the patches posted here the 3d-fl-fixes kernel branch contains a number of fixes that will be merged via the usual amdgpu display process. It also contains a patch to enable support on Navi 4 (DCN 4.0.1), which won't be upstreamed since that generation requires a userspace workaround. The 3d-fl-workaround IGT branch exists solely for that purpose. Nonetheless, Navi 4 can serve as an enablement vehicle for anyone who wants to see the new interface working.
The kwin branch makes use of a pipeline with DRM_COLOROP_3D_LUT_DMA if such a pipeline is discovered before a pipeline with a DRM_COLOROP_3D_LUT.
### Branches
kernel: https://gitlab.freedesktop.org/hwentland/linux/-/commits/3d-fl
kernel w/ fixes: https://gitlab.freedesktop.org/hwentland/linux/-/commits/3d-fl-fixes
IGT: https://gitlab.freedesktop.org/hwentland/igt-gpu-tools/-/tree/3d-fl
IGT Navi 4 w/a: https://gitlab.freedesktop.org/hwentland/igt-gpu-tools/-/tree/3d-fl-workaround
kwin: https://invent.kde.org/hwentlan/kwin/-/commits/3d-fl
Harry Wentland (13):
drm/colorop: Add DRM_COLOROP_3D_LUT_DMA
drm/colorop: add DRM_COLOROP_3D_LUT_DMA object and state drm/atomic: wire up DMA 3D LUT colorop properties drm/atomic: validate DMA 3D LUT colorop framebuffer drm/atomic: add colorop prepare_fb and cleanup_fb helper hooks drm/tests: test colorop prepare_fb and cleanup_fb helpers drm/amd/display: advertise a DMA 3D LUT color pipeline drm/amd/display: pin the DMA 3D LUT framebuffer drm/amd/display: program the DMA 3D LUT colorop drm/amd/display: add 3D LUT DMA pitch alignment cap drm/amd/display: derive the DMA 3D LUT pitch from DC caps drm/amd/display: reject direct 3D LUT loading mode changes drm/amd/display: add KUnit tests for the DMA 3D LUT colorop
drivers/gpu/drm/amd/display/Kconfig | 13 + .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 68 ++- .../amd/display/amdgpu_dm/amdgpu_dm_colorop.c | 131 +++++- .../amd/display/amdgpu_dm/amdgpu_dm_colorop.h | 8 +- .../amd/display/amdgpu_dm/amdgpu_dm_plane.c | 71 +++- .../amdgpu_dm/tests/amdgpu_dm_colorop_test.c | 286 ++++++++++++- .../amdgpu_dm/tests/amdgpu_dm_plane_test.c | 65 +++ drivers/gpu/drm/amd/display/dc/dc.h | 2 + .../dc/resource/dcn42/dcn42_resource.c | 2 + .../dc/resource/dcn42b/dcn42b_resource.c | 2 + drivers/gpu/drm/drm_atomic.c | 66 +++ drivers/gpu/drm/drm_atomic_helper.c | 93 ++++ drivers/gpu/drm/drm_atomic_uapi.c | 28 ++ drivers/gpu/drm/drm_colorop.c | 96 +++++ drivers/gpu/drm/drm_framebuffer.c | 45 +- drivers/gpu/drm/drm_gem_atomic_helper.c | 81 ++++ drivers/gpu/drm/tests/Makefile | 1 + .../gpu/drm/tests/drm_colorop_helper_test.c | 397 ++++++++++++++++++ include/drm/drm_atomic.h | 20 + include/drm/drm_colorop.h | 71 ++++ include/drm/drm_gem_atomic_helper.h | 11 + include/drm/drm_modeset_helper_vtables.h | 62 +++ include/uapi/drm/drm.h | 7 +- include/uapi/drm/drm_mode.h | 79 ++++ 24 files changed, 1672 insertions(+), 33 deletions(-) create mode 100644 drivers/gpu/drm/tests/drm_colorop_helper_test.c
--
2.56.0