Re: [PATCH v1 1/6] dma-buf: Add _unlocked postfix to function names

2022-07-15 Thread Christian König
Am 15.07.22 um 11:31 schrieb Dmitry Osipenko: On 7/15/22 10:19, Christian König wrote: -struct sg_table *dma_buf_map_attachment(struct dma_buf_attachment *attach, -    enum dma_data_direction direction) +struct sg_table * +dma_buf_map_attachment_unlocked(struct

RE: [PATCH 3/3] drm/amdgpu: skip put fence if signal fails

2022-07-15 Thread Zhu, Jiadong
[AMD Official Use Only - General] Updated some comments -Original Message- From: Zhu, Jiadong Sent: Friday, July 15, 2022 5:13 PM To: Christian König ; amd-gfx@lists.freedesktop.org; Grodzovsky, Andrey Cc: Huang, Ray ; Liu, Aaron Subject: RE: [PATCH 3/3] drm/amdgpu: skip put fence if

RE: [PATCH 3/3] drm/amdgpu: skip put fence if signal fails

2022-07-15 Thread Zhu, Jiadong
[AMD Official Use Only - General] Hi Christian, The resubmitted job in function amdgpu_ib_preempt_job_recovery returns the same hw fence because of this commit: static void amdgpu_ib_preempt_job_recovery(struct drm_gpu_scheduler *sched) { struct drm_sched_job *s_job; struct

Re: [PATCH 3/3] drm/amdgpu: skip put fence if signal fails

2022-07-15 Thread Christian König
Am 15.07.22 um 10:43 schrieb jiadong@amd.com: From: "Jiadong.Zhu" Dma_fence_signal returning non-zero indicates that the fence is signaled and put somewhere else. Skip dma_fence_put to make the fence refcount correct. Well quite a big NAK on this. Reference counting should be completely

[PATCH 2/3] drm/amdgpu: add mcbp support for sdma v4.0

2022-07-15 Thread jiadong.zhu
From: "Jiadong.Zhu" Set register to enable mcbp according to amdgpu_mcbp. Add sdma preempt_ib function used for debugfs test. --- drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c | 53 ++ 1 file changed, 53 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c

[PATCH 3/3] drm/amdgpu: skip put fence if signal fails

2022-07-15 Thread jiadong.zhu
From: "Jiadong.Zhu" Dma_fence_signal returning non-zero indicates that the fence is signaled and put somewhere else. Skip dma_fence_put to make the fence refcount correct. Signed-off-by: Jiadong.Zhu --- drivers/gpu/drm/amd/amdgpu/amdgpu_debugfs.c | 4 ++-- 1 file changed, 2 insertions(+), 2

[PATCH 1/3] drm/amdgpu: modify mcbp implement for gfx9

2022-07-15 Thread jiadong.zhu
From: "Jiadong.Zhu" 1. Use unmap_queue package to trigger preemption on gfx9 Add trailing fence to track the preemption done. 2. Modify emit_ce_meta emit_de_meta functions for the resumed ibs. --- drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 1 + drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c|

Re: [PATCH] drm/amdgpu: align between libdrm and drm api

2022-07-15 Thread Christian König
Am 14.07.22 um 23:22 schrieb Ruijing Dong: define HW_IP_VCN_UNIFIED the same as HW_IP_VCN_ENC Usually that should be the other way around, libdrm aligns to the kernel. Why was that modification committed to libdrm first? There are usually plenty of warnings before we can do that. Regards,

[bug report] drm/amd/display: Add basic infrastructure for enabling FAMS

2022-07-15 Thread Dan Carpenter
Hello Rodrigo Siqueira, This is a semi-automatic email about new static checker warnings. The patch 00fa7f031dd4: "drm/amd/display: Add basic infrastructure for enabling FAMS" from Jun 16, 2022, leads to the following Smatch complaint:

Re: [PATCH -next] drm/amdgpu: double free error and freeing uninitialized null pointer

2022-07-15 Thread Somalapuram, Amaranath
On 7/14/2022 9:13 PM, André Almeida wrote: Às 12:06 de 14/07/22, Sebin Sebastian escreveu: On Tue, Jul 12, 2022 at 12:14:27PM -0300, André Almeida wrote: Hi Sebin, Às 10:29 de 10/07/22, Sebin Sebastian escreveu: Fix two coverity warning's double free and and an uninitialized pointer read.

Re: [PATCH v1 2/6] drm/gem: Take reservation lock for vmap/vunmap operations

2022-07-15 Thread Christian König
Am 15.07.22 um 02:52 schrieb Dmitry Osipenko: The new common dma-buf locking convention will require buffer importers to hold the reservation lock around mapping operations. Make DRM GEM core to take the lock around the vmapping operations and update QXL and i915 drivers to use the locked

Re: [PATCH v1 1/6] dma-buf: Add _unlocked postfix to function names

2022-07-15 Thread Christian König
Am 15.07.22 um 02:52 schrieb Dmitry Osipenko: Add _unlocked postfix to the dma-buf API function names in a preparation to move all non-dynamic dma-buf users over to the dynamic locking specification. This patch only renames API functions, preparing drivers to the common locking convention. Later

Re: [PATCH v1 4/6] dma-buf: Acquire wait-wound context on attachment

2022-07-15 Thread Christian König
Am 15.07.22 um 02:52 schrieb Dmitry Osipenko: Intel i915 GPU driver uses wait-wound mutex to lock multiple GEMs on the attachment to the i915 dma-buf. In order to let all drivers utilize shared wait-wound context during attachment in a general way, make dma-buf core to acquire the ww context

Re: [PATCH] drm/ttm: fix missing NULL check in ttm_device_swapout

2022-07-15 Thread Christian König
Am 14.07.22 um 23:58 schrieb Felix Kuehling: Backport of Christian's patch 81b0d0e4f811 to amd-staging-drm-next. This branch may be nearly obsolete, but this patch may still be worth applying as it can serve as a template for backports to some release branches. It fixes intermittent kernel

Re: [PATCH] drm/amdkfd: Remove Align VRAM allocations to 1MB on APU ASIC

2022-07-15 Thread Kuehling, Felix
[AMD Official Use Only - General] As a compromise we are considering a change that restores the old allocation behaviour, keeping the more conservative estimate only for the available-memory API. Regards, Felix From: Guo, Shikai Sent: Thursday, July 14,