Re: [PATCH 2/2] drm/amdgpu: add sclk/uclk sensor support for vega20

2019-07-17 Thread Deucher, Alexander
Ah, I missed that they were already handled in smu_v11_0.c. In that case, I think I can drop these patches. Alex From: Quan, Evan Sent: Wednesday, July 17, 2019 8:58 PM To: Alex Deucher; amd-gfx@lists.freedesktop.org Cc: Deucher, Alexander Subject: RE: [PATCH

[PATCH] drm/amdgpu: Prefer pcie_capability_read_word()

2019-07-17 Thread Frederick Lawler
Commit 8c0d3a02c130 ("PCI: Add accessors for PCI Express Capability") added accessors for the PCI Express Capability so that drivers didn't need to be aware of differences between v1 and v2 of the PCI Express Capability. Replace pci_read_config_word() and pci_write_config_word() calls with

[PATCH] drm/radeon: Prefer pcie_capability_read_word()

2019-07-17 Thread Frederick Lawler
Commit 8c0d3a02c130 ("PCI: Add accessors for PCI Express Capability") added accessors for the PCI Express Capability so that drivers didn't need to be aware of differences between v1 and v2 of the PCI Express Capability. Replace pci_read_config_word() and pci_write_config_word() calls with

RE: [PATCH] drm/amdgpu/pm: remove check for pp funcs in freq sysfs handlers

2019-07-17 Thread Quan, Evan
Reviewed-by: Evan Quan > -Original Message- > From: amd-gfx On Behalf Of Alex > Deucher > Sent: Thursday, July 18, 2019 2:15 AM > To: amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander > Subject: [PATCH] drm/amdgpu/pm: remove check for pp funcs in freq sysfs > handlers > > The dpm

[PATCH] drm/amdgpu/dm: Remove unneeded hotplug event in s3_handle_mst()

2019-07-17 Thread Lyude Paul
The DRM DP MST topology manager will send it's own hotplug events when connectors are destroyed, so there's no reason to send an additional hotplug event here. Signed-off-by: Lyude Paul --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 9 - 1 file changed, 4 insertions(+), 5

[PATCH 23/26] drm/amdgpu/dm: Resume short HPD IRQs before resuming MST topology

2019-07-17 Thread Lyude Paul
Since we're going to be reprobing the entire topology state on resume now using sideband transactions, we need to ensure that we actually have short HPD irqs enabled before calling drm_dp_mst_topology_mgr_resume(). So, do that. Cc: Juston Li Cc: Imre Deak Cc: Ville Syrjälä Cc: Harry Wentland

[PATCH 24/26] drm/dp_mst: Add basic topology reprobing when resuming

2019-07-17 Thread Lyude Paul
Finally! For a very long time, our MST helpers have had one very annoying issue: They don't know how to reprobe the topology state when coming out of suspend. This means that if a user has a machine connected to an MST topology and decides to suspend their machine, we lose all topology changes

[PATCH 22/26] drm/amdgpu: Iterate through DRM connectors correctly

2019-07-17 Thread Lyude Paul
Currently, every single piece of code in amdgpu that loops through connectors does it incorrectly and doesn't use the proper list iteration helpers, drm_connector_list_iter_begin() and drm_connector_list_iter_end(). Yeesh. So, do that. Cc: Juston Li Cc: Imre Deak Cc: Ville Syrjälä Cc: Harry

[PATCH 00/26] DP MST Refactors + debugging tools + suspend/resume reprobing

2019-07-17 Thread Lyude Paul
This is the large series for adding MST suspend/resume reprobing that I've been working on for quite a while now. In addition, I: - Refactored and cleaned up any code I ended up digging through in the process of understanding how some parts of these helpers worked. - Added some debugging tools

RE: [PATCH 2/2] drm/amdgpu: add sclk/uclk sensor support for vega20

2019-07-17 Thread Quan, Evan
I think the AMDGPU_PP_SENSOR_GFX_SCLK and AMDGPU_PP_SENSOR_GFX_MCLK requests are handled in smu_v11_0_read_sensor. It means it cannot reach navi10_ppt.c and vega20_ppt.c. Maybe this should be fixed in smu_v11_0_read_sensor. Regards, Evan > -Original Message- > From: amd-gfx On Behalf Of

Re: [PATCH 1/5] drm/amdgpu: allow direct submission in the VM backends

2019-07-17 Thread Kuehling, Felix
On 2019-07-17 5:10, Christian König wrote: > Am 16.07.19 um 18:40 schrieb Kuehling, Felix: >> On 2019-07-16 9:36 a.m., Christian König wrote: >>> Am 02.07.19 um 21:35 schrieb Kuehling, Felix: This assumes that page tables are resident when a page fault is handled. >>> Yeah, that is

Re: [PATCH v2] drm/amdgpu: Default disable GDS for compute VMIDs

2019-07-17 Thread Kuehling, Felix
On 2019-07-17 14:23, Greathouse, Joseph wrote: > The GDS and GWS blocks default to allowing all VMIDs to > access all entries. Graphics VMIDs can handle setting > these limits when the driver launches work. However, > compute workloads under HWS control don't go through the > kernel driver.

[PATCH v2] drm/amdgpu: Default disable GDS for compute VMIDs

2019-07-17 Thread Greathouse, Joseph
The GDS and GWS blocks default to allowing all VMIDs to access all entries. Graphics VMIDs can handle setting these limits when the driver launches work. However, compute workloads under HWS control don't go through the kernel driver. Instead, HWS firmware should set these limits when a process is

[PATCH] drm/amdgpu/pm: remove check for pp funcs in freq sysfs handlers

2019-07-17 Thread Alex Deucher
The dpm sensor function already does this for us. This fixes the freq*_input files with the new SMU implementation. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c | 10 -- 1 file changed, 10 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c

Re: [PATCH] drm/amdgpu: Default disable GDS for compute VMIDs

2019-07-17 Thread Kuehling, Felix
On 2019-07-17 13:11, Greathouse, Joseph wrote: > The GDS and GWS blocks default to allowing all VMIDs to > access all entries. Graphics VMIDs can handle setting > these limits when the driver launches work. However, > compute workloads under HWS control don't go through the > kernel driver.

[PATCH] drm/amdgpu: Default disable GDS for compute VMIDs

2019-07-17 Thread Greathouse, Joseph
The GDS and GWS blocks default to allowing all VMIDs to access all entries. Graphics VMIDs can handle setting these limits when the driver launches work. However, compute workloads under HWS control don't go through the kernel driver. Instead, HWS firmware should set these limits when a process is

Re: HMM related use-after-free with amdgpu

2019-07-17 Thread Jason Gunthorpe
On Tue, Jul 16, 2019 at 10:10:46PM +, Kuehling, Felix wrote: > On 2019-07-16 1:04 p.m., Michel Dänzer wrote: > > On 2019-07-16 6:35 p.m., Jason Gunthorpe wrote: > >> On Tue, Jul 16, 2019 at 06:31:09PM +0200, Michel Dänzer wrote: > >>> On 2019-07-15 7:25 p.m., Jason Gunthorpe wrote: > On

Re: [PATCH] drm/amdgpu: reserve GDS resources on the gfx ring for gfx10

2019-07-17 Thread Koenig, Christian
Am 17.07.19 um 16:54 schrieb Marek Olšák: On Wed., Jul. 17, 2019, 10:43 Christian König, mailto:ckoenig.leichtzumer...@gmail.com>> wrote: Am 17.07.19 um 16:27 schrieb Marek Olšák: On Wed., Jul. 17, 2019, 03:15 Christian König, mailto:ckoenig.leichtzumer...@gmail.com>> wrote: Am 17.07.19 um

Re: [PATCH] drm/amdkfd: Remove GWS from process during uninit

2019-07-17 Thread Kuehling, Felix
On 2019-07-17 10:58, Greathouse, Joseph wrote: > If we shut down a process without having destroyed its GWS-using > queues, it is possible that GWS BO will still be in the process > BO list during the gpuvm destruction. This list should be empty > at that time, so we should remove the GWS

Re: [PATCH] drm/amdkfd: Remove GWS from process during uninit

2019-07-17 Thread Deucher, Alexander
Acked-by: Alex Deucher From: amd-gfx on behalf of Greathouse, Joseph Sent: Wednesday, July 17, 2019 10:58 AM To: amd-gfx@lists.freedesktop.org Cc: Greathouse, Joseph Subject: [PATCH] drm/amdkfd: Remove GWS from process during uninit If we shut down a process

[PATCH] drm/amdkfd: Remove GWS from process during uninit

2019-07-17 Thread Greathouse, Joseph
If we shut down a process without having destroyed its GWS-using queues, it is possible that GWS BO will still be in the process BO list during the gpuvm destruction. This list should be empty at that time, so we should remove the GWS allocation at the process uninit point if it is still around.

Re: [PATCH] drm/amdgpu: reserve GDS resources on the gfx ring for gfx10

2019-07-17 Thread Marek Olšák
On Wed., Jul. 17, 2019, 10:43 Christian König, < ckoenig.leichtzumer...@gmail.com> wrote: > Am 17.07.19 um 16:27 schrieb Marek Olšák: > > > > On Wed., Jul. 17, 2019, 03:15 Christian König, < > ckoenig.leichtzumer...@gmail.com> wrote: > >> Am 17.07.19 um 02:06 schrieb Marek Olšák: >> > From: Marek

Re: [PATCH] drm/amdgpu: reserve GDS resources on the gfx ring for gfx10

2019-07-17 Thread Christian König
Am 17.07.19 um 16:27 schrieb Marek Olšák: On Wed., Jul. 17, 2019, 03:15 Christian König, > wrote: Am 17.07.19 um 02:06 schrieb Marek Olšák: > From: Marek Olšák mailto:marek.ol...@amd.com>> > > Hopefully we'll only use 1 gfx ring,

[PATCH 2/2] drm/amdgpu: add sclk/uclk sensor support for vega20

2019-07-17 Thread Alex Deucher
Query the metrics table to get the average sclk and uclk. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/powerplay/vega20_ppt.c | 35 ++ 1 file changed, 35 insertions(+) diff --git a/drivers/gpu/drm/amd/powerplay/vega20_ppt.c

[PATCH 1/2] drm/amdgpu: add sclk/uclk sensor support for navi

2019-07-17 Thread Alex Deucher
Query the metrics table to get the average sclk and uclk. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/powerplay/navi10_ppt.c | 34 ++ 1 file changed, 34 insertions(+) diff --git a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c

Re: [PATCH] drm/amdgpu: reserve GDS resources on the gfx ring for gfx10

2019-07-17 Thread Marek Olšák
On Wed., Jul. 17, 2019, 03:15 Christian König, < ckoenig.leichtzumer...@gmail.com> wrote: > Am 17.07.19 um 02:06 schrieb Marek Olšák: > > From: Marek Olšák > > > > Hopefully we'll only use 1 gfx ring, because otherwise we'd have to have > > separate GDS buffers for each gfx ring. > > > > This is

Re: [PATCH] drm/amd/amdgpu: Fix offset for vmid selection in debugfs interface

2019-07-17 Thread Deucher, Alexander
RB, thanks, Alex From: amd-gfx on behalf of StDenis, Tom Sent: Wednesday, July 17, 2019 8:44 AM To: Koenig, Christian; amd-gfx@lists.freedesktop.org Subject: Re: [PATCH] drm/amd/amdgpu: Fix offset for vmid selection in debugfs interface Thanks. Alex can I

Re: [PATCH] drm/amd/powerplay: report bootup clock as max supported on dpm disabled

2019-07-17 Thread Deucher, Alexander
Reviewed-by: Alex Deucher From: amd-gfx on behalf of Evan Quan Sent: Wednesday, July 17, 2019 5:34 AM To: amd-gfx@lists.freedesktop.org Cc: Deucher, Alexander; Xu, Feifei; Quan, Evan; Ma, Le Subject: [PATCH] drm/amd/powerplay: report bootup clock as max

Re: [PATCH 2/2] drm/amd/display: Add drm_audio_component support to amdgpu_dm

2019-07-17 Thread Takashi Iwai
On Wed, 10 Jul 2019 16:36:19 +0200, Takashi Iwai wrote: > > On Wed, 10 Jul 2019 16:31:40 +0200, > Kazlauskas, Nicholas wrote: > > > > On 7/10/19 9:48 AM, Takashi Iwai wrote: > > > On Tue, 09 Jul 2019 18:30:19 +0200, > > > Nicholas Kazlauskas wrote: > > >> > > >> [Why] > > >> The

Re: [PATCH v18 11/15] IB/mlx4: untag user pointers in mlx4_get_umem_mr

2019-07-17 Thread Andrey Konovalov
On Wed, Jul 17, 2019 at 1:58 PM Jason Gunthorpe wrote: > > On Wed, Jul 17, 2019 at 01:44:07PM +0200, Andrey Konovalov wrote: > > On Tue, Jul 16, 2019 at 2:06 PM Jason Gunthorpe wrote: > > > > > > On Tue, Jul 16, 2019 at 12:42:07PM +0200, Andrey Konovalov wrote: > > > > On Mon, Jul 15, 2019 at

Re: [PATCH] drm/amd/amdgpu: Fix offset for vmid selection in debugfs interface

2019-07-17 Thread StDenis, Tom
Thanks. Alex can I grab an R-b please? Cheers, Tom On 2019-07-16 7:30 a.m., Christian König wrote: > Am 16.07.19 um 13:24 schrieb StDenis, Tom: >> The register debugfs interface was using the wrong bitmask for vmid >> selection for GFX_CNTL. >> >> Signed-off-by: Tom St Denis > > Acked-by:

Re: [PATCH v18 11/15] IB/mlx4: untag user pointers in mlx4_get_umem_mr

2019-07-17 Thread Jason Gunthorpe
On Wed, Jul 17, 2019 at 01:44:07PM +0200, Andrey Konovalov wrote: > On Tue, Jul 16, 2019 at 2:06 PM Jason Gunthorpe wrote: > > > > On Tue, Jul 16, 2019 at 12:42:07PM +0200, Andrey Konovalov wrote: > > > On Mon, Jul 15, 2019 at 8:05 PM Jason Gunthorpe wrote: > > > > > > > > On Mon, Jul 15, 2019

Re: [PATCH v18 08/15] userfaultfd: untag user pointers

2019-07-17 Thread Andrey Konovalov
On Wed, Jul 17, 2019 at 1:09 PM Mike Rapoport wrote: > > On Mon, Jun 24, 2019 at 06:51:21PM +0100, Catalin Marinas wrote: > > On Mon, Jun 24, 2019 at 04:32:53PM +0200, Andrey Konovalov wrote: > > > This patch is a part of a series that extends kernel ABI to allow to pass > > > tagged user

Re: [PATCH v18 11/15] IB/mlx4: untag user pointers in mlx4_get_umem_mr

2019-07-17 Thread Andrey Konovalov
On Tue, Jul 16, 2019 at 2:06 PM Jason Gunthorpe wrote: > > On Tue, Jul 16, 2019 at 12:42:07PM +0200, Andrey Konovalov wrote: > > On Mon, Jul 15, 2019 at 8:05 PM Jason Gunthorpe wrote: > > > > > > On Mon, Jul 15, 2019 at 06:01:29PM +0200, Andrey Konovalov wrote: > > > > On Mon, Jun 24, 2019 at

Re: [PATCH v18 11/15] IB/mlx4: untag user pointers in mlx4_get_umem_mr

2019-07-17 Thread Andrey Konovalov
On Tue, Jul 16, 2019 at 2:06 PM Jason Gunthorpe wrote: > > On Tue, Jul 16, 2019 at 12:42:07PM +0200, Andrey Konovalov wrote: > > On Mon, Jul 15, 2019 at 8:05 PM Jason Gunthorpe wrote: > > > > > > On Mon, Jul 15, 2019 at 06:01:29PM +0200, Andrey Konovalov wrote: > > > > On Mon, Jun 24, 2019 at

Re: [PATCH v18 08/15] userfaultfd: untag user pointers

2019-07-17 Thread Mike Rapoport
On Mon, Jun 24, 2019 at 06:51:21PM +0100, Catalin Marinas wrote: > On Mon, Jun 24, 2019 at 04:32:53PM +0200, Andrey Konovalov wrote: > > This patch is a part of a series that extends kernel ABI to allow to pass > > tagged user pointers (with the top byte set to something else other than > > 0x00)

[PATCH] drm/amd/powerplay: report bootup clock as max supported on dpm disabled

2019-07-17 Thread Evan Quan
With gfxclk or uclk dpm disabled, it's reasonable to report bootup clock as the max supported. Change-Id: If8aa7a912e8a34414b0e9c2b46de9b6e316fd9d7 Signed-off-by: Evan Quan --- drivers/gpu/drm/amd/powerplay/amdgpu_smu.c | 27 ++- 1 file changed, 26 insertions(+), 1

Re: [PATCH 1/5] drm/amdgpu: allow direct submission in the VM backends

2019-07-17 Thread Christian König
Am 16.07.19 um 18:40 schrieb Kuehling, Felix: On 2019-07-16 9:36 a.m., Christian König wrote: Am 02.07.19 um 21:35 schrieb Kuehling, Felix: This assumes that page tables are resident when a page fault is handled. Yeah, that is correct. I also haven't completely figured out how we can prevent

kernel panic: stack is corrupted in pointer

2019-07-17 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:1438cde7 Add linux-next specific files for 20190716 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=1398805860 kernel config: https://syzkaller.appspot.com/x/.config?x=3430a151e1452331

Re: [PATCH 2/3] drm: introduce DRIVER_FORCE_AUTH

2019-07-17 Thread Koenig, Christian
Hi Emil, Sorry for the delay, finally coming back to this after my vacation. Am 03.07.19 um 17:14 schrieb Emil Velikov: > On Wed, 3 Jul 2019 at 15:58, Koenig, Christian > wrote: >> Am 03.07.2019 16:51 schrieb Emil Velikov : >> >> On Wed, 3 Jul 2019 at 15:33, Koenig, Christian >> wrote: >>>

Re: HMM related use-after-free with amdgpu

2019-07-17 Thread Michel Dänzer
On 2019-07-17 12:10 a.m., Kuehling, Felix wrote: > On 2019-07-16 1:04 p.m., Michel Dänzer wrote: >> On 2019-07-16 6:35 p.m., Jason Gunthorpe wrote: >>> On Tue, Jul 16, 2019 at 06:31:09PM +0200, Michel Dänzer wrote: On 2019-07-15 7:25 p.m., Jason Gunthorpe wrote: > On Mon, Jul 15, 2019 at

Re: [PATCH] drm/amdgpu: reserve GDS resources on the gfx ring for gfx10

2019-07-17 Thread Christian König
Am 17.07.19 um 02:06 schrieb Marek Olšák: From: Marek Olšák Hopefully we'll only use 1 gfx ring, because otherwise we'd have to have separate GDS buffers for each gfx ring. This is a workaround to ensure stability of transform feedback. Shaders hang waiting for a GDS instruction (ds_sub, not

Re: [PATCH v3 2/3] drm: plumb attaching dev thru to prime_pin/unpin

2019-07-17 Thread Koenig, Christian
Am 16.07.19 um 23:37 schrieb Rob Clark: > From: Rob Clark > > Needed in the following patch for cache operations. Well have you seen that those callbacks are deprecated? >* Deprecated hook in favour of _gem_object_funcs.pin. >* Deprecated hook in favour of