Re: [PATCH] drm/amdgpu: remove experimental flag for Navi14

2019-11-15 Thread Yuan, Xiaojie
Reviewed-by: Xiaojie Yuan BR, Xiaojie > On Nov 15, 2019, at 10:51 PM, Alex Deucher wrote: > > 5.4 and newer works fine with navi14. > > Signed-off-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a

[PATCH] drm/amd/display: Modify comments to match the code

2019-11-15 Thread Zhan Liu
[Why] This line of code was modified. However, the comment was remaining unchanged. [How] Change "200ms" to "3000ms", which matches the code. Also add another line of comment, which tells people where the value came from. Signed-off-by: Zhan Liu --- drivers/gpu/drm/amd/display/dc/dc_helper.c |

Re: [PATCH 3/4] drm/ttm: rework BO delayed delete.

2019-11-15 Thread Felix Kuehling
On 2019-11-11 9:58 a.m., Christian König wrote: This patch reworks the whole delayed deletion of BOs which aren't idle. Instead of having two counters for the BO structure we resurrect the BO when we find that a deleted BO is not idle yet. This has many advantages, especially that we don't need

[PATCH] amd/amdgpu: force to trigger a no-retry-fault after a retry-fault

2019-11-15 Thread Alex Sierra
After a retry-fault happens, the fault handler will modify the UTCL2 to set PTE bits to force a no-retry-fault. This will cause the wave to enter the trap handler. Change-Id: I177102891f715068f15605957ff23b0cab862603 Signed-off-by: Alex Sierra --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 15

Re: [PATCH] drm/amdgpu/vcn2.5: fix the enc loop with hw fini

2019-11-15 Thread James Zhu
Reviewed-by: James Zhu On 2019-11-15 5:15 p.m., Leo Liu wrote: Fixes: 9072c584 (drm/amdgpu: move JPEG2.5 out from VCN2.5) Signed-off-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vc

Re: [PATCH] drm/amdgpu/vcn2.5: fix the enc loop with hw fini

2019-11-15 Thread Leo Liu
On 2019-11-15 5:15 p.m., Leo Liu wrote: Fixes: 9072c584 (drm/amdgpu: move JPEG2.5 out from VCN2.5) Just checked the bug was existing before the changes above. Regards, Leo Signed-off-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c | 6 +++--- 1 file changed, 3 insertions(+), 3

Re: [PATCH 2/4] drm/ttm: cleanup ttm_buffer_object_transfer

2019-11-15 Thread Felix Kuehling
The subject doesn't match the change. This changes ttm_bo_cleanup_refs, not ttm_buffer_object_transfer. On 2019-11-11 9:58 a.m., Christian König wrote: The function is always called with deleted BOs. While at it cleanup the indentation as well. Signed-off-by: Christian König --- drivers/gp

[PATCH] drm/amdgpu/vcn2.5: fix the enc loop with hw fini

2019-11-15 Thread Leo Liu
Fixes: 9072c584 (drm/amdgpu: move JPEG2.5 out from VCN2.5) Signed-off-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c b/drivers/gpu/drm/amd/amdgpu/vcn_v2_5.c index 451dc814d845.

Re: [PATCH] drm/amdkfd: remove set but not used variable 'top_dev'

2019-11-15 Thread Felix Kuehling
On 2019-11-13 10:20 p.m., zhengbin wrote: Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/amd/amdkfd/kfd_iommu.c: In function kfd_iommu_device_init: drivers/gpu/drm/amd/amdkfd/kfd_iommu.c:65:30: warning: variable top_dev set but not used [-Wunused-but-set-variable] Reported-by:

Re: [PATCH 01/12] amdgpu: add UAPI for creating encrypted buffers

2019-11-15 Thread Olsak, Marek
The way this is upstreamed is that you submit the kernel and userspace patches for review at the same time. When they see the userspace patches, the kernel patches will be accepted. When the kernel patches land in the Dave's or Linus's tree, the userspace patches can be pushed. Marek __

Re: [PATCH 01/12] amdgpu: add UAPI for creating encrypted buffers

2019-11-15 Thread Olsak, Marek
In the kernel tree, you need to do "make headers_install". Then copy amdgpu_drm.h from ./usr/ to the libdrm tree and discard parts that we can't upstream (freesync). Marek From: Koenig, Christian Sent: November 15, 2019 10:08 To: Deucher, Alexander Cc: Christia

Re: [PATCH 2/2] drm/edid: Add alternate clock for SMPTE 4K

2019-11-15 Thread Ville Syrjälä
On Tue, Nov 12, 2019 at 10:36:54AM +0100, Neil Armstrong wrote: > On 12/11/2019 08:53, Wayne Lin wrote: > > [Why] > > In hdmi_mode_alternate_clock(), it adds an exception for VIC 4 > > mode (4096x2160@24) due to there is no alternate clock defined for > > that mode in HDMI1.4b. But HDMI2.0 adds 23.

Re: [PATCH 2/2] drm/edid: Add alternate clock for SMPTE 4K

2019-11-15 Thread Ville Syrjälä
On Tue, Nov 12, 2019 at 03:53:07PM +0800, Wayne Lin wrote: > [Why] > In hdmi_mode_alternate_clock(), it adds an exception for VIC 4 > mode (4096x2160@24) due to there is no alternate clock defined for > that mode in HDMI1.4b. But HDMI2.0 adds 23.98Hz for that mode. > > [How] > Remove the exception

Re: [PATCH 1/2] drm/edid: Add aspect ratios to HDMI 4K modes

2019-11-15 Thread Ville Syrjälä
On Tue, Nov 12, 2019 at 03:53:06PM +0800, Wayne Lin wrote: > [Why] > HDMI 2.0 adds aspect ratio attribute to distinguish different > 4k modes. According to Appendix E of HDMI 2.0 spec, source should > use VSIF to indicate video mode only when the mode is one defined > in HDMI 1.4b 4K modes. Otherwi

Re: [PATCH] amd/amdgpu: force to trigger a no-retry-fault after a retry-fault

2019-11-15 Thread Philip Yang
One suggestion below, move the flags setting for else path into else path looks better. Philip On 2019-11-15 12:43 p.m., Alex Sierra wrote: After a retry-fault happens, the fault handler will modify the UTCL2 to set PTE bits to force a no-retry-fault. This will cause the wave to enter the trap

[PATCH] amd/amdgpu: force to trigger a no-retry-fault after a retry-fault

2019-11-15 Thread Alex Sierra
After a retry-fault happens, the fault handler will modify the UTCL2 to set PTE bits to force a no-retry-fault. This will cause the wave to enter the trap handler. Change-Id: I177102891f715068f15605957ff23b0cab862603 Signed-off-by: Alex Sierra --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 13

Re: [PATCH 2/2] drm/amdgpu: disable gfxoff when using register read interface

2019-11-15 Thread Yuan, Xiaojie
Yes. IIRC, some asics' amdgpu_gfx_ctrl() is implemented as synchronous (upon function returns, gfx block is guaranteed to be in power-up state). Anyway, let me confirm about that soon. BR, Xiaojie > On Nov 16, 2019, at 12:52 AM, Alex Deucher wrote: > >> On Fri, Nov 15, 2019 at 11:46 AM Yuan,

Re: [PATCH 2/2] drm/amdgpu: disable gfxoff when using register read interface

2019-11-15 Thread Alex Deucher
On Fri, Nov 15, 2019 at 11:46 AM Yuan, Xiaojie wrote: > > Hi Alex, > > IMHO, driver sending Disallow_Gfxoff message to SMU doesn't mean gfx block > will be immediately powered up, so I'm not sure MMIO register access will be > successful within this time window(maybe GRBM access will be pending

[PATCH 20/20] ALSA: hda/hdmi - enable automatic runtime pm for AMD HDMI codecs by default

2019-11-15 Thread Alex Deucher
So that we can power down the GPU and audio to save power. Reviewed-by: Takashi Iwai Acked-by: Evan Quan Signed-off-by: Alex Deucher --- sound/pci/hda/patch_hdmi.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c index 795cbda32cbb..87

[PATCH 14/20] drm/amdgpu: disentangle runtime pm and vga_switcheroo

2019-11-15 Thread Alex Deucher
Originally we only supported runtime pm on PX/HG laptops so vga_switcheroo and runtime pm are sort of entangled. Attempt to logically separate them. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 22 ++ 1 file changed, 14

[PATCH 17/20] ALSA: hda/hdmi - fix vgaswitcheroo detection for AMD

2019-11-15 Thread Alex Deucher
Only enable the vga_switcheroo logic on systems with the ATPX ACPI method. This logic is not needed for asics that are not part of a PX (PowerXpress)/HG (Hybrid Graphics) platform. Reviewed-by: Takashi Iwai Acked-by: Evan Quan Signed-off-by: Alex Deucher --- sound/pci/hda/hda_intel.c | 45 +++

[PATCH 15/20] drm/amdgpu: enable runtime pm on BACO capable boards if runpm=1

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Everything is in place now. Not enabled by default yet. You still have to specify runpm=1. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 11 +++ 1 file changed, 7 insertions(+), 4 deletions(-) diff --git

[PATCH 13/20] drm/amdgpu: start to disentangle boco from runtime pm

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off BOCO - Bus Off, Chip Off We originally only supported runtime pm on PX/HG laptops so most of the runtime pm code looks for this. Add a new flag to check for runtime pm enablement and use this rather than checking for PX/HG. Reviewed-by: Evan Quan Signed-off-by: Alex D

[PATCH 16/20] drm/amdgpu/runpm: enable runpm on baco capable VI+ asics (v2)

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Works reliably on VI, vega. v2: don't enable on navi yet. Reviewed-by: Evan Quan (v1) Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amd

[PATCH 00/20] Enable BACO for power savings (v3)

2019-11-15 Thread Alex Deucher
This patch set enables BACO (Bus Active Chip Off) for power savings on VI+ asics. Similar to PowerXpress and Hybrid Graphics (PX/HG) laptops, we can disable GPUs at runtime when they are not in use if they support BACO. The runtime pm code in amdgpu was originally developed for PX/HG laptops, so

[PATCH 11/20] drm/amdgpu: add helpers for baco entry and exit

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Will be used for runtime pm. Entry will enter the BACO state (chip off). Exit will exit the BACO state (chip on). Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu.h| 2 + drivers/gpu/drm/amd/amdgpu/amdgpu_device.c |

[PATCH 02/20] drm/amdgpu: add supports_baco callback for soc15 asics. (v2)

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Check the BACO capabilities from the powerplay table. v2: drop unrelated struct cleanup Reviewed-by: Evan Quan (v1) Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/soc15.c | 24 1 file changed, 24 insertions(+) diff --git a/driv

[PATCH 19/20] ALSA: hda/hdmi - enable runtime pm for newer AMD display audio

2019-11-15 Thread Alex Deucher
We are able to power down the GPU and audio via the GPU driver so flag these asics as supporting runtime pm. Reviewed-by: Takashi Iwai Acked-by: Evan Quan Signed-off-by: Alex Deucher --- sound/pci/hda/hda_intel.c | 35 +++ 1 file changed, 23 insertions(+), 12 de

[PATCH 09/20] drm/amdgpu: add additional boco checks to runtime suspend/resume (v2)

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off BOCO - Bus Off, Chip Off We will take slightly different paths for boco and baco. v2: fold together two consecutive if clauses Reviewed-by: Evan Quan (v1) Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 47 ++--- 1 file

[PATCH 06/20] drm/amdgpu: add supports_baco callback for NV asics.

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Check the BACO capabilities from the powerplay table. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/nv.c b/drivers/gpu/drm/amd/amdgpu

[PATCH 07/20] drm/amdgpu: add a amdgpu_device_supports_baco helper

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off To check if a device supports BACO or not. This will be used in determining when to enable runtime pm. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu.h| 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 15

[PATCH 18/20] ALSA: hda/hdmi - Add new pci ids for AMD GPU display audio

2019-11-15 Thread Alex Deucher
These are needed so we can enable runtime pm in a subsequent patch. Reviewed-by: Takashi Iwai Signed-off-by: Alex Deucher --- sound/pci/hda/hda_intel.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c index 3ebc7b2a897f..7

[PATCH 05/20] drm/amdgpu: add supports_baco callback for VI asics.

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Check the BACO capabilities from the powerplay table. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/vi.c | 22 ++ 1 file changed, 22 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/vi.c b/drivers/gpu/drm

[PATCH 03/20] drm/amdgpu: add supports_baco callback for SI asics.

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Not supported. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/si.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/si.c b/drivers/gpu/drm/amd/amdgpu/si.c index 29024e64c886..cb682d44737a 100644

[PATCH 10/20] drm/amdgpu: split swSMU baco_reset into enter and exit

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off So we can use it for power savings rather than just reset. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/nv.c | 7 ++- drivers/gpu/drm/amd/amdgpu/soc15.c| 10 -- drivers/gpu/drm/amd/powerplay

[PATCH 08/20] drm/amdgpu: rename amdgpu_device_is_px to amdgpu_device_supports_boco (v2)

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off BOCO - Bus Off, Chip Off To better match what we are checking for and to align with amdgpu_device_supports_baco. BOCO is used on PowerXpress/Hybrid Graphics systems and BACO is used on desktop dGPU boards. v2: fix typo in documentation Reviewed-by: Evan Quan Signed-

[PATCH 12/20] drm/amdgpu: add baco support to runtime suspend/resume

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off This adds the necessary support to the runtime suspend and resume functions to handle boards that support baco. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-)

[PATCH 01/20] drm/amdgpu: add asic callback for BACO support

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Used to check whether the device supports BACO. This will be used to enable runtime pm on devices which support BACO. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 1 file changed, 4 insertions(+) diff --git a/

[PATCH 04/20] drm/amdgpu: add supports_baco callback for CIK asics.

2019-11-15 Thread Alex Deucher
BACO - Bus Active, Chip Off Check the BACO capabilities from the powerplay table. Reviewed-by: Evan Quan Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/cik.c | 18 ++ 1 file changed, 18 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/cik.c b/drivers/gpu/drm/a

Re: [PATCH] drm/amdgpu/nv: add asic func for fetching vbios from rom directly

2019-11-15 Thread Yuan, Xiaojie
Reviewed-by: Xiaojie Yuan BR, Xiaojie > On Nov 16, 2019, at 12:12 AM, Alex Deucher wrote: > > Ping? > >> On Wed, Nov 13, 2019 at 2:29 PM Alex Deucher wrote: >> >> Needed as a fallback if the vbios can't be fetched by other means. >> >> Signed-off-by: Alex Deucher >> --- >> drivers/gpu/drm

Re: [PATCH 2/2] drm/amdgpu: disable gfxoff when using register read interface

2019-11-15 Thread Yuan, Xiaojie
Hi Alex, IMHO, driver sending Disallow_Gfxoff message to SMU doesn't mean gfx block will be immediately powered up, so I'm not sure MMIO register access will be successful within this time window(maybe GRBM access will be pending until gfx block is powered up?) If you are not in a hurry to com

Re: [PATCH] drm/amdgpu/soc15: move struct definition around to align with other soc15 asics

2019-11-15 Thread Zhao, Yong
Reviewed-by: Yong Zhao From: amd-gfx on behalf of Alex Deucher Sent: Friday, November 15, 2019 11:13 AM To: amd-gfx list Cc: Deucher, Alexander Subject: Re: [PATCH] drm/amdgpu/soc15: move struct definition around to align with other soc15 asics Ping? On Mon

[pull] radeon and amdgpu drm-next-5.5

2019-11-15 Thread Alex Deucher
Hi Dave, Daniel, Misc fixes for 5.5. The following changes since commit 53dbc27ad5a93932ff1892a8e4ef266827d74a0f: drm/amdgpu/powerplay: fix AVFS handling with custom powerplay table (2019-11-08 12:30:24 -0500) are available in the Git repository at: git://people.freedesktop.org/~agd5f/lin

Re: [PATCH 2/2] drm/amdgpu: disable gfxoff when using register read interface

2019-11-15 Thread Alex Deucher
Ping? On Thu, Nov 14, 2019 at 11:42 AM Alex Deucher wrote: > > When gfxoff is enabled, accessing gfx registers via MMIO > can lead to a hang. > > Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205497 > Signed-off-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 6 +- > 1

Re: [PATCH 1/2] Revert "drm/amdgpu: don't read registers if gfxoff is enabled (v2)"

2019-11-15 Thread Alex Deucher
Ping? On Thu, Nov 14, 2019 at 11:41 AM Alex Deucher wrote: > > This reverts commit 5e49d6f654c569c2de920babbaf5cf7c4c4a353f. > > Drop this workaround in favor of a better one. > > Signed-off-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/nv.c| 27 ++ > drivers/g

Re: [PATCH] drm/amdgpu/soc15: move struct definition around to align with other soc15 asics

2019-11-15 Thread Alex Deucher
Ping? On Mon, Nov 11, 2019 at 5:21 PM Alex Deucher wrote: > > Move reset_method next to reset callback to match the struct layout and > the other definition in this file. > > Signed-off-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/soc15.c | 2 +- > 1 file changed, 1 insertion(+), 1 delet

Re: [PATCH] drm/amdgpu/nv: add asic func for fetching vbios from rom directly

2019-11-15 Thread Alex Deucher
Ping? On Wed, Nov 13, 2019 at 2:29 PM Alex Deucher wrote: > > Needed as a fallback if the vbios can't be fetched by other means. > > Signed-off-by: Alex Deucher > --- > drivers/gpu/drm/amd/amdgpu/nv.c | 24 ++-- > 1 file changed, 22 insertions(+), 2 deletions(-) > > diff --g

[PATCH] drm/amdkfd: DIQ should not use HIQ way to allocate memory

2019-11-15 Thread Yong Zhao
In the mqd_diq_sdma buffer, there should be only one HIQ mqd. All DIQs should be allocate using the regular way. Change-Id: Ibf3eb33604d0ec30501c244228cdb3b24615b699 Signed-off-by: Yong Zhao --- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_cik.c | 2 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_v

[PATCH] drm/amdkfd: Delete KFD_MQD_TYPE_COMPUTE

2019-11-15 Thread Yong Zhao
It is the same as KFD_MQD_TYPE_CP, so delete it. As a result, we will have one less mqd mananger per device. Change-Id: Iaa98fc17be06b216de7a826c3577f44bc0536b4c Signed-off-by: Yong Zhao --- drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c | 2 +- drivers/gpu/drm/amd/amdkfd/kfd_mqd_manager_

[PATCH] drm/amd/display: re-enable wait in pipelock, but add timeout

2019-11-15 Thread Alex Deucher
Removing this causes hangs in some games, so re-add it, but add a timeout so we don't hang while switching flip types. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205169 Bug: https://bugs.freedesktop.org/show_bug.cgi?id=112266 Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205169 Signed-off

Re: [PATCH] Revert "drm/amd/display: revert wait in pipelock"

2019-11-15 Thread Kazlauskas, Nicholas
On 2019-11-15 10:13 a.m., Alex Deucher wrote: This reverts commit 617089d5837a3aa4167a9c4afb34929e0d52805d. This causes hangs in some games. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205169 Bug: https://bugs.freedesktop.org/show_bug.cgi?id=112266 Bug: https://bugzilla.kernel.org/show_bug

Re: drm core/helpers and MIT license

2019-11-15 Thread Alex Deucher
On Tue, Nov 12, 2019 at 10:03 AM Daniel Vetter wrote: > > Hi all, > > Dave and me chatted about this last week on irc. Essentially we have: > > $ git grep SPDX.*GPL -- ':(glob)drivers/gpu/drm/*c' > drivers/gpu/drm/drm_client.c:// SPDX-License-Identifier: GPL-2.0 > drivers/gpu/drm/drm_damage_helper

[PATCH 1/2] drm/amdgpu: disable gfxoff on original raven

2019-11-15 Thread Alex Deucher
There are still combinations of sbios and firmware that are not stable. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=204689 Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 9 +++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/a

[PATCH 2/2] Revert "drm/amd/display: enable S/G for RAVEN chip"

2019-11-15 Thread Alex Deucher
This reverts commit 1c4259159132ae4ceaf7c6db37a6cf76417f73d9. S/G display is not stable with the IOMMU enabled on some platforms. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205523 Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 2 +- drivers/gpu/drm/amd

[PATCH] Revert "drm/amd/display: revert wait in pipelock"

2019-11-15 Thread Alex Deucher
This reverts commit 617089d5837a3aa4167a9c4afb34929e0d52805d. This causes hangs in some games. Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205169 Bug: https://bugs.freedesktop.org/show_bug.cgi?id=112266 Bug: https://bugzilla.kernel.org/show_bug.cgi?id=205169 Signed-off-by: Alex Deucher ---

Re: [PATCH 01/12] amdgpu: add UAPI for creating encrypted buffers

2019-11-15 Thread Koenig, Christian
I know, that's the usual chicken and egg problem with updating libdrm. But we should update the file with the kernel version and not pick all changes line by line. Christian. Am 15.11.2019 15:49 schrieb "Deucher, Alexander" : We can't land the kernel side until we have real userspace (e.g., Mes

[PATCH 2/6] drm/radeon: remove set but not used variable 'backbias_response_time'

2019-11-15 Thread zhengbin
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/radeon/si_dpm.c: In function si_program_response_times: drivers/gpu/drm/radeon/si_dpm.c:3640:29: warning: variable backbias_response_time set but not used [-Wunused-but-set-variable] It is introduced by commit a9e61410921b ("drm/rade

[PATCH 5/6] drm/radeon: remove set but not used variable 'blocks'

2019-11-15 Thread zhengbin
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/radeon/radeon_combios.c: In function radeon_combios_get_power_modes: drivers/gpu/drm/radeon/radeon_combios.c:2638:10: warning: variable blocks set but not used [-Wunused-but-set-variable] It is introduced by commit 56278a8edace ("dr

[PATCH][next] drm/amdgpu/powerplay: fix dereference before null check of pointer hwmgr

2019-11-15 Thread Colin King
From: Colin Ian King The assignment of adev dereferences pointer hwmgr before hwmgr is null checked, hence there is a potential null pointer deference issue. Fix this by assigning adev after the null check. Addresses-Coverity: ("Dereference before null check") Fixes: 0896d2f7ba4d ("drm/amdgpu/po

[PATCH 3/6] drm/radeon: remove set but not used variable 'dig_connector'

2019-11-15 Thread zhengbin
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/radeon/atombios_dp.c: In function radeon_dp_get_panel_mode: drivers/gpu/drm/radeon/atombios_dp.c:415:36: warning: variable dig_connector set but not used [-Wunused-but-set-variable] It is not used since commit 379dfc25e257 ("drm/rade

[PATCH 0/6] drm/radeon: remove some set but not used variables

2019-11-15 Thread zhengbin
zhengbin (6): drm/radeon: remove set but not used variable 'size','relocs_chunk' drm/radeon: remove set but not used variable 'backbias_response_time' drm/radeon: remove set but not used variable 'dig_connector' drm/radeon: remove set but not used variable 'radeon_connector' drm/radeon: r

[PATCH 1/6] drm/radeon: remove set but not used variable 'size', 'relocs_chunk'

2019-11-15 Thread zhengbin
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/radeon/r600_cs.c: In function r600_cs_track_validate_cb: drivers/gpu/drm/radeon/r600_cs.c:353:22: warning: variable size set but not used [-Wunused-but-set-variable] drivers/gpu/drm/radeon/r600_cs.c: In function r600_cs_track_validate

[PATCH 6/6] drm/radeon: remove set but not used variable 'tv_pll_cntl1'

2019-11-15 Thread zhengbin
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/radeon/radeon_legacy_tv.c: In function radeon_legacy_tv_mode_set: drivers/gpu/drm/radeon/radeon_legacy_tv.c:538:24: warning: variable tv_pll_cntl1 set but not used [-Wunused-but-set-variable] It is introduced by commit 4ce001abafaf

[PATCH 4/6] drm/radeon: remove set but not used variable 'radeon_connector'

2019-11-15 Thread zhengbin
Fixes gcc '-Wunused-but-set-variable' warning: drivers/gpu/drm/radeon/radeon_display.c: In function radeon_crtc_scaling_mode_fixup: drivers/gpu/drm/radeon/radeon_display.c:1685:27: warning: variable radeon_connector set but not used [-Wunused-but-set-variable] It is not used since commit 377bd8

[PATCH] drm/amdgpu: remove experimental flag for Navi14

2019-11-15 Thread Alex Deucher
5.4 and newer works fine with navi14. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c index e1c15721611a..b19157b

Re: [PATCH 01/12] amdgpu: add UAPI for creating encrypted buffers

2019-11-15 Thread Deucher, Alexander
We can't land the kernel side until we have real userspace (e.g., Mesa) that uses the TMZ interfaces. The unit tests are not enough. Alex From: Christian König Sent: Friday, November 15, 2019 7:56 AM To: Liu, Aaron ; amd-gfx@lists.freedesktop.org Cc: Olsak,

Re: [PATCH 00/12] Initial TMZ support for libdrm and amdgpu_test

2019-11-15 Thread Christian König
Patches #2-#5, #8, #10-#12  are Acked-by: Christian König Patch #7 is most likely a NAK. The interface updated here is deprecated as far as I know. Patch #9: How does that actually work? Thanks, Christian. Am 15.11.19 um 04:34 schrieb Liu, Aaron: These series of patches are to initial TM

Re: [PATCH 01/12] amdgpu: add UAPI for creating encrypted buffers

2019-11-15 Thread Christian König
Am 15.11.19 um 04:34 schrieb Aaron Liu: From: Huang Rui To align the kernel uapi change from Alex: "Add a flag to the GEM_CREATE ioctl to create encrypted buffers. Buffers with this flag set will be created with the TMZ bit set in the PTEs or engines accessing them. This is required in order t

Re: [PATCH 07/12] amdgpu: using IB flags for TMZ or non-TMZ

2019-11-15 Thread Christian König
Am 15.11.19 um 10:32 schrieb Huang Rui: On Fri, Nov 15, 2019 at 11:34:50AM +0800, Liu, Aaron wrote: In kernel, cs->in.flags is used for TMZ. Hence libdrm should transfer the flag to kernel. Signed-off-by: Aaron Liu --- amdgpu/amdgpu.h| 4 +++- amdgpu/amdgpu_cs.c | 4 2 files chang

Re: [PATCH 12/12] tests/amdgpu: add test to submit a sdma command with secure context

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:55AM +0800, Liu, Aaron wrote: > This patch add test to submit a sdma command with secure context. > > Signed-off-by: Aaron Liu Reviewed-by: Huang Rui > --- > tests/amdgpu/security_tests.c | 10 ++ > 1 file changed, 10 insertions(+) > > diff --git a/tests

Re: [PATCH 10/12] tests/amdgpu: add test to submit a gfx command with secure context

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:53AM +0800, Liu, Aaron wrote: > This patch is to test the command submission with secure context. > > Signed-off-by: Aaron Liu Reviewed-by: Huang Rui > --- > tests/amdgpu/security_tests.c | 9 + > 1 file changed, 9 insertions(+) > > diff --git a/tests/am

Re: [PATCH 09/12] tests/amdgpu: add atomic_mem cp_packet to verify the secure buffer

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:52AM +0800, Liu, Aaron wrote: > Secure buffer is only able to be read with trusted ip block. > So we need use GFX ip to read it back instead of CPU. > Steps: > 1. use write_data packet to write 0xdeadbeaf to secure buffer, > 2. use atmoic_mem packet and ATOMIC_CMPSWAP_

Re: [PATCH 11/12] tests/amdgpu: add atomic dma command to verify the secure buffer

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:54AM +0800, Liu, Aaron wrote: > DMA's atomic behavir is unlike GFX,If the comparing data is not > equal to destination data, > For GFX, loop again till gfx timeout(system hang). > For DMA, loop again till timer expired and then send interrupt. > So testcase can't use i

Re: [PATCH 08/12] tests/amdgpu: expand secure param for exec_cs_helper

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:51AM +0800, Liu, Aaron wrote: > This patch expands secure param for amdgpu_test_exec_cs_helper_raw. > The flag is transfered to kernel with cs. > > Signed-off-by: Aaron Liu Acked-by: Huang Rui > --- > tests/amdgpu/basic_tests.c | 8 +--- > 1 file changed, 5 i

Re: [PATCH 08/12] tests/amdgpu: expand secure param for exec_cs_helper

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:51AM +0800, Liu, Aaron wrote: > This patch expands secure param for amdgpu_test_exec_cs_helper_raw. > The flag is transfered to kernel with cs. > > Signed-off-by: Aaron Liu Acked-by: Huang Rui > --- > tests/amdgpu/basic_tests.c | 8 +--- > 1 file changed, 5 i

Re: [PATCH 09/12] tests/amdgpu: add atomic_mem cp_packet to verify the secure buffer

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:52AM +0800, Liu, Aaron wrote: > Secure buffer is only able to be read with trusted ip block. > So we need use GFX ip to read it back instead of CPU. > Steps: > 1. use write_data packet to write 0xdeadbeaf to secure buffer, > 2. use atmoic_mem packet and ATOMIC_CMPSWAP_

Re: [PATCH 07/12] amdgpu: using IB flags for TMZ or non-TMZ

2019-11-15 Thread Huang, Ray
On Fri, Nov 15, 2019 at 11:34:50AM +0800, Liu, Aaron wrote: > In kernel, cs->in.flags is used for TMZ. Hence libdrm should transfer > the flag to kernel. > > Signed-off-by: Aaron Liu > --- > amdgpu/amdgpu.h| 4 +++- > amdgpu/amdgpu_cs.c | 4 > 2 files changed, 7 insertions(+), 1 deleti

RE: [PATCH 2/2] drm/amdgpu: invalidate semphore mmhub workaround for gfx9/gfx10

2019-11-15 Thread Zhu, Changfeng
Am 14.11.19 um 11:17 schrieb Changfeng.Zhu: > From: changzhu > > MMHUB may lose GPUVM invalidate acknowledge state across power-gating > off cycle when it does invalidation req/ack work. > > So we must acquire/release one of the vm_invalidate_eng*_sem around > the invalidation req/ack. > > Besi