[PATCH AUTOSEL 6.12 05/29] drm/amdgpu: use sjt mec fw on gfx943 for sriov

2024-12-20 Thread Sasha Levin
From: Victor Zhao [ Upstream commit 9a4ab400f1fad0e6e8686b8f5fc5376383860ce8 ] Use second jump table in sriov for live migration or mulitple VF support so different VF can load different version of MEC as long as they support sjt Signed-off-by: Victor Zhao Reviewed-by: Yang Wang Signed-off-by

[PATCH AUTOSEL 6.12 06/29] drm/amdkfd: Correct the migration DMA map direction

2024-12-20 Thread Sasha Levin
From: Prike Liang [ Upstream commit 5c3de6b02d38eb9386edf50490e050bb44398e40 ] The SVM DMA device map direction should be set the same as the DMA unmap setting, otherwise the DMA core will report the following warning. Before finialize this solution, there're some discussion on the DMA mapping

[PATCH AUTOSEL 6.6 03/16] drm/amdkfd: Correct the migration DMA map direction

2024-12-20 Thread Sasha Levin
From: Prike Liang [ Upstream commit 5c3de6b02d38eb9386edf50490e050bb44398e40 ] The SVM DMA device map direction should be set the same as the DMA unmap setting, otherwise the DMA core will report the following warning. Before finialize this solution, there're some discussion on the DMA mapping

[PATCH AUTOSEL 6.1 02/12] drm/amdkfd: Correct the migration DMA map direction

2024-12-20 Thread Sasha Levin
From: Prike Liang [ Upstream commit 5c3de6b02d38eb9386edf50490e050bb44398e40 ] The SVM DMA device map direction should be set the same as the DMA unmap setting, otherwise the DMA core will report the following warning. Before finialize this solution, there're some discussion on the DMA mapping

[PATCH AUTOSEL 5.15 2/9] drm/amdkfd: Correct the migration DMA map direction

2024-12-20 Thread Sasha Levin
From: Prike Liang [ Upstream commit 5c3de6b02d38eb9386edf50490e050bb44398e40 ] The SVM DMA device map direction should be set the same as the DMA unmap setting, otherwise the DMA core will report the following warning. Before finialize this solution, there're some discussion on the DMA mapping

Re: [PATCH v3 1/3] drm/amdgpu: Fix out-of-bounds issue in user fence

2024-12-20 Thread Paneer Selvam, Arunpravin
On 12/20/2024 4:08 PM, Christian König wrote: Hi Arun, Am 20.12.24 um 11:34 schrieb Paneer Selvam, Arunpravin: Hi Christian, On 12/19/2024 4:11 PM, Christian König wrote: Am 19.12.24 um 11:38 schrieb Arunpravin Paneer Selvam: Fix out-of-bounds issue in userq fence create when accessin

Re: [PATCH] drm/fourcc: add LINEAR modifiers with an exact pitch alignment

2024-12-20 Thread Brian Starkey
This is getting long, so tl;dr: - Pitch alignment *by itself* is manageable. - Adding constraints in modifiers quickly leads to combinatorial explosion. - drm_fourcc.h explicitly says "it's incorrect to encode pitch alignment in a modifier", for all the reasons Daniel raised. That need

Re: [PATCH v6 9/9] drm/amd/display: Mark dc_fixpt_from_fraction() noinline

2024-12-20 Thread Tiezhu Yang
On 12/19/2024 03:22 AM, Alex Deucher wrote: On Wed, Dec 18, 2024 at 2:18 PM Josh Poimboeuf wrote: On Wed, Dec 18, 2024 at 10:36:00PM +0800, Huacai Chen wrote: Hi, Tiezhu, On Tue, Dec 17, 2024 at 9:50 AM Tiezhu Yang wrote: When compiling with Clang on LoongArch, there exists the following

Re: [PATCH v6 9/9] drm/amd/display: Mark dc_fixpt_from_fraction() noinline

2024-12-20 Thread Nathan Chancellor
On Fri, Dec 20, 2024 at 11:31:00AM +0100, Peter Zijlstra wrote: > Also, curse the DRM Makefiles, you can't do: > > make drivers/gpu/drm/amd/display/dc/basics/fixpt31_32.s Small tip: You can get the path of the target by building drivers/gpu/drm/amd/amdgpu/ and finding it in the output. In this

Re: [PATCH] drm/fourcc: add LINEAR modifiers with an exact pitch alignment

2024-12-20 Thread Marek Olšák
> > * Modifiers must uniquely encode buffer layout. In other words, a buffer > must > * match only a single modifier. > That sentence is misleading and impossible to meet. Specifications are sometimes changed to reflect the overwhelming reality. Multiple modifiers can represent identical layouts

Re: [PATCH 1/1] drm/amdgpu: Use device wedged event

2024-12-20 Thread kernel test robot
Hi André, kernel test robot noticed the following build errors: [auto build test ERROR on linus/master] [also build test ERROR on drm-intel/for-linux-next drm-intel/for-linux-next-fixes drm-tip/drm-tip v6.13-rc3 next-20241220] [If your patch is applied to the wrong git tree, kindly drop us a

Re: [PATCH v6 9/9] drm/amd/display: Mark dc_fixpt_from_fraction() noinline

2024-12-20 Thread Peter Zijlstra
On Fri, Dec 20, 2024 at 01:02:18PM +0800, Tiezhu Yang wrote: > 2. For x86 > > I tested with LLVM 19.1.6 and the latest mainline LLVM, the test result > is same with LoongArch. Debian's clang-19 is 19.1.5. > (1) objdump info with LLVM release version 19.1.6: Please always use -r, that's ever so

Re: [PATCH v3 1/3] drm/amdgpu: Fix out-of-bounds issue in user fence

2024-12-20 Thread Paneer Selvam, Arunpravin
Hi Christian, On 12/19/2024 4:11 PM, Christian König wrote: Am 19.12.24 um 11:38 schrieb Arunpravin Paneer Selvam: Fix out-of-bounds issue in userq fence create when accessing the userq xa structure. Added a lock to protect the race condition. v2:(Christian)    - Acquire xa lock only for th

Re: [PATCH 2/2] drm/buddy: Add a testcase to verify the multiroot fini

2024-12-20 Thread Paneer Selvam, Arunpravin
Hi Matthew, On 12/16/2024 11:52 PM, Matthew Auld wrote: On 16/12/2024 13:07, Arunpravin Paneer Selvam wrote: - Added a testcase to verify the multiroot force merge fini. - Added a new field in_use to track the mm freed status. Signed-off-by: Arunpravin Paneer Selvam Signed-off-by: Lin.Cao

Re: [PATCH v3 1/3] drm/amdgpu: Fix out-of-bounds issue in user fence

2024-12-20 Thread Christian König
Hi Arun, Am 20.12.24 um 11:34 schrieb Paneer Selvam, Arunpravin: Hi Christian, On 12/19/2024 4:11 PM, Christian König wrote: Am 19.12.24 um 11:38 schrieb Arunpravin Paneer Selvam: Fix out-of-bounds issue in userq fence create when accessing the userq xa structure. Added a lock to protect t

Re: [PATCH 1/1] drm/amdgpu: Use device wedged event

2024-12-20 Thread kernel test robot
Hi André, kernel test robot noticed the following build errors: [auto build test ERROR on linus/master] [also build test ERROR on v6.13-rc3 next-20241220] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as

Re: [PATCH] drm/fourcc: add LINEAR modifiers with an exact pitch alignment

2024-12-20 Thread Simona Vetter
On Thu, Dec 19, 2024 at 05:09:33PM +0100, Michel Dänzer wrote: > On 2024-12-19 10:02, Daniel Stone wrote: > > > > How this would be used in practice is also way too underdocumented. We > > need to document that exact-round-up 64b is more restrictive than > > any-multiple-of 64b is more restrictive

Re: [PATCH] drm/fourcc: add LINEAR modifiers with an exact pitch alignment

2024-12-20 Thread Simona Vetter
On Fri, Dec 20, 2024 at 09:24:59AM -0500, Marek Olšák wrote: > > > > * Modifiers must uniquely encode buffer layout. In other words, a buffer > > must > > * match only a single modifier. > > > > That sentence is misleading and impossible to meet. Specifications are > sometimes changed to reflect

[PATCH 05/28] drm/amd/display: Add DP required HBlank size calc to link interface

2024-12-20 Thread Roman.Li
From: George Shen [Why] Some features, such as HBlank expansion/reduction, needs to know how much HBlank is required to support basic audio. [How] Add interface to link to calculate required HBlank size for a given link + timing combination to support basic audio (i.e. 2-channel 48KHz). Reviewe

[PATCH 03/28] drm/amd/display: Cleanup outdated interfaces in dcn401_clk_mgr

2024-12-20 Thread Roman.Li
From: Dillon Varone [WHY&HOW] - Remove legacy update clocks sequence - FCLK P-State allow message is not required Reviewed-by: Alvin Lee Signed-off-by: Dillon Varone Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- .../dc/clk_mgr/dcn401/dcn401_clk_mgr.c| 240 ++

[PATCH 04/28] drm/amd/display: Parse RECEIVE_PORT0_CAP capabilities from DPCD

2024-12-20 Thread Roman.Li
From: George Shen [Why] DPCD register RECEIVE_PORT0_CAP contains HBlank expansion/reduction capabilities of a DP device. These capabilities are required to enable HBlank expansion/reduction logic. [How] Read raw RECEIVE_PORT0_CAP register values and store parsed fields. Reviewed-by: Wenjing Liu

[PATCH 06/28] drm/amd/display: Add expanded HBlank field to dc_crtc_timing

2024-12-20 Thread Roman.Li
From: George Shen [Why] For DP HBlank expansion/reduction, the HBlank parameters of the original EDID timing needs to be notified to the sink in order for the timing to be reduced back to the original HBlank size. [How] Add parameter in dc_crtc_timing to track the increased HBlank. Reviewed-by:

[PATCH 00/28] DC Patches December 20, 2024

2024-12-20 Thread Roman.Li
From: Roman Li - Improvements for DP, Replay/PSR, DML, SPL, DCN32, DCN35, DCN401 - Extended logging for DSC, VABC and stream crc - Optimization for cursor position updates Aric Cyr (1): drm/amd/display: Optimize cursor position updates Aurabindo Pillai (1): drm/amd/display: Add guards ar

[PATCH 07/28] drm/amd/display: Add support for setting multiple CRC windows in dc

2024-12-20 Thread Roman.Li
From: Wayne Lin [Why & How] Have to support multiple CRC windows setting to dmub. Add new dmub forward functions for supporting/forwarding multiple crc windows setting to dmub. Reviewed-by: HaoPing Liu Signed-off-by: Wayne Lin Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- drivers/gp

[PATCH 08/28] drm/amd/display: Extend dc_stream_get_crc to support 2nd crc engine

2024-12-20 Thread Roman.Li
From: Wayne Lin [Why & How] Since now we can set multiple crc windows for secure display, add a new input parameter for dc_stream_get_crc to indicate to fetch crc from which crc engine. Reviewed-by: HaoPing Liu Signed-off-by: Wayne Lin Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- .

[PATCH 25/28] drm/amd/display: Clean up SPL code

2024-12-20 Thread Roman.Li
From: Samson Tam [Why & How] Use helper functions for checking formats Apply cositing offset in rotation case Reviewed-by: Navid Assadian Signed-off-by: Samson Tam Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- drivers/gpu/drm/amd/display/dc/spl/dc_spl.c | 88 ++--- 1

[PATCH 23/28] drm/amd/display: Add 6bpc RGB case for dcn32 output bpp calculations

2024-12-20 Thread Roman.Li
From: George Shen [Why] Current DCN32 calculation doesn't consider RGB 6bpc for the DP case. This results in an invalid output bpp being calculated when DSC is not enabled in the configuration, failing the mode validation. [How] Add special case to handle 6bpc RGB in the output bpp calculation.

[PATCH 16/28] drm/amd/display: Update dc_tiling_info union to structure

2024-12-20 Thread Roman.Li
From: Karthi Kandasamy [WHY] The `dc_tiling_info` union previously did not have a field to specify the active GFX format, assuming only one format would be used per DCN version. from DCN4+, support for switching between different GFX formats is introduced, requiring a way to track which format is

[PATCH 28/28] drm/amd/display: Promote DC to 3.2.315

2024-12-20 Thread Roman.Li
From: Martin Leung This version brings along the following: - Add Interface to Dump DSC Caps from dm - Add DP required HBlank size calc to link interface - Add 6bpc RGB case for dcn32 output bpp calculations - Add VC for VESA Aux Backlight Control - Add support for setting multiple CRC windows in

[PATCH 21/28] drm/amd/display: Fix PSR-SU not support but still call the amdgpu_dm_psr_enable

2024-12-20 Thread Roman.Li
From: Tom Chung [Why] The enum DC_PSR_VERSION_SU_1 of psr_version is 1 and DC_PSR_VERSION_UNSUPPORTED is 0x. The original code may has chance trigger the amdgpu_dm_psr_enable() while psr version is set to DC_PSR_VERSION_UNSUPPORTED. [How] Modify the condition to psr->psr_version == DC_P

[PATCH 15/28] drm/amd/display: modify init dc_power_state

2024-12-20 Thread Roman.Li
From: Brandon Syu [why] initialize the power state for dc use, but dc_set_power_state it not called at D3. It would cause can't recognize last power state [how] remove initialize the power state for dc use, it is not necessary. Reviewed-by: Nicholas Kazlauskas Signed-off-by: Brandon Syu Signe

[PATCH 19/28] drm/amd/display: Optimize cursor position updates

2024-12-20 Thread Roman.Li
From: Aric Cyr [why] Updating the cursor enablement register can be a slow operation and accumulates when high polling rate cursors cause frequent updates asynchronously to the cursor position. [how] Since the cursor enable bit is cached there is no need to update the enablement register if ther

[PATCH 22/28] drm/amd/display: Disable replay and psr while VRR is enabled

2024-12-20 Thread Roman.Li
From: Tom Chung [Why] Replay and PSR will cause some video corruption while VRR is enabled. [How] 1. Disable the Replay and PSR while VRR is enabled. 2. Change the amdgpu_dm_crtc_vrr_active() parameter to const. Because the function will only read data from dm_crtc_state. Reviewed-by: Sun pe

[PATCH 13/28] drm/amd/display: Implement Replay Low Hz Visual Confirm

2024-12-20 Thread Roman.Li
From: "Dennis.Chan" [why] Add new Visual confirm color for Replay Low Hz. Reviewed-by: Robin Chen Signed-off-by: Dennis.Chan Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- drivers/gpu/drm/amd/display/dc/dc_types.h | 11 ++-- .../dc/link/protocols/link_dp_irq_handler.c | 2 + .

[PATCH 12/28] drm/amd/display: Add Interface to Dump DSC Caps from dm

2024-12-20 Thread Roman.Li
From: Fangzhi Zuo No common dsc params found between encoder and decoder is one of the reason that could prevent dsc from properly enabled. Dump the params to a specific timing to help locate possible invalid dsc params in either encoder or decoder side. Reviewed-by: Aurabindo Pillai Signed-of

[PATCH 20/28] drm/amd/display: Add HBlank reduction DPCD write to DPMS sequence

2024-12-20 Thread Roman.Li
From: George Shen [Why] Certain small HBlank timings may not have a large enough HBlank to support audio when low bpp DSC is enabled. HBlank expansion by the source can solve this problem, but requires the branch/sink to support HBlank reduction. [How] Update DPMS sequence to call DM to perform

[PATCH 17/28] drm/amd/display: Ensure correct GFX tiling info passed to DML

2024-12-20 Thread Roman.Li
From: Karthi Kandasamy [Why] To ensure DML validation receives the correct tiling information, such as swizzle mode or array mode, based on the active GFX format [How] - For new GFX format passed swizzle_mode to DML. - For legacy GFX format passed array_mode to DML. - Dynamically determined the

[PATCH 24/28] drm/amd/display: Add check for granularity in dml ceil/floor helpers

2024-12-20 Thread Roman.Li
From: Roman Li [Why] Wrapper functions for dcn_bw_ceil2() and dcn_bw_floor2() should check for granularity is non zero to avoid assert and divide-by-zero error in dcn_bw_ functions. [How] Add check for granularity 0. Cc: Mario Limonciello Cc: sta...@vger.kernel.org Reviewed-by: Alvin Lee Sign

[PATCH 14/28] drm/amd/display: have pretrain for dpia

2024-12-20 Thread Roman.Li
From: Peichen Huang [WHY] We like to have pretrain for dpia link so that dp and dp tunneling have aligned behavior. The Main difficult for dpia pretrain is that encoder can not get corresponded dpia port when link detection in current implementation. [HOW] 1. create enable/disable dpia output fu

[PATCH 18/28] drm/amd/display: fix init_adj offset for cositing in SPL

2024-12-20 Thread Roman.Li
From: Samson Tam [Why & How] init_adj offset is applied when cosited not interstitial Adjust cositing offset in SPL Reviewed-by: Jun Lei Signed-off-by: Samson Tam Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- .../amd/display/dc/resource/dcn401/dcn401_resource.c | 2 +- drivers/gpu

[PATCH 27/28] drm/amd/display: Extend capability to get multiple ROI CRCs

2024-12-20 Thread Roman.Li
From: Wayne Lin [Why & How] We already extend our dm, dc and dmub to support setting of multiple CRC instances, now extend the capability to return back the ROI/CRC pair result from psp by specifying activated ROI instances. Reviewed-by: HaoPing Liu Signed-off-by: Wayne Lin Signed-off-by: Roma

[PATCH 01/28] drm/amd/display: update sequential pg logic DCN35

2024-12-20 Thread Roman.Li
From: Yihan Zhu [WHY & HOW] No check for HUBP/DPP power gating when DSC instance is still running. Avoid HUBP/DPP to power gate when corresponding DSC block is still running in the power gating calculation. Reviewed-by: Nicholas Kazlauskas Reviewed-by: Duncan Ma Signed-off-by: Yihan Zhu Sig

[PATCH 02/28] drm/amd/display: power up all gating blocks when releasing hw DCN35

2024-12-20 Thread Roman.Li
From: Yihan Zhu [WHY & HOW] Driver disable will deallocate framebuffer to reset IPS state, this will cause IPS start with INIT state to blindly power gate ONO region to break power sequence. All the gating blocks should be powered up when releasing hw to ensure all the power optimizations are

[PATCH 11/28] drm/amd/display: Add guards around MAX/MIN

2024-12-20 Thread Roman.Li
From: Aurabindo Pillai MAX/MIN macros maybe defined already, hence add a guard around them to prevent errors that complain about redefinition like: drivers/gpu/drm/amd/amdgpu/../dal-dev/modules/hdcp/hdcp_ddc.c:31: error: "MIN" redefined [-Werror] 31 | #define MIN(a, b) ((a) < (b) ? (a) : (b)

[PATCH 09/28] drm/amd/display: Adjust dm to use supported interfaces for setting multiple crc windows

2024-12-20 Thread Roman.Li
From: Wayne Lin [Why & How] We actually have the capability to calculate independent CRC for 2 crc window at the same time. Extend dm with the capability by having array to configure/maintain multiple crc windows. Add the flexibility but use 1st CRC instance only for now. Can change to use the 2n

[PATCH 26/28] drm/amd/display: Add VC for VESA Aux Backlight Control

2024-12-20 Thread Roman.Li
From: Iswara Nagulendran [WHY] There is no way to distinguish the static backlight control type being used and the VABC support without the use of a debugger or reading DPCD registers. [HOW] Add Visual Confirm support for VESA Aux-based Backlight Control. Reviewed-by: Harry Vanzylldejong Signe

[PATCH 10/28] drm/amd/display: correct type mismatches in comparisons in DML2

2024-12-20 Thread Roman.Li
From: Natanel Roizenman [Why] Comparisons were made between unsigned char and unsigned int. [How] Corrected by changing variable types. Reviewed-by: Nicholas Kazlauskas Signed-off-by: Natanel Roizenman Signed-off-by: Roman Li Tested-by: Daniel Wheeler --- .../dml2/dml21/src/dml2_dpmm/dml2_