Re: [PATCH 2/2] drm/amdgpu: fix fence calculation

2021-05-12 Thread Christian König
And BTW amdgpu_ctx_fence_time() should probably be static. Christian. Am 12.05.21 um 08:55 schrieb Christian König: In this case amdgpu_ctx_fence_time should probably be changed to initialize the variable itself. That is really bad coding style otherwise. Christian. Am 11.05.21 um 20:14

Re: [PATCH 2/2] drm/amdgpu: fix fence calculation

2021-05-12 Thread Christian König
In this case amdgpu_ctx_fence_time should probably be changed to initialize the variable itself. That is really bad coding style otherwise. Christian. Am 11.05.21 um 20:14 schrieb Nieto, David M: [AMD Official Use Only - Internal Distribution Only] The local variables need to be

Re: [PATCH] drm/amdgpu: flush TLB if valid PDE turns into PTE

2021-05-12 Thread Christian König
Am 12.05.21 um 14:34 schrieb Philip Yang: Mapping huge page, 2MB aligned address with 2MB size, uses PDE0 as PTE. If previously valid PDE0, PDE0.V=1 and PDE0.P=0 turns into PTE, this requires TLB flush, otherwise page table walker will not read updated PDE0. Change page table update mapping

Re: New uAPI for color management proposal and feedback request

2021-05-12 Thread Simon Ser
On Wednesday, May 12th, 2021 at 3:04 PM, Ville Syrjälä wrote: > > Adoption: > > > > A KDE dev wants to implement the settings in the KDE settings GUI: > > > > https://gitlab.freedesktop.org/drm/amd/-/issues/476#note_912370 > > > > Tuxedo Computers (my employer) wants to implement the settings

New uAPI for color management proposal and feedback request

2021-05-12 Thread Werner Sembach
Hello, In addition to the existing "max bpc", and "Broadcast RGB/output_csc" drm properties I propose 4 new properties: "preferred pixel encoding", "active color depth", "active color range", and "active pixel encoding" Motivation: Current monitors have a variety pixel encodings available:

Patch "drm/amd/display: Reject non-zero src_y and src_x for video planes" has been added to the 5.4-stable tree

2021-05-12 Thread gregkh
This is a note to let you know that I've just added the patch titled drm/amd/display: Reject non-zero src_y and src_x for video planes to the 5.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Re: [5.12 regression] ttm->pages NULL dereference with radeon driver

2021-05-12 Thread Dennis Foster
Hi Christian, I can confirm that the patch provided fixes the issue in kernel version 5.12.2 Thank you. On Wed, May 12, 2021 at 6:21 AM Christian König wrote: > > Hi guys, > > adding a few people who ran into the problem as well and opened a kernel > bug. > > Am 07.05.21 um 17:11 schrieb

[PATCH] drm/amd/display: Fix duplicate included hubp.h

2021-05-12 Thread Jiapeng Chong
Clean up the following includecheck warning: ./drivers/gpu/drm/amd/display/dc/core/dc.c: hubp.h is included more than once. Reported-by: Abaci Robot Signed-off-by: Jiapeng Chong --- drivers/gpu/drm/amd/display/dc/core/dc.c | 1 - 1 file changed, 1 deletion(-) diff --git

Patch "drm/amd/display: Reject non-zero src_y and src_x for video planes" has been added to the 5.11-stable tree

2021-05-12 Thread gregkh
This is a note to let you know that I've just added the patch titled drm/amd/display: Reject non-zero src_y and src_x for video planes to the 5.11-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Re: [PATCH] drm/amdgpu: Register bad page handler for Aldebaran

2021-05-12 Thread Borislav Petkov
Hi, so this is a drive-by review using the lore.kernel.org mail because I wasn't CCed on this. On Tue, May 11, 2021 at 09:30:58PM -0400, Mukul Joshi wrote: > +static int amdgpu_bad_page_notifier(struct notifier_block *nb, > + unsigned long val, void *data) > +{ >

Patch "drm/amd/display: Reject non-zero src_y and src_x for video planes" has been added to the 5.10-stable tree

2021-05-12 Thread gregkh
This is a note to let you know that I've just added the patch titled drm/amd/display: Reject non-zero src_y and src_x for video planes to the 5.10-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

Patch "drm/amd/display: Reject non-zero src_y and src_x for video planes" has been added to the 5.12-stable tree

2021-05-12 Thread gregkh
This is a note to let you know that I've just added the patch titled drm/amd/display: Reject non-zero src_y and src_x for video planes to the 5.12-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the

[PATCH] drm/amdgpu: flush TLB if valid PDE turns into PTE

2021-05-12 Thread Philip Yang
Mapping huge page, 2MB aligned address with 2MB size, uses PDE0 as PTE. If previously valid PDE0, PDE0.V=1 and PDE0.P=0 turns into PTE, this requires TLB flush, otherwise page table walker will not read updated PDE0. Change page table update mapping to return free_table flag to indicate the

Re: [5.12 regression] ttm->pages NULL dereference with radeon driver

2021-05-12 Thread Christian König
Hi guys, adding a few people who ran into the problem as well and opened a kernel bug. Am 07.05.21 um 17:11 schrieb Christian König: Hi Takashi, Am 07.05.21 um 17:08 schrieb Takashi Iwai: Hi, we've received a regression report showing NULL dereference Oops with radeon driver on 5.12

Re: New uAPI for color management proposal and feedback request

2021-05-12 Thread Ville Syrjälä
On Wed, May 12, 2021 at 02:06:56PM +0200, Werner Sembach wrote: > Hello, > > In addition to the existing "max bpc", and "Broadcast RGB/output_csc" drm > properties I propose 4 new properties: > "preferred pixel encoding", "active color depth", "active color range", and > "active pixel encoding"

[PATCH 2/2] drm/amdgpu: Poll of RAS errors asynchronously

2021-05-12 Thread Luben Tuikov
When using Vega 20 with RAS support and RAS is enabled, the system interactivity is extremely slow, to the point of being unusable. After debugging, it was determined that this is due to the polling loop performed for AMDGPU_CTX_OP_QUERY_STATE2 under amdgpu_ctx_ioctl(), which seems to be executed

[PATCH 1/2] drm/amdgpu: Don't query CE and UE errors

2021-05-12 Thread Luben Tuikov
On QUERY2 IOCTL don't query counts of correctable and uncorrectable errors, since when RAS is enabled and supported on Vega20 server boards, this takes insurmountably long time, in O(n^3), which slows the system down to the point of it being unusable when we have GUI up. Fixes: ae363a212b14

[PATCH 2/3] drm/amdkfd: skip invalid pages during migrations

2021-05-12 Thread Alex Sierra
Invalid pages can be the result of pages that have been migrated already due to copy-on-write procedure or pages that were never migrated to VRAM in first place. This is not an issue anymore, as pranges now support mixed memory domains (CPU/GPU). Signed-off-by: Alex Sierra ---

[PATCH 3/3] drm/amdkfd: add invalid pages debug at vram migration

2021-05-12 Thread Alex Sierra
This is for debug purposes only. It conditionally generates partial migrations to test mixed CPU/GPU memory domain pages in a prange easily. Signed-off-by: Alex Sierra --- drivers/gpu/drm/amd/amdkfd/kfd_migrate.c | 14 ++ 1 file changed, 14 insertions(+) diff --git

[PATCH 1/3] drm/amdkfd: classify and map mixed svm range pages in GPU

2021-05-12 Thread Alex Sierra
[Why] svm ranges can have mixed pages from device or system memory. A good example is, after a prange has been allocated in VRAM and a copy-on-write is triggered by a fork. This invalidates some pages inside the prange. Endding up in mixed pages. [How] By classifying each page inside a prange,

[PATCH AUTOSEL 5.10 28/34] drm/amd/display: Fix two cursor duplication when using overlay

2021-05-12 Thread Sasha Levin
From: Rodrigo Siqueira [ Upstream commit 16e9b3e58bc3fce7391539e0eb3fd167cbf9951f ] Our driver supports overlay planes, and as expected, some userspace compositor takes advantage of these features. If the userspace is not enabling the cursor, they can use multiple planes as they please.

[PATCH AUTOSEL 5.10 24/34] amdgpu/pm: Prevent force of DCEFCLK on NAVI10 and SIENNA_CICHLID

2021-05-12 Thread Sasha Levin
From: Darren Powell [ Upstream commit b117b3964f38a988cb79825950dbd607c02237f3 ] Writing to dcefclk causes the gpu to become unresponsive, and requires a reboot. Patch ignores a .force_clk_levels(SMU_DCEFCLK) call and issues an info message. Signed-off-by: Darren Powell Reviewed-by: Kenneth

[PATCH v2] drm/amdgpu: flush TLB if valid PDE turns into PTE

2021-05-12 Thread Philip Yang
Mapping huge page, 2MB aligned address with 2MB size, uses PDE0 as PTE. If previously valid PDE0, PDE0.V=1 and PDE0.P=0 turns into PTE, this requires TLB flush, otherwise page table walker will not read updated PDE0. Change page table update mapping to return free_table flag to indicate the

[PATCH AUTOSEL 5.11 25/35] amdgpu/pm: Prevent force of DCEFCLK on NAVI10 and SIENNA_CICHLID

2021-05-12 Thread Sasha Levin
From: Darren Powell [ Upstream commit b117b3964f38a988cb79825950dbd607c02237f3 ] Writing to dcefclk causes the gpu to become unresponsive, and requires a reboot. Patch ignores a .force_clk_levels(SMU_DCEFCLK) call and issues an info message. Signed-off-by: Darren Powell Reviewed-by: Kenneth

[PATCH AUTOSEL 5.11 29/35] drm/amd/display: Fix two cursor duplication when using overlay

2021-05-12 Thread Sasha Levin
From: Rodrigo Siqueira [ Upstream commit 16e9b3e58bc3fce7391539e0eb3fd167cbf9951f ] Our driver supports overlay planes, and as expected, some userspace compositor takes advantage of these features. If the userspace is not enabling the cursor, they can use multiple planes as they please.

Re: [PATCH] drm/amdgpu: flush TLB if valid PDE turns into PTE

2021-05-12 Thread philip yang
On 2021-05-12 11:54 a.m., Felix Kuehling wrote: Am 2021-05-12 um 8:38 a.m. schrieb Christian König: Am 12.05.21 um 14:34 schrieb Philip Yang: Mapping huge page, 2MB aligned address with 2MB size, uses PDE0 as PTE. If

[PATCH 5.12 080/677] drm/amd/display: Reject non-zero src_y and src_x for video planes

2021-05-12 Thread Greg Kroah-Hartman
From: Harry Wentland commit d89f6048bdcb6a56abb396c584747d5eeae650db upstream. [Why] This hasn't been well tested and leads to complete system hangs on DCN1 based systems, possibly others. The system hang can be reproduced by gesturing the video on the YouTube Android app on ChromeOS into full

[PATCH 42/49] drm/amd/display: Initial DC support for Beige Goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why] Add Beige Goby (DCN303) resource, irq service, & dmub loader. v2: fix nbio include (Alex) Signed-off-by: Chris Park Signed-off-by: Aurabindo Pillai Acked-by: Alex Deucher Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/Makefile |1 +

[PATCH 09/49] drm/amd/amdgpu: add common ip block for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Same as dimgrey_cavefish v2: fix comments typo Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 3 +++ 1 file changed, 3 insertions(+) diff --git

[PATCH 14/49] drm/amd/amdgpu: configure beige_goby gfx according to gfx 10.3's definition

2021-05-12 Thread Alex Deucher
From: Chengming Gui The gfx version of beige_goby is 10.3, identical to sienna_cichlid, follow the way of sienna_cichlid Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 9 + 1

[PATCH 47/49] drm/amd/display: Update DCN303 SR Exit Latency

2021-05-12 Thread Alex Deucher
From: Joshua Aberback [Why] This update was made for DCN30, but it is needed for DCN303 as well Signed-off-by: Joshua Aberback Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/dcn303/dcn303_resource.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH 40/49] drm/amd/amdgpu: Enable memory training for psp HW_REV#11.0.13

2021-05-12 Thread Alex Deucher
From: Chengming Gui Enable memory training on newer hw revisions. Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_atomfirmware.c | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH 31/49] drm/amdgpu: enable athub/mmhub PG for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable athub/mmhub power gating for beige_goby. Signed-off-by: Tao Zhou Reviewed-by: Jiansong Chen Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 48/49] drm/amd/display: Enable HDCP for Beige Goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why] Add beige_goby_ta.bin to module firmware table and call psp init for TA Signed-off-by: Aurabindo Pillai Acked-by: Alex Deucher Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/psp_v11_0.c | 4 1 file changed, 4 insertions(+) diff --git

[PATCH 46/49] drm/amd/display: Add callback for update_soc_for_wm_a for dcn303

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why] Absense of this callback causes null pointer dereference. Add the corresponding callback in dcn303 resources. Fixes: 8ea9608379 ("drm/amd/display: fix dcn3+ bw validation soc param update sequence") Signed-off-by: Aurabindo Pillai Signed-off-by: Alex Deucher ---

[PATCH 45/49] drm/amd/amdgpu: Enable DCN IP init for Beige Goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why] Adds DCN IP block initialization for Beige Goby Signed-off-by: Aurabindo Pillai Acked-by: Alex Deucher Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 1 + drivers/gpu/drm/amd/amdgpu/nv.c| 4 2 files changed, 5

[PATCH 49/49] drm/amd/display: enable idle optimizations for beige goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why] MALL requires idle optimizations to be enabled. This enables MALL feature on dcn303 Signed-off-by: Aurabindo Pillai Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc/dcn303/dcn303_resource.c | 1 + 1 file changed, 1

[PATCH 07/49] drm/amd/amdgpu: initialize IP offset for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add ip offset definition for beige_goby and initialize it v2: squash in fixes (Alex) Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/Makefile |3 +-

[PATCH 43/49] drm/amd/display: Edit license info for beige goby DC files

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [How] * Add MIT license to all new files as SPDX tag. * Fix copyright year Signed-off-by: Aurabindo Pillai Signed-off-by: Alex Deucher --- .../gpu/drm/amd/display/dc/dcn303/Makefile| 8 ++- .../drm/amd/display/dc/dcn303/dcn303_dccg.h | 22 ++-

[PATCH 44/49] drm/amd/display: Add DM support for Beige Goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why] Adds the firmware definition and missing cases statement hooks for Beige Goby support in AMDGPU DM. Signed-off-by: Aurabindo Pillai Acked-by: Alex Deucher Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 14 ++ 1

[PATCH 05/49] drm/amd/amdgpu: add gmc support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Same as dimgrey_cavefish Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gmc_v10_0.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v10_0.c

[PATCH 08/49] drm/amd/amdgpu: add mmhub support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Same as dimgrey_cavefish Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c | 6 ++ 1 file changed, 6 insertions(+) diff --git

[PATCH 36/49] drm/amdgpu: add cgls for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable cgls to improve the runtime power efficiency. Signed-off-by: Tao Zhou Reviewed-by: Jack Gui Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 38/49] drm/amd/amdgpu: Enable gfxoff for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Enable gfxoff in driver side based on SMC#73.3 v2: fix typo 'Eanble' --> 'Enable' Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 1 + drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c | 1

[PATCH 13/49] drm/amd/amdgpu: add sdma ip block for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Enable sdma block for beige_goby, same as sienna_cichlid v2: share the same setting of sdma instance num with vangogh Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Suggested-by: Alexander Deucher Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher ---

[PATCH 34/49] drm/amdgpu: enable ih CG for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable ih clock gating for beige_goby. Signed-off-by: Tao Zhou Reviewed-by: Jiansong Chen Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 06/49] drm/amd/amdgpu: add common support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add external id and set clock gating for beige_goby Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 6 ++ 1 file changed, 6 insertions(+) diff --git

[PATCH 33/49] drm/amdgpu: enable hdp CG and LS for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable hdp MGCG and LS for beige_goby. Signed-off-by: Tao Zhou Reviewed-by: Jiansong Chen Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 30/49] drm/amdgpu: support athub cg setting for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable athub cg for beige_goby. Signed-off-by: Tao Zhou Reviewed-by: Jiansong Chen Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/athub_v2_1.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/athub_v2_1.c

[PATCH 35/49] drm/amdgpu: enabled VCN3.0 CG for BEIGE GOBY

2021-05-12 Thread Alex Deucher
From: Veerabadhran Gopalakrishnan Enable VCN CG for BEIGE GOBY Signed-off-by: Veerabadhran Gopalakrishnan Reviewed-by: Leo Liu Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git

[PATCH 39/49] drm/amdgpu: fix GCR_GENERAL_CNTL offset for beige_goby

2021-05-12 Thread Alex Deucher
From: Jiansong Chen beige_goby has similar gc_10_3 ip with sienna_cichlid, so follow its registers offset setting. Signed-off-by: Jiansong Chen Reviewed-by: Jack Gui Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[PATCH 37/49] drm/amd/pm: Use the PPTable from VBIOS for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Switch from softPPTable to VBIOS PPTable. v2: drop extra parens (Alex) Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git

[PATCH 11/49] drm/amd/amdgpu: add ih ip block for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Enable ih block for beige_goby, same as dimgrey_cavefish Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/navi10_ih.c | 1 + drivers/gpu/drm/amd/amdgpu/nv.c| 1 + 2 files

Re: New uAPI for color management proposal and feedback request

2021-05-12 Thread Alex Deucher
On Wed, May 12, 2021 at 9:04 AM Ville Syrjälä wrote: > > On Wed, May 12, 2021 at 02:06:56PM +0200, Werner Sembach wrote: > > Hello, > > > > In addition to the existing "max bpc", and "Broadcast RGB/output_csc" drm > > properties I propose 4 new properties: > > "preferred pixel encoding", "active

[PATCH AUTOSEL 5.4 18/23] drm/amd/display: Fix two cursor duplication when using overlay

2021-05-12 Thread Sasha Levin
From: Rodrigo Siqueira [ Upstream commit 16e9b3e58bc3fce7391539e0eb3fd167cbf9951f ] Our driver supports overlay planes, and as expected, some userspace compositor takes advantage of these features. If the userspace is not enabling the cursor, they can use multiple planes as they please.

[PATCH 00/49] Initial Beige Goby Support

2021-05-12 Thread Alex Deucher
These patches enable initial support for Beige Goby, a new GPU from AMD. This includes support for GFX, compute, multimedia, display, and power management. Due to the size of the new register headers (patch 41), I didn't send them out, but you can view the entire patch set in my git tree here:

[PATCH 03/49] drm/amd/amdgpu: set asic family and ip blocks for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Same as navi series Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

[PATCH 10/49] drm/amd/amdgpu: add gmc ip block for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Enable gmc block for beige_goby, same as sienna_cichlid Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gmc_v10_0.c | 1 + drivers/gpu/drm/amd/amdgpu/nv.c| 1 + 2 files

[PATCH 29/49] drm/amdgpu: enable GFX clock gating for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable GFX MGCG, CGCG and 3DCG for beige_goby. Signed-off-by: Tao Zhou Reviewed-by: Jiansong Chen Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 02/49] drm/amd/amdgpu: set fw load type for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Use direct load for beige_goby Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 2 ++ 1 file changed, 2 insertions(+) diff --git

[PATCH 12/49] drm/amd/amdgpu: add gfx ip block for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Enable gfx block for beige_goby, same as dimgrey_cavefish Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 5 + drivers/gpu/drm/amd/amdgpu/nv.c| 1 + 2

[PATCH 17/49] drm/amd/amdgpu: Use IP discovery table for beige goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Rather than gpu info firmware. Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH 19/49] drm/amdkfd: add kfd2kgd funcs for beige_goby kfd support

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add the function pointer. Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdkfd/kfd_device.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_device.c

[PATCH 20/49] drm/amd/amdgpu: add smu support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Use soft-pptable for beige_goby v2: fix format Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Reviewed-by: Hawking Zhang Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c| 3 +++ drivers/gpu/drm/amd/pm/inc/smu_v11_0.h | 1 +

[PATCH 21/49] drm/amd/amdgpu: add psp support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui add general PSP support for beige_goby Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Reviewed-by: Hawking Zhang Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 3 +--

[PATCH 27/49] drm/amd/pm: update smu11 driver interface header for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Use new struct name to identify beige_goby pptable due to extra added fields. v2: squash in updates (Alex) Signed-off-by: Chengming Gui Reviewed-by: Jiansong Chen Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- .../pm/inc/smu11_driver_if_sienna_cichlid.h | 366

[PATCH 24/49] drm/amdgpu: Enable VCN for Beige Goby

2021-05-12 Thread Alex Deucher
From: Veerabadhran Gopalakrishnan Enabled VCN support for Beige Goby chip Signed-off-by: Veerabadhran Gopalakrishnan Reviewed-by: Leo Liu Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 8 ++ drivers/gpu/drm/amd/amdgpu/nv.c | 4 +-

[PATCH 26/49] drm/amd/pm: add mode1 support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add mode1 reset as the default reset method for beige_goby Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 16/49] drm/amd/amdgpu: support cp_fw_write_wait for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Same as dimgrey_cavefish to support WAIT_REG_MEM packet. Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH 04/49] drm/amd/amdgpu: add support for beige_goby firmware

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add support for beige_goby cp/rlc firmware Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 10 ++ 1 file changed, 10 insertions(+) diff --git

[PATCH 28/49] drm/amd/pm: use macro to get pptable members

2021-05-12 Thread Alex Deucher
From: Chengming Gui Use macro to get the pptable members for different pptable structures. v2: abstract the table operations especially get the table members to simplify cover the two different pptable structures. v3: move pptable operations related structures and functions into ppt.c

[PATCH 32/49] drm/amdgpu: enable mc CG and LS for beige_goby

2021-05-12 Thread Alex Deucher
From: Tao Zhou Enable mc CG and LS for beige_goby. Signed-off-by: Tao Zhou Reviewed-by: Jiansong Chen Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH 25/49] drm/amd/amdgpu: update golden_setting_10_3_5 for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui add mmCGTT_SPI_{RA0/RA1}_CLK_CTRL setting Signed-off-by: Chengming Gui Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c

[PATCH 01/49] drm/amd/amdgpu: add beige_goby asic type

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add chip type for beige_goby v2: fix enum count (Alex) Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 1 + include/drm/amd_asic_type.h| 1 + 2

[PATCH 23/49] drm/amdgpu: add gc_10_3_5 golden setting for beige_goby

2021-05-12 Thread Alex Deucher
From: Hawking Zhang execute gc_10_3_5 golden registers one-time initialization Signed-off-by: Hawking Zhang Reviewed-by: Jiansong Chen Reviewed-by: Guchun Chen --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 38 ++ 1 file changed, 38 insertions(+) diff --git

[PATCH 22/49] drm/amdgpu: add mmhub client support for beige goby

2021-05-12 Thread Alex Deucher
For decoding GPUVM page faults. Reviewed-by: Hawking Zhang Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c | 27 + 1 file changed, 27 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c b/drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.c

[PATCH 18/49] drm/amdkfd: support beige_goby KFD

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add KFD support for beige_goby v2: fix asic name typo v3: squash in updates (Alex) Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdkfd/kfd_crat.c | 61 +++

[PATCH 15/49] drm/amd/amdgpu: add virtual display support for beige_goby

2021-05-12 Thread Alex Deucher
From: Chengming Gui Add virtual ip block for beige_goby Signed-off-by: Chengming Gui Reviewed-by: Hawking Zhang Reviewed-by: Tao Zhou Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c

[PATCH AUTOSEL 5.12 31/37] drm/amd/display: Fix two cursor duplication when using overlay

2021-05-12 Thread Sasha Levin
From: Rodrigo Siqueira [ Upstream commit 16e9b3e58bc3fce7391539e0eb3fd167cbf9951f ] Our driver supports overlay planes, and as expected, some userspace compositor takes advantage of these features. If the userspace is not enabling the cursor, they can use multiple planes as they please.

[PATCH AUTOSEL 5.12 27/37] amdgpu/pm: Prevent force of DCEFCLK on NAVI10 and SIENNA_CICHLID

2021-05-12 Thread Sasha Levin
From: Darren Powell [ Upstream commit b117b3964f38a988cb79825950dbd607c02237f3 ] Writing to dcefclk causes the gpu to become unresponsive, and requires a reboot. Patch ignores a .force_clk_levels(SMU_DCEFCLK) call and issues an info message. Signed-off-by: Darren Powell Reviewed-by: Kenneth

Re: [PATCH] drm/radeon: use the dummy page for GART if needed

2021-05-12 Thread Alex Deucher
On Wed, May 12, 2021 at 6:18 AM Christian König wrote: > > Imported BOs don't have a pagelist any more. > > Signed-off-by: Christian König > Fixes: 0575ff3d33cd ("drm/radeon: stop using pages with > drm_prime_sg_to_page_addr_arrays v2") > CC: sta...@vger.kernel.org # 5.12 Reviewed-by: Alex

Re: [PATCH v6 10/16] drm/amdgpu: Guard against write accesses after device removal

2021-05-12 Thread Christian König
Am 12.05.21 um 16:01 schrieb Andrey Grodzovsky: Ping - need a confirmation it's ok to keep this as a single patch given my explanation bellow. It was just an suggestion. Key point is the approach sounds sane to me, but I can't say much about the psp code for example. So maximum I can give

[PATCH 5.11 071/601] drm/amd/display: Reject non-zero src_y and src_x for video planes

2021-05-12 Thread Greg Kroah-Hartman
From: Harry Wentland commit d89f6048bdcb6a56abb396c584747d5eeae650db upstream. [Why] This hasn't been well tested and leads to complete system hangs on DCN1 based systems, possibly others. The system hang can be reproduced by gesturing the video on the YouTube Android app on ChromeOS into full

[PATCH 5.4 042/244] drm/amd/display: Reject non-zero src_y and src_x for video planes

2021-05-12 Thread Greg Kroah-Hartman
From: Harry Wentland commit d89f6048bdcb6a56abb396c584747d5eeae650db upstream. [Why] This hasn't been well tested and leads to complete system hangs on DCN1 based systems, possibly others. The system hang can be reproduced by gesturing the video on the YouTube Android app on ChromeOS into full

Re: [PATCH v6 10/16] drm/amdgpu: Guard against write accesses after device removal

2021-05-12 Thread Andrey Grodzovsky
Ping - need a confirmation it's ok to keep this as a single patch given my explanation bellow. Andrey On 2021-05-11 1:52 p.m., Andrey Grodzovsky wrote: On 2021-05-11 2:50 a.m., Christian König wrote: Am 10.05.21 um 18:36 schrieb Andrey Grodzovsky: This should prevent writing to memory or

[PATCH 5.10 068/530] drm/amd/display: Reject non-zero src_y and src_x for video planes

2021-05-12 Thread Greg Kroah-Hartman
From: Harry Wentland commit d89f6048bdcb6a56abb396c584747d5eeae650db upstream. [Why] This hasn't been well tested and leads to complete system hangs on DCN1 based systems, possibly others. The system hang can be reproduced by gesturing the video on the YouTube Android app on ChromeOS into full

Re: [PATCH] drm/amdgpu: flush TLB if valid PDE turns into PTE

2021-05-12 Thread Felix Kuehling
Am 2021-05-12 um 8:38 a.m. schrieb Christian König: > > > Am 12.05.21 um 14:34 schrieb Philip Yang: >> Mapping huge page, 2MB aligned address with 2MB size, uses PDE0 as PTE. >> If previously valid PDE0, PDE0.V=1 and PDE0.P=0 turns into PTE, this >> requires TLB flush, otherwise page table walker

Re: [PATCH v6 10/16] drm/amdgpu: Guard against write accesses after device removal

2021-05-12 Thread Andrey Grodzovsky
Hopefyllu Alex can chime in on this. I will respin V7 soon. Andrey On 2021-05-12 10:06 a.m., Christian König wrote: Am 12.05.21 um 16:01 schrieb Andrey Grodzovsky: Ping - need a confirmation it's ok to keep this as a single patch given my explanation bellow. It was just an suggestion. Key

[PATCH v7 02/16] drm/amdgpu: Split amdgpu_device_fini into early and late

2021-05-12 Thread Andrey Grodzovsky
Some of the stuff in amdgpu_device_fini such as HW interrupts disable and pending fences finilization must be done right away on pci_remove while most of the stuff which relates to finilizing and releasing driver data structures can be kept until drm_driver.release hook is called, i.e. when the

[PATCH v7 04/16] drm/amdgpu: Add early fini callback

2021-05-12 Thread Andrey Grodzovsky
Use it to call disply code dependent on device->drv_data before it's set to NULL on device unplug v5: Move HW finilization into this callback to prevent MMIO accesses post cpi remove. Signed-off-by: Andrey Grodzovsky Acked-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c

[PATCH v7 05/16] drm/amdgpu: Handle IOMMU enabled case.

2021-05-12 Thread Andrey Grodzovsky
Handle all DMA IOMMU gropup related dependencies before the group is removed. v5: Drop IOMMU notifier and switch to lockless call to ttm_tt_unpopulate v6: Drop the BO unamp list v7: Drop amdgpu_gart_fini In amdgpu_ih_ring_fini do uncinditional check (!ih->ring) to avoid freeing uniniitalized

[PATCH v7 09/16] drm/amdgpu: Guard against write accesses after device removal

2021-05-12 Thread Andrey Grodzovsky
This should prevent writing to memory or IO ranges possibly already allocated for other uses after our device is removed. v5: Protect more places wher memcopy_to/form_io takes place Protect IB submissions v6: Switch to !drm_dev_enter instead of scoping entire code with brackets. v7: Drop guard

[PATCH v7 10/16] drm/sched: Make timeout timer rearm conditional.

2021-05-12 Thread Andrey Grodzovsky
We don't want to rearm the timer if driver hook reports that the device is gone. v5: Update drm_gpu_sched_stat values in code. Signed-off-by: Andrey Grodzovsky Reviewed-by: Christian König --- drivers/gpu/drm/scheduler/sched_main.c | 11 +++ 1 file changed, 7 insertions(+), 4

[PATCH v7 01/16] drm/ttm: Remap all page faults to per process dummy page.

2021-05-12 Thread Andrey Grodzovsky
On device removal reroute all CPU mappings to dummy page. v3: Remove loop to find DRM file and instead access it by vma->vm_file->private_data. Move dummy page installation into a separate function. v4: Map the entire BOs VA space into on demand allocated dummy page on the first fault for that

[PATCH v7 03/16] drm/amdkfd: Split kfd suspend from device exit

2021-05-12 Thread Andrey Grodzovsky
Helps to expdite HW related stuff to amdgpu_pci_remove Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h | 2 +- drivers/gpu/drm/amd/amdkfd/kfd_device.c| 3 ++- 3 files changed, 4 insertions(+), 3 deletions(-)

[PATCH v7 06/16] drm/amdgpu: Remap all page faults to per process dummy page.

2021-05-12 Thread Andrey Grodzovsky
On device removal reroute all CPU mappings to dummy page per drm_file instance or imported GEM object. v4: Update for modified ttm_bo_vm_dummy_page Signed-off-by: Andrey Grodzovsky Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 21 - 1 file

[PATCH v7 07/16] PCI: Add support for dev_groups to struct pci_driver

2021-05-12 Thread Andrey Grodzovsky
This helps converting PCI drivers sysfs attributes to static. Analogous to' commit b71b283e3d6d ("USB: add support for dev_groups to struct usb_driver")' Signed-off-by: Andrey Grodzovsky Suggested-by: Greg Kroah-Hartman Acked-by: Bjorn Helgaas --- drivers/pci/pci-driver.c | 1 +

[PATCH v7 08/16] drm/amdgpu: Convert driver sysfs attributes to static attributes

2021-05-12 Thread Andrey Grodzovsky
This allows to remove explicit creation and destruction of those attrs and by this avoids warnings on device finalizing post physical device extraction. v5: Use newly added pci_driver.dev_groups directly Signed-off-by: Andrey Grodzovsky Acked-by: Christian König ---

[PATCH v7 12/16] drm/amdgpu: Fix hang on device removal.

2021-05-12 Thread Andrey Grodzovsky
If removing while commands in flight you cannot wait to flush the HW fences on a ring since the device is gone. Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git

[PATCH v7 11/16] drm/amdgpu: Prevent any job recoveries after device is unplugged.

2021-05-12 Thread Andrey Grodzovsky
Return DRM_TASK_STATUS_ENODEV back to the scheduler when device is not present so they timeout timer will not be rearmed. v5: Update to match updated return values in enum drm_gpu_sched_stat Signed-off-by: Andrey Grodzovsky Reviewed-by: Christian König ---

  1   2   >