Re: [RFC PATCH v4 00/42] Color Pipeline API w/ VKMS

2024-06-05 Thread Melissa Wen
Inverse > OETF while the 3rd colorop takes the Inverse EOTF or OETF. > > We are working on two more ops for amdgpu, the HDR multiplier > and the 3DLUT, which will give us this: > > 1. 1D Curve EOTF > 2. 3x4 CTM > 3. HDR Multiplier > 4. 1D Curve Inverse EOTF > 5. 1D LU

Re: [RFC PATCH v4 31/42] drm/amd/display: Add support for sRGB EOTF in DEGAM block

2024-05-21 Thread Melissa Wen
On 05/21, Melissa Wen wrote: > On 02/26, Harry Wentland wrote: > > From: Alex Hung > > > > Expose one 1D curve colorop with support for > > DRM_COLOROP_1D_CURVE_SRGB_EOTF and program HW to perform > > the sRGB transform when the colorop is not in bypass. > &

Re: [RFC PATCH v4 00/42] Color Pipeline API w/ VKMS

2024-05-21 Thread Melissa Wen
this: > > 1. 1D Curve EOTF > 2. 3x4 CTM > 3. HDR Multiplier > 4. 1D Curve Inverse EOTF > 5. 1D LUT > 6. 3D LUT > 7. 1D Curve EOTF > 8. 1D LUT > > This, essentially mirrors the color pipeline used by gamescope > and presented by Melissa Wen, with the excep

Re: [RFC PATCH v4 31/42] drm/amd/display: Add support for sRGB EOTF in DEGAM block

2024-05-21 Thread Melissa Wen
On 02/26, Harry Wentland wrote: > From: Alex Hung > > Expose one 1D curve colorop with support for > DRM_COLOROP_1D_CURVE_SRGB_EOTF and program HW to perform > the sRGB transform when the colorop is not in bypass. > > With this change the following IGT test passes: > kms_colorop --run

Re: [RFC PATCH v4 41/42] drm/colorop: Add mutliplier type

2024-05-21 Thread Melissa Wen
On 02/26, Harry Wentland wrote: > From: Alex Hung > > This introduces a new drm_colorop_type: DRM_COLOROP_MULTIPLIER. > > It's a simple multiplier to all pixel values. The value is > specified via a S31.32 fixed point provided via the > "MULTIPLIER" property. > > Signed-off-by: Alex Hung >

Re: [RFC PATCH v4 09/42] drm/colorop: Introduce new drm_colorop mode object

2024-05-21 Thread Melissa Wen
On 02/26, Harry Wentland wrote: > This patches introduces a new drm_colorop mode object. This > object represents color transformations and can be used to > define color pipelines. > > We also introduce the drm_colorop_state here, as well as > various helpers and state tracking bits. > > v4: >

Re: [PATCH 02/25] drm/amd/display: Add a function for checking tmds mode

2024-04-15 Thread Melissa Wen
On 10/04/2024 18:25, Rodrigo Siqueira wrote: From: Chris Park [Why] DVI is TMDS signal like HDMI but without audio. Current signal check does not correctly reflect DVI clock programming. [How] Define a new signal check for TMDS that includes DVI to HDMI TMDS programming. Reviewed-by:

Re: [PATCH] drm/amd/display: Enable ogam_ram for dcn32+dcn35+dcn351

2024-04-15 Thread Melissa Wen
On 04/12, Harry Wentland wrote: > > > On 2024-04-12 16:22, Harry Wentland wrote: > > > > > > On 2024-04-12 12:26, Melissa Wen wrote: > >> On 04/12, Joshua Ashton wrote: > >>> > >>> > >>> On 4/11/24 3:26 PM, Melissa W

[PATCH] drm/amd/display: use mpcc_count to log MPC state

2024-04-12 Thread Melissa Wen
/20240328195047.2843715-39-roman...@amd.com/ Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/dc/hwss/dcn10/dcn10_hwseq.c | 2 +- drivers/gpu/drm/amd/display/dc/hwss/dcn20/dcn20_hwseq.c | 2 +- drivers/gpu/drm/amd/display/dc/hwss/dcn30/dcn30_hwseq.c | 2 +- 3 files changed, 3 insertions(+), 3

Re: [PATCH] drm/amd/display: Enable ogam_ram for dcn32+dcn35+dcn351

2024-04-12 Thread Melissa Wen
On 04/12, Joshua Ashton wrote: > > > On 4/11/24 3:26 PM, Melissa Wen wrote: > > On 04/10, Joshua Ashton wrote: > > > The comment here states "no OGAM in DPP since DCN1", yet that is not > > > true. > > > > > > Testing on an RX 7900XT

Re: [PATCH] Revert "drm/amd/display: Enable cur_rom_en even if cursor degamma is not enabled"

2024-04-11 Thread Melissa Wen
On 04/11, Rodrigo Siqueira wrote: > This reverts commit 5aba567a2988400d4e01d44493c84bed92820d8d. > > The original patch introduces cursor gamma issue to multiple > Linux compositors. For this reason this commit reverts this change. Thanks for checking the issue. Reviewed-by:

Re: [PATCH] drm/amd/display: Enable ogam_ram for dcn32+dcn35+dcn351

2024-04-11 Thread Melissa Wen
od if AMD people can check it too. Melissa > > Signed-off-by: Joshua Ashton > > Cc: Harry Wentland > Cc: Xaver Hugl > Cc: Melissa Wen > Cc: Ethan Lee > --- > drivers/gpu/drm/amd/display/dc/resource/dcn32/dcn32_resource.c | 2 +- > drivers/gpu/drm/amd/display

Re: [RFC PATCH v3 0/6] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-04-08 Thread Melissa Wen
On 03/28, Jani Nikula wrote: > On Wed, 27 Mar 2024, Melissa Wen wrote: > > 2. Most of the edid data handled by `dm_helpers_parse_edid_caps()` are > >in drm_edid halpers, but there are still a few that are not managed by > >them yet. For example: > >``` >

Re: [RFC PATCH v3 3/6] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-04-08 Thread Melissa Wen
On 03/28, Jani Nikula wrote: > On Wed, 27 Mar 2024, Melissa Wen wrote: > > Replace raw edid handling (struct edid) with the opaque EDID type > > (struct drm_edid) on amdgpu_dm_connector for consistency. It may also > > prevent mismatch of approaches in different par

Re: [PATCH 30/43] drm/amd/display: Enable cur_rom_en even if cursor degamma is not enabled

2024-04-01 Thread Melissa Wen
On 28/03/2024 16:50, roman...@amd.com wrote: From: Rodrigo Siqueira Signed-off-by: Rodrigo Siqueira Tested-by: Daniel Wheeler --- drivers/gpu/drm/amd/display/dc/dpp/dcn30/dcn30_dpp.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git

Re: [PATCH 38/43] drm/amd/display: Fix MPCC DTN logging

2024-04-01 Thread Melissa Wen
On 28/03/2024 16:50, roman...@amd.com wrote: From: Eric Bernstein [Why] DTN only logs 'pipe_count' instances of MPCC. However in some cases there are different number of MPCC than DPP (pipe_count). [How] Add mpcc_count parameter to resource_pool and set it during pool construction and use

[RFC PATCH v3 6/6] drm/amd/display: remove redundant freesync parser for DP

2024-03-27 Thread Melissa Wen
When updating connector under drm_edid infrastructure, many calculations and validations are already done and become redundant inside AMD driver. Remove those driver-specific code in favor of the DRM common code. Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 86

[RFC PATCH v3 5/6] drm/amd/display: always call connector_update when parsing freesync_caps

2024-03-27 Thread Melissa Wen
Update connector caps with drm_edid data before parsing info for freesync. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu

[RFC PATCH v3 4/6] drm/amd/display: switch to setting physical address directly

2024-03-27 Thread Melissa Wen
Connectors have source physical address available in display info. Use drm_dp_cec_attach() to use it instead of parsing the EDID again. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

[RFC PATCH v3 3/6] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-03-27 Thread Melissa Wen
(Alex Hung) v3: fix general protection fault on mst Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 99 +-- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 4 +- .../amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 8 +- .../display/amdgpu_dm

[RFC PATCH v3 2/6] drm/amd/display: clean unused variables for hdmi freesync parser

2024-03-27 Thread Melissa Wen
Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 05ffe844b1fc..280562707cd0 100644 --- a/drivers/gpu

[RFC PATCH v3 1/6] drm/amd/display: remove unused pixel_clock_mhz from amdgpu_dm_connector

2024-03-27 Thread Melissa Wen
We set pixel_clock_mhz when updating freesync caps, but it's not used anywhere. Remove it. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 1 - 2 files changed, 4 deletions(-) diff --git a/drivers/gpu

[RFC PATCH v3 0/6] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-03-27 Thread Melissa Wen
common code v2: https://lore.kernel.org/amd-gfx/20240327165828.288792-1-m...@igalia.com/ - fix general protection fault on mst Melissa Wen (6): drm/amd/display: remove unused pixel_clock_mhz from amdgpu_dm_connector drm/amd/display: clean unused variables for hdmi freesync parser drm/a

[RFC PATCH v2 6/6] drm/amd/display: remove redundant freesync parser for DP

2024-03-27 Thread Melissa Wen
When updating connector under drm_edid infrastructure, many calculations and validations are already done and become redundant inside AMD driver. Remove those driver-specific code in favor of the DRM common code. Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 86

[RFC PATCH v2 5/6] drm/amd/display: always call connector_update when parsing freesync_caps

2024-03-27 Thread Melissa Wen
Update connector caps with drm_edid data before parsing info for freesync. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu

[RFC PATCH v2 4/6] drm/amd/display: switch to setting physical address directly

2024-03-27 Thread Melissa Wen
Connectors have source physical address available in display info. Use drm_dp_cec_attach() to use it instead of parsing the EDID again. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

[RFC PATCH v2 3/6] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-03-27 Thread Melissa Wen
(Alex Hung) Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 99 +-- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 4 +- .../amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 8 +- .../display/amdgpu_dm/amdgpu_dm_mst_types.c | 28 +++--- 4 files changed

[RFC PATCH v2 2/6] drm/amd/display: clean unused variables for hdmi freesync parser

2024-03-27 Thread Melissa Wen
Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 05ffe844b1fc..280562707cd0 100644 --- a/drivers/gpu

[RFC PATCH v2 1/6] drm/amd/display: remove unused pixel_clock_mhz from amdgpu_dm_connector

2024-03-27 Thread Melissa Wen
We set pixel_clock_mhz when updating freesync caps, but it's not used anywhere. Remove it. Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 3 --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 1 - 2 files changed, 4 deletions(-) diff --git a/drivers/gpu

[RFC PATCH v2 0/6] switch amdgpu_dm_connector to use struct drm_edid

2024-03-27 Thread Melissa Wen
extensive testing and validation of a large variety of display caps and I don't have the required setup for it (perhaps you can test it in your CI to point issues?). I don't see how to reduce the scope of changes to mitigate the noise/disruption, but any suggestions are welcome. Thanks, Melissa Meli

Re: [RFC PATCH v4 01/42] drm: Don't treat 0 as -1 in drm_fixp2int_ceil

2024-03-14 Thread Melissa Wen
raction and drm_fixp2int_ceil") > Signed-off-by: Harry Wentland > Reviewed-by: Simon Ser > Reviewed-by: Melissa Wen It was already applied upstream: https://cgit.freedesktop.org/drm/drm-misc/commit/include?id=cf8837d7204481026335461629b84ac7f4538fa5 Thanks Melissa > --- > in

Re: [RFC PATCH v4 02/42] drm: Add helper for conversion from signed-magnitude

2024-03-14 Thread Melissa Wen
On 02/26, Harry Wentland wrote: > CTM values are defined as signed-magnitude values. Add > a helper that converts from CTM signed-magnitude fixed > point value to the twos-complement value used by > drm_fixed. > > Signed-off-by: Harry Wentland > --- > include/drm/drm_fixed.h | 18

Re: [RFC PATCH v4 07/42] drm/vkms: Avoid reading beyond LUT array

2024-03-12 Thread Melissa Wen
Drop bits from commit description that didn't contribute >anything of value > > Fixes: db1f254f2cfaf ("drm/vkms: Add support to 1D gamma LUT") > Signed-off-by: Harry Wentland > Cc: Arthur Grillo > Reviewed-by: Melissa Wen Same. Already applied upstream: https://cgit.freed

Re: [RFC PATCH v4 05/42] drm/vkms: Create separate Kconfig file for VKMS

2024-03-12 Thread Melissa Wen
On 02/26, Harry Wentland wrote: > This aligns with most other DRM drivers and will allow > us to add new VKMS config options without polluting > the DRM Kconfig. > > v3: > - Change SPDX to GPL-2.0-only to match DRM KConfig >SPDX (Simon) > > Signed-off-by: Harry Wentland > Reviewed-by:

Re: [PATCH 25/34] drm/amd/display: Set the power_down_on_boot function pointer to null

2024-03-07 Thread Melissa Wen
On 02/28, Mario Limonciello wrote: > On 2/28/2024 12:39, Alex Hung wrote: > > From: Muhammad Ahmed > > > > [WHY] > > Blackscreen hang @ PC EF25 when trying to wake up from S0i3. DCN > > gets powered off due to dc_power_down_on_boot() being called after > > timeout. > > > > [HOW] > > Setting

[PATCH] drm/amd/display: check dc_link before dereferencing

2024-02-27 Thread Melissa Wen
Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c index 32efce81a5a7..46dd06e8fc7e 100644 --- a/drive

Re: [PATCH] drm/amd/display: fix null-pointer dereference on edid reading

2024-02-16 Thread Melissa Wen
On 02/15, Alex Deucher wrote: > On Thu, Feb 15, 2024 at 12:35 PM Melissa Wen wrote: > > > > Use i2c adapter when there isn't aux_mode in dc_link to fix a > > null-pointer derefence that happens when running > > igt@kms_force_connector_basic in a system with DCN2.1 and

[PATCH v2] drm/amd/display: fix null-pointer dereference on edid reading

2024-02-16 Thread Melissa Wen
]--- Fixes: e54ed41620f ("drm/amd/display: Remove unwanted drm edid references") Signed-off-by: Melissa Wen --- v2: - remove unused variables .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 19 +++ 1 file changed, 15 insertions(+), 4 deletions(-) diff --git

[PATCH] drm/amd/display: fix null-pointer dereference on edid reading

2024-02-15 Thread Melissa Wen
]--- Fixes: e54ed41620f ("drm/amd/display: Remove unwanted drm edid references") Signed-off-by: Melissa Wen --- Hi, I'm still working on the migration from edid to drm_edid, but I found a way to fix the issue using the current approach, so we don't need to delay this

Re: [RFC PATCH 2/2] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-02-05 Thread Melissa Wen
On 01/26, Alex Hung wrote: > > > On 2024-01-26 09:28, Melissa Wen wrote: > > Replace raw edid handling (struct edid) with the opaque EDID type > > (struct drm_edid) on amdgpu_dm_connector for consistency. It may also > > prevent mismatch of approaches in differe

Re: [RFC PATCH 0/2] drm/amd/display: switch amdgpu_dm_connector to

2024-02-05 Thread Melissa Wen
On 01/29, Jani Nikula wrote: > On Fri, 26 Jan 2024, Mario Limonciello wrote: > > On 1/26/2024 10:28, Melissa Wen wrote: > >> Hi, > >> > >> I'm debugging a null-pointer dereference when running > >> igt@kms_connector_force_edid and the way I found to

[RFC PATCH 2/2] drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid

2024-01-26 Thread Melissa Wen
. Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 63 ++- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 4 +- .../amd/display/amdgpu_dm/amdgpu_dm_helpers.c | 9 +-- .../display/amdgpu_dm/amdgpu_dm_mst_types.c | 23 +++ 4 files changed, 51

[RFC PATCH 0/2] drm/amd/display: switch amdgpu_dm_connector to

2024-01-26 Thread Melissa Wen
ssed - I'm looking for the best replacement. I appreciate any feedback and testing. Melissa Melissa Wen (2): drm/amd/display: fix null-pointer dereference on edid reading drm/amd/display: switch amdgpu_dm_connector to use struct drm_edid .../gpu/drm/amd/display/amdgpu_dm/amdgpu

[RFC PATCH 1/2] drm/amd/display: fix null-pointer dereference on edid reading

2024-01-26 Thread Melissa Wen
0f ("drm/amd/display: Remove unwanted drm edid references") Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 23 +++ 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drive

Re: [PATCH 1/1] Revert "drm/amd/display: fix bandwidth validation failure on DCN 2.1"

2024-01-07 Thread Melissa Wen
ui...@amd.com ; Choi, Nicholas > ; Deucher, Alexander ; > Koenig, Christian ; Wentland, Harry > ; LIPSKI, IVAN ; Melissa Wen > ; Mahfooz, Hamza > Subject: [PATCH 1/1] Revert "drm/amd/display: fix bandwidth validation > failure on DCN 2.1" > > From: Ivan Lipski

[PATCH] drm/amd/display: cleanup inconsistent indenting in amdgpu_dm_color

2024-01-05 Thread Melissa Wen
smatch warnings: amdgpu_dm_update_plane_color_mgmt() warn: inconsistent indenting Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202401051643.ppdbmg1u-...@intel.com/ Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c | 2 +- 1

[RFC PATCH] drm/amd/display: fix bandwidth validation failure on DCN 2.1

2023-12-29 Thread Melissa Wen
, the atomic check needs to perform a full state validation. Therefore, set fast_validation to false in the dc_validate_global_state call for atomic check. Fixes: b8272241ff9d ("drm/amd/display: Drop dc_commit_state in favor of dc_commit_streams") Signed-off-by: Melissa Wen --- Hi, It's a

[PATCH] drm/amd/display: fix documentation for dm_crtc_additional_color_mgmt()

2023-12-14 Thread Melissa Wen
warning: expecting prototype for drm_crtc_additional_color_mgmt(). Prototype was for dm_crtc_additional_color_mgmt() instead Reported-by: kernel test robot Closes: https://lore.kernel.org/oe-kbuild-all/202312141801.o9ebcxt9-...@intel.com/ Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd

Re: [PATCH] drm/amd/display: fix documentation for amdgpu_dm_verify_lut3d_size()

2023-12-14 Thread Melissa Wen
On 12/14, Alex Deucher wrote: > It takes the plane state rather than the crtc state. > > Fixes: aba8b76baabd ("drm/amd/display: add plane shaper LUT support") > Reported-by: Stephen Rothwell > Signed-off-by: Alex Deucher > Cc: Melissa Wen > Cc: harry.wentl...@a

[PATCH v3 6/9] drm/amd/display: create DCN3-specific log for MPC state

2023-11-28 Thread Melissa Wen
-by: Melissa Wen --- .../gpu/drm/amd/display/dc/dcn30/dcn30_mpc.c | 48 ++- drivers/gpu/drm/amd/display/dc/inc/hw/mpc.h | 7 +++ 2 files changed, 54 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dcn30/dcn30_mpc.c b/drivers/gpu/drm/amd/display/dc

[PATCH v3 9/9] drm/amd/display: hook up DCN20 color blocks data to DTN log

2023-11-28 Thread Melissa Wen
31.32. Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/dc/dcn20/dcn20_dpp.c | 30 ++--- .../gpu/drm/amd/display/dc/dcn20/dcn20_init.c | 1 + .../gpu/drm/amd/display/dc/dcn20/dcn20_mpc.c | 24 +++- .../gpu/drm/amd/display/dc/dcn21/dcn21_init.c | 1 + .../amd/display/dc/hwss/dcn20

[PATCH v3 8/9] drm/amd/display: add DPP and MPC color caps to DTN log

2023-11-28 Thread Melissa Wen
Add color caps information for DPP and MPC block to show HW color caps. Signed-off-by: Melissa Wen --- .../amd/display/dc/hwss/dcn10/dcn10_hwseq.c | 23 +++ .../amd/display/dc/hwss/dcn30/dcn30_hwseq.c | 23 +++ 2 files changed, 46 insertions(+) diff --git

[PATCH v3 7/9] drm/amd/display: hook up DCN30 color blocks data to DTN log

2023-11-28 Thread Melissa Wen
remap matrix log v3: - read MPC gamut remap matrix in fixed 31.32 format - extend to DCN3.0+ and DCN3.1+ drivers (Harry) Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/dc/dcn30/dcn30_init.c | 1 + .../drm/amd/display/dc/dcn301/dcn301_init.c | 1 + .../gpu/drm/amd/display/dc/dcn31

[PATCH v3 3/9] drm/amd/display: read gamut remap matrix in fixed-point 31.32 format

2023-11-28 Thread Melissa Wen
Instead of read gamut remap data from hw values, convert HW register values (S2D13) into a fixed-point 31.32 matrix for color state log. Change DCN10 log to print data in the format of the gamut remap matrix. Signed-off-by: Melissa Wen --- .../amd/display/dc/hwss/dcn10/dcn10_hwseq.c | 38

[PATCH v3 5/9] drm/amd/display: add get_gamut_remap helper for MPC3

2023-11-28 Thread Melissa Wen
We want to be able to read the MPC's gamut remap matrix similar to what we do with .dpp_get_gamut_remap functions. On the other hand, we don't need a hook here because only DCN3+ has the MPC gamut remap block, being absent in previous families. Signed-off-by: Melissa Wen --- .../gpu/drm/amd

[PATCH v3 2/9] drm/amd/display: Add dpp_get_gamut_remap functions

2023-11-28 Thread Melissa Wen
From: Harry Wentland We want to be able to read the DPP's gamut remap matrix. v2: - code-style and doc comments clean-up (Melissa) Signed-off-by: Harry Wentland Signed-off-by: Melissa Wen --- .../drm/amd/display/dc/basics/conversion.c| 34 + .../drm/amd/display/dc/basics

[PATCH v3 4/9] drm/amd/display: fill up DCN3 DPP color state

2023-11-28 Thread Melissa Wen
Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/dc/dcn30/dcn30_dpp.c | 37 ++- drivers/gpu/drm/amd/display/dc/inc/hw/dpp.h | 8 2 files changed, 43 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dcn30/dcn30_dpp.c b/drivers/gpu/drm/amd

[PATCH v3 1/9] drm/amd/display: decouple color state from hw state log

2023-11-28 Thread Melissa Wen
Prepare to hook up color state log according to the DCN version. v3: - put functions in single line (Siqueira) Signed-off-by: Melissa Wen --- .../amd/display/dc/hwss/dcn10/dcn10_hwseq.c | 26 +-- 1 file changed, 18 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm

[PATCH v3 0/9] drm/amd/display: improve DTN color state log

2023-11-28 Thread Melissa Wen
functions Melissa Wen (8): drm/amd/display: decouple color state from hw state log drm/amd/display: read gamut remap matrix in fixed-point 31.32 format drm/amd/display: fill up DCN3 DPP color state drm/amd/display: add get_gamut_remap helper for MPC3 drm/amd/display: create DCN3-specific log

[PATCH v5 31/32] drm/amd/display: add plane CTM support

2023-11-16 Thread Melissa Wen
Map the plane CTM driver-specific property to DC plane, instead of DC stream. The remaining steps to program DPP block are already implemented on DC shared-code. v3: - fix comment about plane and CRTC CTMs priorities (Harry) Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../gpu

[PATCH v5 28/32] drm/amd/display: allow newer DC hardware to use degamma ROM for PQ/HLG

2023-11-16 Thread Melissa Wen
set_color_properties (Harry) Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 29 --- 1 file changed, 18 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c

[PATCH v5 29/32] drm/amd/display: copy 3D LUT settings from crtc state to stream_update

2023-11-16 Thread Melissa Wen
From: Joshua Ashton When commiting planes, we copy color mgmt resources to the stream state. Do the same for shaper and 3D LUTs. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Co-developed-by: Melissa Wen Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm

[PATCH v5 21/32] drm/amd/display: add dc_fixpt_from_s3132 helper

2023-11-16 Thread Melissa Wen
From: Joshua Ashton Detach value translation from CTM to reuse it for programming HDR multiplier property. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c | 8 +--- drivers/gpu/drm/amd/display

[PATCH v5 24/32] drm/amd/display: add plane shaper TF support

2023-11-16 Thread Melissa Wen
Enable usage of predefined transfer func in addition to shaper 1D LUT. That means we can save some complexity by just setting a predefined curve, instead of programming a custom curve when preparing color space for applying 3D LUT. Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen

[PATCH v5 32/32] drm/amd/display: Add 3x4 CTM support for plane CTM

2023-11-16 Thread Melissa Wen
From: Joshua Ashton Create drm_color_ctm_3x4 to support 3x4-dimension plane CTM matrix and convert DRM CTM to DC CSC float matrix. v3: - rename ctm2 to ctm_3x4 (Harry) Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 28

[PATCH v5 27/32] drm/amd/display: add plane blend LUT and TF support

2023-11-16 Thread Melissa Wen
module to fill parameters when setting non-linear TF with empty LUT. v2: - rename DRM TFs to AMDGPU TFs Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 + .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 56

[PATCH v5 30/32] drm/amd/display: add plane CTM driver-specific property

2023-11-16 Thread Melissa Wen
Plane CTM for pre-blending color space conversion. Only enable driver-specific plane CTM property on drivers that support both pre- and post-blending gamut remap matrix, i.e., DCN3+ family. Otherwise it conflits with DRM CRTC CTM property. Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen

[PATCH v5 25/32] drm/amd/display: add plane 3D LUT support

2023-11-16 Thread Melissa Wen
instead of # of entries Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 + .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 102 +- 2 files changed, 99 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd

[PATCH v5 19/32] drm/amd/display: add plane degamma TF and LUT support

2023-11-16 Thread Melissa Wen
return -EINVAL if we don't have plane degamma settings, so we can continue and check CRTC degamma. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 +- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 1

[PATCH v5 23/32] drm/amd/display: add plane shaper LUT support

2023-11-16 Thread Melissa Wen
) Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 + .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 2 + .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 93 ++- 3 files changed, 92 insertions(+), 4 deletions(-) diff

[PATCH v5 26/32] drm/amd/display: handle empty LUTs in __set_input_tf

2023-11-16 Thread Melissa Wen
Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 20 +++ 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c b/drivers/gpu/drm/amd/display/amdgpu_dm

[PATCH v5 22/32] drm/amd/display: add HDR multiplier support

2023-11-16 Thread Melissa Wen
From: Joshua Ashton With `dc_fixpt_from_s3132()` translation, we can just use it to set hdr_mult. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 + drivers/gpu/drm/amd/display/amdgpu_dm

[PATCH v5 18/32] drm/amd/display: decouple steps for mapping CRTC degamma to DC plane

2023-11-16 Thread Melissa Wen
combinations. Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 60 +-- 1 file changed, 42 insertions(+), 18 deletions(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c b/drivers/gpu/drm/amd/display

[PATCH v5 20/32] drm/amd/display: reject atomic commit if setting both plane and CRTC degamma

2023-11-16 Thread Melissa Wen
Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c | 13 - 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c b/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c index

[PATCH v5 13/32] drm/amd/display: add comments to describe DM crtc color mgmt behavior

2023-11-16 Thread Melissa Wen
Describe some expected behavior of the AMD DM color mgmt programming. Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../drm/amd/display/amdgpu_dm/amdgpu_dm_color.c | 16 ++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display

[PATCH v5 16/32] drm/amd/display: set sdr_ref_white_level to 80 for out_transfer_func

2023-11-16 Thread Melissa Wen
From: Joshua Ashton Otherwise this is just initialized to 0. This needs to actually have a value so that compute_curve can work for PQ EOTF. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Co-developed-by: Melissa Wen Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display

[PATCH v5 17/32] drm/amd/display: mark plane as needing reset if color props change

2023-11-16 Thread Melissa Wen
From: Joshua Ashton We should reset a plane state if at least one of the color management properties differs from old and new state. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Co-developed-by: Melissa Wen Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm

[PATCH v5 15/32] drm/amd/display: add CRTC gamma TF support

2023-11-16 Thread Melissa Wen
). v2: - update crtc color mgmt if regamma TF differs between states (Joshua) - map inverse EOTF to DC transfer function (Melissa) v3: - update AMDGPU TF list v4: - update comment regarding regamma behavior Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Co-developed-by: Melissa Wen

[PATCH v5 07/32] drm/amd/display: document AMDGPU pre-defined transfer functions

2023-11-16 Thread Melissa Wen
Wentland Co-developed-by: Harry Wentland Signed-off-by: Harry Wentland Signed-off-by: Melissa Wen --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 62 +++ 1 file changed, 62 insertions(+) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_color.c b/drivers/gpu/drm

[PATCH v5 09/32] drm/amd/display: add plane 3D LUT driver-specific properties

2023-11-16 Thread Melissa Wen
-dimension v5: - get lut3d blob correctly (Joshua) - fix doc about 3d-lut dimension size (Sebastian) Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 18 ++ .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 9 +++ .../amd/display/amdgpu_dm

[PATCH v5 12/32] drm/amd/display: add CRTC gamma TF driver-specific property

2023-11-16 Thread Melissa Wen
and comments (Harry) Reviewed-by: Harry Wentland Co-developed-by: Joshua Ashton Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 7 ++ .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 8 +++ .../amd/display/amdgpu_dm/amdgpu_dm_color.c

[PATCH v5 14/32] drm/amd/display: encapsulate atomic regamma operation

2023-11-16 Thread Melissa Wen
LUT programming and better understand each step, detach atomic regamma programming from the crtc colocr updating code. Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 55 --- 1 file changed, 35 insertions(+), 20 deletions

[PATCH v5 11/32] drm/amd/display: add plane blend LUT and TF driver-specific properties

2023-11-16 Thread Melissa Wen
out TF+LUT behavior in the commit and comments (Harry) v5: - get blend blob correctly Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 22 +++ .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 12

[PATCH v5 08/32] drm/amd/display: add plane HDR multiplier driver-specific property

2023-11-16 Thread Melissa Wen
ontent, pass in (203.0 / 80.0). v4: - comment about the PQ TF need for L-to-NL (from Harry's review) Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Co-developed-by: Melissa Wen Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h| 4 .../gpu/d

[PATCH v5 03/32] drm/drm_plane: track color mgmt changes per plane

2023-11-16 Thread Melissa Wen
-by: Harry Wentland Signed-off-by: Melissa Wen --- drivers/gpu/drm/drm_atomic.c | 1 + drivers/gpu/drm/drm_atomic_state_helper.c | 1 + include/drm/drm_plane.h | 7 +++ 3 files changed, 9 insertions(+) diff --git a/drivers/gpu/drm/drm_atomic.c b/drivers/gpu/drm

[PATCH v5 06/32] drm/amd/display: explicitly define EOTF and inverse EOTF

2023-11-16 Thread Melissa Wen
to identity (Pekka) - define the right TFs for BT.709 (Pekka and Harry) - add comment about AMD TF coefficients Suggested-by: Harry Wentland Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 27 +--- .../amd/display/amdgpu_dm

[PATCH v5 10/32] drm/amd/display: add plane shaper LUT and TF driver-specific properties

2023-11-16 Thread Melissa Wen
(Harry) - replace BT709 EOTF by inv OETF v5: - get shaper blob correctly (Joshua) Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 21 .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 11 +++ .../amd/display/amdgpu_dm

[PATCH v5 05/32] drm/amd/display: add plane degamma TF driver-specific property

2023-11-16 Thread Melissa Wen
-off-by: Joshua Ashton Co-developed-by: Melissa Wen Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h | 5 + .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 19 + .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 21 +++ .../amd

[PATCH v5 04/32] drm/amd/display: add driver-specific property for plane degamma LUT

2023-11-16 Thread Melissa Wen
prop description - move private color operations from amdgpu_display to amdgpu_dm_color v5: - get degamma blob correctly (Joshua) Reviewed-by: Harry Wentland Co-developed-by: Joshua Ashton Signed-off-by: Joshua Ashton Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h

[PATCH v5 02/32] drm/drm_property: make replace_property_blob_from_id a DRM helper

2023-11-16 Thread Melissa Wen
Place it in drm_property where drm_property_replace_blob and drm_property_lookup_blob live. Then we can use the DRM helper for driver-specific KMS properties too. Reviewed-by: Harry Wentland Reviewed-by: Liviu Dudau Signed-off-by: Melissa Wen --- drivers/gpu/drm/arm/malidp_crtc.c | 2

[PATCH v5 00/32] drm/amd/display: add AMD driver-specific properties for color mgmt

2023-11-16 Thread Melissa Wen
ies are guarded by cflags `AMD_PRIVATE_COLOR`. Best Regards, Melissa Wen [1] https://github.com/ValveSoftware/gamescope [2] https://store.steampowered.com/news/app/1675200/view/3686804163591367815 [3] https://lore.kernel.org/dri-devel/20230721132431.692158-1-m...@igalia.com Joshua Ashton (14):

[PATCH v5 01/32] drm/drm_mode_object: increase max objects to accommodate new color props

2023-11-16 Thread Melissa Wen
property. Reviewed-by: Harry Wentland Reviewed-by: Simon Ser Signed-off-by: Melissa Wen --- include/drm/drm_mode_object.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/drm/drm_mode_object.h b/include/drm/drm_mode_object.h index 912f1e415685..08d7a7f0188f 100644

Re: [PATCH v4 00/32] drm/amd/display: add AMD driver-specific properties for color mgmt

2023-11-06 Thread Melissa Wen
On 10/06, Sebastian Wick wrote: > On Thu, Oct 05, 2023 at 04:14:55PM -0100, Melissa Wen wrote: > > Hello, > > > > Just another iteration for AMD driver-specific color properties. > > Basically, addressing comments from the previous version. > > > > Rec

Re: [PATCH v4 09/32] drm/amd/display: add plane 3D LUT driver-specific properties

2023-11-06 Thread Melissa Wen
for debugging the issue. BR, Melissa > > Thanks > > - Joshie ✨ > > On 11/2/23 03:48, Joshua Ashton wrote: > > > > > > On 10/5/23 18:15, Melissa Wen wrote: > > > Add 3D LUT property for plane color transformations using a 3D lookup &g

Re: [PATCH v4 09/32] drm/amd/display: add plane 3D LUT driver-specific properties

2023-11-06 Thread Melissa Wen
On 11/02, Joshua Ashton wrote: > > > On 10/5/23 18:15, Melissa Wen wrote: > > Add 3D LUT property for plane color transformations using a 3D lookup > > table. 3D LUT allows for highly accurate and complex color > > transformations and is suitable to adjust the balance

Re: [PATCH v4 09/32] drm/amd/display: add plane 3D LUT driver-specific properties

2023-11-06 Thread Melissa Wen
On 10/06, Sebastian Wick wrote: > On Thu, Oct 05, 2023 at 04:15:04PM -0100, Melissa Wen wrote: > > Add 3D LUT property for plane color transformations using a 3D lookup > > table. 3D LUT allows for highly accurate and complex color > > transformations and is suitable to adjus

[PATCH v4 32/32] drm/amd/display: Add 3x4 CTM support for plane CTM

2023-10-05 Thread Melissa Wen
From: Joshua Ashton Create drm_color_ctm_3x4 to support 3x4-dimension plane CTM matrix and convert DRM CTM to DC CSC float matrix. v3: - rename ctm2 to ctm_3x4 (Harry) Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton --- .../amd/display/amdgpu_dm/amdgpu_dm_color.c | 28

[PATCH v4 31/32] drm/amd/display: add plane CTM support

2023-10-05 Thread Melissa Wen
Map the plane CTM driver-specific property to DC plane, instead of DC stream. The remaining steps to program DPP block are already implemented on DC shared-code. v3: - fix comment about plane and CRTC CTMs priorities (Harry) Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen --- .../gpu

[PATCH v4 30/32] drm/amd/display: add plane CTM driver-specific property

2023-10-05 Thread Melissa Wen
Plane CTM for pre-blending color space conversion. Only enable driver-specific plane CTM property on drivers that support both pre- and post-blending gamut remap matrix, i.e., DCN3+ family. Otherwise it conflits with DRM CRTC CTM property. Reviewed-by: Harry Wentland Signed-off-by: Melissa Wen

[PATCH v4 29/32] drm/amd/display: copy 3D LUT settings from crtc state to stream_update

2023-10-05 Thread Melissa Wen
From: Joshua Ashton When commiting planes, we copy color mgmt resources to the stream state. Do the same for shaper and 3D LUTs. Reviewed-by: Harry Wentland Signed-off-by: Joshua Ashton Co-developed-by: Melissa Wen Signed-off-by: Melissa Wen --- drivers/gpu/drm/amd/display/amdgpu_dm

  1   2   3   4   5   >