[PATCH] drm/amdgpu: Fill adev->unique_id with data from PF2VF msg

2021-05-12 Thread Jiawei Gu
Initialize unique_id from PF2VF under virtualization. Signed-off-by: Jiawei Gu --- drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_virt.c index a57842689d42..96e269cbe326

[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 ("drm/

[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 o

[PATCH] drm/amdgpu: Complete multimedia bandwidth interface

2021-05-12 Thread Bokun Zhang
- Update SRIOV PF2VF header with latest revision - Extend existing function in amdgpu_virt.c to read MM bandwidth config from PF2VF message - Add SRIOV Sienna Cichlid codec array and update the bandwidth with PF2VF message Change-Id: Id0cfa2e1adb7a097997d53b34d41a6d36a390c00 Signed-off-by: B

[PATCH] drm/amdkfd: fix a typo in kfd_device_info for beige goby

2021-05-12 Thread Alex Deucher
Fix needs_pci_atomics setting. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdkfd/kfd_device.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_device.c b/drivers/gpu/drm/amd/amdkfd/kfd_device.c index d925e5ffa41b..80015e866498 100644 --

RE: [PATCH] drm/amdgpu: remove unsafe optimization to drop preamble ib

2021-05-12 Thread Zhang, Hawking
[AMD Public Use] Reviewed-by: Hawking Zhang Regards, Hawking -Original Message- From: Jiansong Chen Sent: Thursday, May 13, 2021 11:22 To: amd-gfx@lists.freedesktop.org Cc: Zhang, Hawking ; Koenig, Christian ; Chen, Jiansong (Simon) Subject: [PATCH] drm/amdgpu: remove unsafe optimiza

[PATCH] drm/amdgpu: remove unsafe optimization to drop preamble ib

2021-05-12 Thread Jiansong Chen
Take the situation with gfxoff, the optimization may cause corrupt CE ram contents. In addition emit_cntxcntl callback has similar optimization which firmware can handle properly even for power feature. Signed-off-by: Jiansong Chen Change-Id: I962946557108bb0575f8b2afc25b18a6dcf0d838 --- drivers

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

2021-05-12 Thread Joshi, Mukul
[AMD Official Use Only - Internal Distribution Only] > -Original Message- > From: Borislav Petkov > Sent: Wednesday, May 12, 2021 5:06 PM > To: Joshi, Mukul > Cc: amd-gfx@lists.freedesktop.org; Kasiviswanathan, Harish > ; x86-ml ; lkml ker...@vger.kernel.org> > Subject: Re: [PATCH] dr

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

2021-05-12 Thread Borislav Petkov
On Wed, May 12, 2021 at 07:00:58PM +, Joshi, Mukul wrote: > SMCA UMCv2 corresponds to GPU's UMC MCA bank and the GPU driver is > only interested in errors on GPU UMC. So that thing should be called SMCA_GPU_UMC not SMCA_UMC_V2. > We cannot know this without is_smca_umc_v2. You don't need it

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

2021-05-12 Thread Felix Kuehling
Am 2021-05-12 um 2:40 p.m. schrieb 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 previously

[PATCH v2 1/1] drm/dp_mst: Use kHz as link rate units when settig source max link caps at init

2021-05-12 Thread Nikola Cornij
[why] Link rate in kHz is what is eventually required to calculate the link bandwidth, which makes kHz a more generic unit. This should also make forward-compatibility with new DP standards easier. [how] - Replace 'link rate DPCD code' with 'link rate in kHz' when used with drm_dp_mst_topology_mgr

[PATCH v2 0/1] drm/dp_mst: Use kHz as link rate units when settig source max link caps at init

2021-05-12 Thread Nikola Cornij
Change log: v2: - Added 'Acked-by' to comment v1: - Initial Nikola Cornij (1): drm/dp_mst: Use kHz as link rate units when settig source max link caps at init .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_mst_types.c | 4 ++-- drivers/gpu/drm/drm_dp_mst_topology.c

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

2021-05-12 Thread Alex Deucher
On Wed, May 12, 2021 at 4:30 PM Andrey Grodzovsky wrote: > > > > On 2021-05-12 4:17 p.m., Alex Deucher wrote: > > On Wed, May 12, 2021 at 10:27 AM Andrey Grodzovsky > > wrote: > >> > >> This should prevent writing to memory or IO ranges possibly > >> already allocated for other uses after our dev

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

2021-05-12 Thread Andrey Grodzovsky
On 2021-05-12 4:33 p.m., Felix Kuehling wrote: Am 2021-05-12 um 10:26 a.m. schrieb 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 |

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

2021-05-12 Thread Felix Kuehling
Am 2021-05-12 um 10:26 a.m. schrieb 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_dev

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

2021-05-12 Thread Andrey Grodzovsky
On 2021-05-12 4:17 p.m., Alex Deucher wrote: On Wed, May 12, 2021 at 10:27 AM Andrey Grodzovsky wrote: 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 whe

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

2021-05-12 Thread Alex Deucher
On Wed, May 12, 2021 at 10:27 AM Andrey Grodzovsky wrote: > > 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 where > Protect IB submissions > > v6: Switc

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

2021-05-12 Thread Deucher, Alexander
[AMD Public Use] > -Original Message- > From: Tuikov, Luben > Sent: Wednesday, May 12, 2021 1:03 PM > To: amd-gfx@lists.freedesktop.org > Cc: Tuikov, Luben ; Deucher, Alexander > ; sta...@vger.kernel.org > Subject: [PATCH 1/2] drm/amdgpu: Don't query CE and UE errors > > On QUERY2 IOCTL

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

2021-05-12 Thread David M Nieto
The proper metric for fence utilization over several contexts is an harmonic mean, but such calculation is prohibitive in kernel space, so the code approximates it. Because the approximation diverges when one context has a very small ratio compared with the other context, this change filter out ra

[PATCH 1/2] drm/amdgpu: free resources on fence usage query

2021-05-12 Thread David M Nieto
Free the resources if the fence needs to be ignored during the ratio calculation Signed-off-by: David M Nieto Change-Id: Ibfc55a94c53d4b3a1dba8fff4c53fd893195bb96 --- drivers/gpu/drm/amd/amdgpu/amdgpu_ctx.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/d

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

2021-05-12 Thread Nieto, David M
[AMD Official Use Only - Internal Distribution Only] yep, you are right... I'll make those changes. David From: Christian König Sent: Tuesday, May 11, 2021 11:56 PM To: Nieto, David M ; amd-gfx@lists.freedesktop.org Subject: Re: [PATCH 2/2] drm/amdgpu: fix fen

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

2021-05-12 Thread Felix Kuehling
Am 2021-05-12 um 2:43 p.m. 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 upda

[pull] amdgpu, amdkfd, radeon drm-next-5.14

2021-05-12 Thread Alex Deucher
Hi Dave, Daniel, First set of new changes for 5.14. The following changes since commit af8352f1ff54c4fecf84e36315fd1928809a580b: Merge tag 'drm-msm-next-2021-04-11' of https://gitlab.freedesktop.org/drm/msm into drm-next (2021-04-13 23:35:54 +0200) are available in the Git repository at:

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

2021-05-12 Thread Joshi, Mukul
[AMD Official Use Only - Internal Distribution Only] > -Original Message- > From: Borislav Petkov > Sent: Wednesday, May 12, 2021 5:37 AM > To: Joshi, Mukul > Cc: amd-gfx@lists.freedesktop.org; Kasiviswanathan, Harish > ; x86-ml ; lkml ker...@vger.kernel.org> > Subject: Re: [PATCH] drm

[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 previo

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 prev

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 Deuc

[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. Neverthe

[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. Neverthe

[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 Fe

[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. Neverthe

[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 Fe

[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. Neverthe

[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 Fe

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 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 --- drivers/gpu/drm/am

[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 a/drivers/gpu/drm

[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, bas

[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 chan

[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 file

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

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why&How] 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 a/drivers/gpu/drm/amd/amdgpu/

[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 a/drivers/gp

[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 +- .../gpu/drm/amd/am

[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 49/49] drm/amd/display: enable idle optimizations for beige goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why&How] 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 insertio

[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&How] 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 48/49] drm/amd/display: Enable HDCP for Beige Goby

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why&How] 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 a/drive

[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 b/drivers/g

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

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why&How] 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 in

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

2021-05-12 Thread Alex Deucher
From: Aurabindo Pillai [Why&How] 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 ++

[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 a/drivers/gpu/drm/amd/amdgpu/amdgpu_atomfirm

[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 a/

[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 b/drivers/gpu/drm/amd/amdgpu/

[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 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 --- drivers/g

[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 b/drivers/gpu/drm/amd

[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 a/drivers/gpu/drm/amd

[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 b/drivers/gpu/drm/am

[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 b/drivers/gpu/drm/amd/amdgpu/n

[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 b/

[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 a/drivers/gpu/drm/amd/amdgpu/mmhub_v2_0.

[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 b/drivers/gpu/drm/amd/a

[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 v4

[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 a/drivers/gpu/drm

[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 a/drivers/gpu/drm/amd/amdgpu/amdgpu_

[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 b/

[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 chang

[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 b/drivers/gp

[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 fil

[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 a/drivers/g

[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: ht

[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 b/drivers/gpu/

[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 b/drive

[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 in

[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 b/drivers/gpu/

[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 a/drivers/gpu/d

[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 +- drivers/gpu/drm/amd/am

[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 +++ driver

[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 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 +-- drivers/gpu/drm/amd/am

[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 + d

[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 a/drivers/gpu/drm/amd/amdgpu/amdgpu_d

[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 b/

[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 files

[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 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 ("drm/

[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 o

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 w

[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.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

[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: New uAPI for color management proposal and feedback request

2021-05-12 Thread Werner Sembach
Am 12.05.21 um 14:06 schrieb 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: >

[PATCH v7 16/16] drm/amdgpu: Unmap all MMIO mappings

2021-05-12 Thread Andrey Grodzovsky
Access to those must be prevented post pci_remove v6: Drop BOs list, unampping VRAM BAR is enough. Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 24 +++--- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_tt

[PATCH v7 15/16] drm/amdgpu: Verify DMA opearations from device are done

2021-05-12 Thread Andrey Grodzovsky
In case device remove is just simualted by sysfs then verify device doesn't keep doing DMA to the released memory after pci_remove is done. Signed-off-by: Andrey Grodzovsky Acked-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 6 ++ 1 file changed, 6 insertions(+) diff --

[PATCH v7 14/16] drm/amd/display: Remove superfluous drm_mode_config_cleanup

2021-05-12 Thread Andrey Grodzovsky
It's already being released by DRM core through devm Signed-off-by: Andrey Grodzovsky Reviewed-by: Rodrigo Siqueira --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c b/drivers/gpu/drm/amd/d

[PATCH v7 13/16] drm/scheduler: Fix hang when sched_entity released

2021-05-12 Thread Andrey Grodzovsky
Problem: If scheduler is already stopped by the time sched_entity is released and entity's job_queue not empty I encountred a hang in drm_sched_entity_flush. This is because drm_sched_entity_is_idle never becomes false. Fix: In drm_sched_fini detach all sched_entities from the scheduler's run queu

[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 a/drivers/gpu/drm/amd

  1   2   >