[PATCH 2/3] drm/amdgpu/gfx9: update mqd to include dynamic CU mask

2017-08-18 Thread Alex Deucher
Necessary for proper operation with KIQ. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/include/v9_structs.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/include/v9_structs.h

[PATCH 3/3] drm/amdgpu/gfx9: adjust mqd allocation size

2017-08-18 Thread Alex Deucher
to allocate additional space for the dynamic cu masks. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c| 25 ++--- drivers/gpu/drm/amd/include/v9_structs.h | 8 2 files changed, 26 insertions(+), 7 deletions(-)

[PATCH 1/3] drm/amdgpu/gfx8: fix spelling typo in mqd allocation

2017-08-18 Thread Alex Deucher
Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c| 12 ++-- drivers/gpu/drm/amd/include/vi_structs.h | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v8_0.c

Re: [PATCH] drm/ttm: Add DMA map/unmap tracepoint (v3)

2017-08-18 Thread Tom St Denis
Hi Christian, Should I wait for comments on dri-devel or can I push the TTM trace patches to our stg-4.12 already? Cheers, Tom On 18/08/17 09:45 AM, Christian König wrote: Am 18.08.2017 um 15:22 schrieb Tom St Denis: Also exports two functions that vendor drivers can call to trace DMA

[PATCH 2/6 v2] drm/amdgpu Moving amdgpu asic types to a separate file

2017-08-18 Thread Alex Deucher
From: Akshu Agrawal Amdgpu asic types will be required for other drivers too. Hence, its better to keep it in a separate include file. Reviewed-by: Alex Deucher Signed-off-by: Akshu Agrawal Signed-off-by: Alex Deucher

[PATCH 0/6 v3] Add ASoC support for AMD Stoney APUs

2017-08-18 Thread Alex Deucher
This patch set updates the AMD GPU and Audio CoProcessor (ACP) audio drivers and the designware i2s driver for Stoney (ST). ST is an APU similar to Carrizo (CZ) which already has ACP audio support. The i2s controller and ACP audio DMA engine are part of the GPU and both need updating so I would

[pull] radeon and amdgpu drm-next-4.14

2017-08-18 Thread Alex Deucher
Hi Dave, More changes for 4.14. Highlights: - command submission overhead improvements - Huge page support for vega10 - physical mode support for mjpeg for asics that don't support UVD vm - improve ttm_mem_type_manager_func debug - misc ttm fixes, cleanups - misc gpuvm cleanups The following

Re: [PATCH 22/24] drm/amdkfd: Adding new IOCTL for scratch memory v2

2017-08-18 Thread Oded Gabbay
On Wed, Aug 16, 2017 at 6:00 AM, Felix Kuehling wrote: > From: Moses Reuben > > v2: > * Renamed ALLOC_MEMORY_OF_SCRATCH to SET_SCRATCH_BACKING_VA > * Removed size parameter from the ioctl, it was unused > * Removed hole in ioctl number space > * No

Re: [PATCH] drm/amdgpu: Fix huge page updates with CPU

2017-08-18 Thread Christian König
Am 18.08.2017 um 17:18 schrieb Felix Kuehling: Correctly detect system memory mappings when using CPU and don't use huge pages for them. Avoid incorrectly translating a physical page table GPU address when splitting a huge page while mapping system memory. Signed-off-by: Felix Kuehling

[PATCH 2/2] drm/radeon: use new TTM populate/dma map helper functions

2017-08-18 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/radeon/radeon_ttm.c | 33 ++--- 1 file changed, 2 insertions(+), 31 deletions(-) diff --git a/drivers/gpu/drm/radeon/radeon_ttm.c b/drivers/gpu/drm/radeon/radeon_ttm.c index

[PATCH] drm/ttm: Add helper functions to populate/map in one call

2017-08-18 Thread Tom St Denis
These functions replace a section of common code found in radeon/amdgpu drivers (and possibly others) as part of the ttm_tt_*populate() callbacks. Signed-off-by: Tom St Denis --- drivers/gpu/drm/ttm/ttm_page_alloc.c | 41

[PATCH 1/2] drm/amd/amdgpu: Use new TTM populate/map helper function

2017-08-18 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 33 ++--- 1 file changed, 2 insertions(+), 31 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c index

[PATCH 1/2] drm/ttm: Add DMA map/unmap tracepoint (v3)

2017-08-18 Thread Tom St Denis
Also exports two functions that vendor drivers can call to trace DMA mappings. This is meant to help translate IOMMU mappings of bus addresses back to physical pages. Used by the umr amdgpu debugger for instance. Signed-off-by: Tom St Denis Reviewed-by: Christian König

[PATCH 2/2] drm/amd/amdgpu: Remove AMDGPU tracepoint and use new TTM tracepoint (v2)

2017-08-18 Thread Tom St Denis
Switches the AMDGPU driver over to the TTM tracepoint and removes our old one. Now you can enable traces before loading the module and trace all mappings. Signed-off-by: Tom St Denis Reviewed-by: Christian König (v2): Use struct device instead of

Re: [PATCH] drm/ttm: Add DMA map/unmap tracepoint (v3)

2017-08-18 Thread Christian König
Am 18.08.2017 um 15:22 schrieb Tom St Denis: Also exports two functions that vendor drivers can call to trace DMA mappings. This is meant to help translate IOMMU mappings of bus addresses back to physical pages. Used by the umr amdgpu debugger for instance. Signed-off-by: Tom St Denis

[PATCH] drm/ttm: Add DMA map/unmap tracepoint (v3)

2017-08-18 Thread Tom St Denis
Also exports two functions that vendor drivers can call to trace DMA mappings. This is meant to help translate IOMMU mappings of bus addresses back to physical pages. Used by the umr amdgpu debugger for instance. Signed-off-by: Tom St Denis (v2): Use dev_name() to get PCI

[PATCH] drm/ttm: use reservation_object_trylock in ttm_bo_individualize_resv v2

2017-08-18 Thread Christian König
From: Christian König Fixes a false positive from might_sleep(). The reservation object is freshly initialized, so nobody else can hold the mutex but the function is called from atomic context. v2: Correctly invert the check as well. Signed-off-by: Christian König

Re: [PATCH 1/2] drm/ttm: Add DMA map/unmap tracepoint (v2)

2017-08-18 Thread Christian König
Am 18.08.2017 um 14:54 schrieb Tom St Denis: Also exports two functions that vendor drivers can call to trace DMA mappings. This is meant to help translate IOMMU mappings of bus addresses back to physical pages. Used by the umr amdgpu debugger for instance. Sorry to have even more notes on

[PATCH umr] Switch over to TTM trace point from AMDGPU tracepoint

2017-08-18 Thread Tom St Denis
Signed-off-by: Tom St Denis --- src/lib/read_vram.c | 20 ++-- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/src/lib/read_vram.c b/src/lib/read_vram.c index 7516484bb4af..f38748c1b94d 100644 --- a/src/lib/read_vram.c +++

[PATCH 2/2] drm/amd/amdgpu: Remove AMDGPU tracepoint and use new TTM tracepoint (v2)

2017-08-18 Thread Tom St Denis
Switches the AMDGPU driver over to the TTM tracepoint and removes our old one. Now you can enable traces before loading the module and trace all mappings. Signed-off-by: Tom St Denis (v2): Use struct device instead of pci in trace. ---

[PATCH 1/2] drm/ttm: Add DMA map/unmap tracepoint (v2)

2017-08-18 Thread Tom St Denis
Also exports two functions that vendor drivers can call to trace DMA mappings. This is meant to help translate IOMMU mappings of bus addresses back to physical pages. Used by the umr amdgpu debugger for instance. Signed-off-by: Tom St Denis (v2): Use dev_name() to get PCI

[PATCH xf86-video-amdgpu 1/3] Consolidate amdgpu_scanout_flip_abort/handler helpers

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer While at it, make them use crtc->driver_private. (Ported from radeon commit 36ce7920136c0d723c9397a84e7dd5926a9c7943) Signed-off-by: Michel Dänzer --- src/amdgpu_kms.c | 85

[PATCH xf86-video-amdgpu 2/3] Use xorg_list_append for the DRM event list

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer We were adding entries at the start of the list, i.e. the list was ordered from most recently added to least recently added. However, the corresponding DRM events are generally expected to arrive in the same order as they are queued, which means that

[PATCH xf86-video-amdgpu 3/3] Make amdgpu_scanout_do_update take a PixmapPtr instead of a DrawablePtr

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer All callers were already passing in a pixmap. This allows simplifying the rotated scanout case slightly. (Ported from radeon commit d822a0f47070374ad0c1a97b559bae27724dc52a) Signed-off-by: Michel Dänzer --- src/amdgpu_drv.h

[PATCH xf86-video-amdgpu 04/10] Create drmmode_crtc_wait_pending_event helper macro

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Preparation for following change, no functional change intended yet. (Ported from radeon commit f87acdbfb1b0b6d2769764772a52ea8b81675e20) Signed-off-by: Michel Dänzer --- src/drmmode_display.c | 14 ++ 1 file

[PATCH xf86-video-amdgpu 07/10] Add source drawable parameter to amdgpu_scanout_do_update

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Preparation for following changes, no functional change intended yet. (Ported from radeon commit 1443270e52e8562bd8dc3603f301963bd4027cef) Signed-off-by: Michel Dänzer --- src/amdgpu_drv.h | 3 ++- src/amdgpu_kms.c

[PATCH xf86-video-amdgpu 05/10] Wait for pending flips synchronously before turning off a CRTC

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Allows removing drmmode_clear_pending_flip and the pending_dpms_mode field and cleaning up the code considerably. (Ported from radeon commit e6d7dc2070f4d21a6900916bb70a31839112882c) Signed-off-by: Michel Dänzer ---

[PATCH xf86-video-amdgpu 08/10] Pass extents to amdgpu_scanout_do_update

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Preparation for following change, no functional change intended yet. (Ported from radeon commit 65e0c5ea1b4adff21d673dbf54af99704c429627) Signed-off-by: Michel Dänzer --- src/amdgpu_drv.h | 2 +- src/amdgpu_kms.c

[PATCH xf86-video-amdgpu 06/10] Handle multiple "pending" Present flips

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer The xserver Present code can submit a flip in response to notifying it that a vblank event arrived. This can happen before the completion event of the previous flip is processed. In that case, we were clearing the drmmode_crtc->flip_pending field

[PATCH xf86-video-amdgpu 09/10] Always allow Present page flipping with TearFree

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Even if TearFree is active for the the CRTC we're synchronizing to. In that case, for Present flips synchronized to vertical blank, the other scanout buffer is immediately synchronized and flipped to during the target vertical blank period. For Present

[PATCH xf86-video-amdgpu 03/10] Create drmmode_wait_vblank helper

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Allows cleaning up the code considerably. (Ported from radeon commit 99f1d7a474af3683fe1a66f50c0bb8935478ff0a) Signed-off-by: Michel Dänzer --- src/amdgpu_dri2.c | 97 +++

[PATCH xf86-video-amdgpu 02/10] Pass reference CRTC to amdgpu_do_pageflip directly

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Simplifies the code slightly. (Ported from radeon commit 49cc61ab970ee28d4509b4e2dd0a57165136889f) Signed-off-by: Michel Dänzer --- src/amdgpu_dri2.c | 4 +--- src/amdgpu_present.c | 6 ++ src/drmmode_display.c |

[PATCH xf86-video-amdgpu 01/10] Remove drmmode_crtc->scanout_destroy[] array

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer No longer necessary since we're reference counting framebuffers. (Ported from radeon commit 3f120fa1d5d921656a367751bc079e020e9ab105) Signed-off-by: Michel Dänzer --- src/drmmode_display.c | 22 --

[PATCH xf86-video-amdgpu 10/10] Always allow DRI2 page flipping with TearFree

2017-08-18 Thread Michel Dänzer
From: Michel Dänzer Even if TearFree is enabled for the CRTC we're synchronizing to. (Ported from radeon commit d314cbfb228bb4b8762714f98d0c114a8ee3f061) Signed-off-by: Michel Dänzer --- man/amdgpu.man| 6 ++ src/amdgpu_dri2.c | 2 -- 2

Re: [PATCH 1/2] drm/ttm: Add DMA map/unmap tracepoint

2017-08-18 Thread Christian König
Am 17.08.2017 um 14:29 schrieb Tom St Denis: Also exports two functions that vendor drivers can call to trace DMA mappings. This is meant to help translate IOMMU mappings of bus addresses back to physical pages. Used by the umr amdgpu debugger for instance. Signed-off-by: Tom St Denis

[PATCH] drm/ttm: use reservation_object_trylock in ttm_bo_individualize_resv

2017-08-18 Thread Christian König
From: Christian König Fixes a false positive from might_sleep(). The reservation object is freshly initialized, so nobody else can hold the mutex but the function is called from atomic context. Signed-off-by: Christian König ---

Re: [PATCH] drm/atomic: put commit when -ERESTARTSYS received

2017-08-18 Thread Daniel Vetter
On Thu, Aug 17, 2017 at 10:21:18AM -0400, Jerry Zuo wrote: > During page flip atomic_check and atomic_commit can return > -ERESTARTSYS to restart the ioctl. When this happens we fail to > put the commit object leading to a memory leak. > > v2: Changed subject tag to drm/atomic > > Signed-off-by:

Re: [PATCH] drm/amdgpu: fix a bogus warning

2017-08-18 Thread Christian König
Reviewed-by: Christian König Am 17.08.2017 um 23:03 schrieb Xie, AlexBin: Reviewed-by: Alex Xie *From:* amd-gfx on behalf of

Re: [PATCH] drm/amdgpu/virtual_dce: Virtual display doesn't support disable vblank immediately

2017-08-18 Thread Michel Dänzer
On 18/08/17 02:48 PM, Emily Deng wrote: > For virtual display, it uses software timer to emulate the vsync interrupt, > it doesn't have high precision, so doesn't support disable vblank immediately. > > BUG: SWDEV-129274 > > Signed-off-by: Emily Deng > --- >