Re: [PATCH 2/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread axie
On 2017-06-12 06:47 PM, Christian König wrote: Am 12.06.2017 um 22:31 schrieb Alex Xie: Make the critical section smaller. There is no need to protect the bo_list, because there is no other task can access the newly created BO list yet. NAK, a task can guess the next id number so could get th

Re: [PATCH 1/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread axie
On 2017-06-12 07:00 PM, Christian König wrote: Am 12.06.2017 um 22:31 schrieb Alex Xie: This patch is to move a loop of unref BOs and several memory free function calls out of critical sections. Signed-off-by: Alex Xie --- drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 5 - 1 file change

Re: [PATCH 4/4] drm/amdgpu: Optimize mutex usage

2017-06-12 Thread axie
Hi Christian, Regarding comment 1. Please read the file idr.c line 24 to line 29. Let me quote here. Isn't it surprise you? idr_alloc only need read lock. ... * Simultaneous modifications to the @idr are not allowed and should be * prevented by the user, usually with a lock. idr_alloc() ma

[PATCH 2/2] drm/radeon: Fix overflow of watermark calcs at > 4k resolutions.

2017-06-12 Thread Mario Kleiner
Commit e6b9a6c84b93 ("drm/radeon: Make display watermark calculations more accurate") made watermark calculations more accurate, but not for > 4k resolutions on 32-Bit architectures, as it introduced an integer overflow for those setups and resolutions. Fix this by proper u64 casting and division.

[PATCH 1/2] drm/amdgpu: Fix overflow of watermark calcs at > 4k resolutions.

2017-06-12 Thread Mario Kleiner
Commit d63c277dc672e0 ("drm/amdgpu: Make display watermark calculations more accurate") made watermark calculations more accurate, but not for > 4k resolutions on 32-Bit architectures, as it introduced an integer overflow for those setups and resolutions. Fix this by proper u64 casting and divisio

Re: [PATCH] drm/amdgpu/gfx9: fix compute ring doorbell index

2017-06-12 Thread Zhang, Jerry (Junwei)
On 06/13/2017 11:01 AM, Alex Deucher wrote: This got lost when the code was revamped. Copy/paste bug from gfx8. Reported-by: Evan Quan Fixes: 78c168342 (drm/amdgpu: allow split of queues with kfd at queue granularity v4) Signed-off-by: Alex Deucher Reviewed-by: Junwei Zhang --- drivers

Re: [PATCH] drm/amdgpu/gfx: use a single pipe for vega10 for now

2017-06-12 Thread Alex Deucher
On Mon, Jun 12, 2017 at 3:17 PM, Alex Deucher wrote: > Spreading queues across pipes regresses performance right now > disable until we root cause the issue. > > Signed-off-by: Alex Deucher Ignore this patch. Evan found the root cause. Alex > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 6

[PATCH] drm/amdgpu/gfx9: fix compute ring doorbell index

2017-06-12 Thread Alex Deucher
This got lost when the code was revamped. Copy/paste bug from gfx8. Reported-by: Evan Quan Fixes: 78c168342 (drm/amdgpu: allow split of queues with kfd at queue granularity v4) Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 2 +- 1 file changed, 1 insertion(+), 1 dele

Re: [PATCH 1/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread Dave Airlie
On 13 June 2017 at 09:00, Christian König wrote: > Am 12.06.2017 um 22:31 schrieb Alex Xie: >> >> This patch is to move a loop of unref BOs and >> several memory free function calls out of >> critical sections. >> >> Signed-off-by: Alex Xie >> --- >> drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c

Re: [PATCH 1/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread Christian König
Am 12.06.2017 um 22:31 schrieb Alex Xie: This patch is to move a loop of unref BOs and several memory free function calls out of critical sections. Signed-off-by: Alex Xie --- drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/

Re: [PATCH 4/4] drm/amdgpu: Optimize mutex usage

2017-06-12 Thread Christian König
Am 12.06.2017 um 22:31 schrieb Alex Xie: Use rw_semaphore instead of mutex for bo_lists. In original function amdgpu_bo_list_get, the waiting for result->lock can be quite long while mutex bo_list_lock was holding. It can make other tasks waiting for bo_list_lock for long period too. Change bo_l

Re: [PATCH 3/4] drm/amdgpu: Optimization of mutex usage

2017-06-12 Thread Christian König
Am 12.06.2017 um 22:31 schrieb Alex Xie: There is no need to lock the bo_list mutex, because there is no other task can access the newly created BO list yet. Again NAK, this can race as well when a task guess the next ID number or incorrectly uses an old one. Christian. Signed-off-by: Ale

Re: [PATCH 2/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread Christian König
Am 12.06.2017 um 22:31 schrieb Alex Xie: Make the critical section smaller. There is no need to protect the bo_list, because there is no other task can access the newly created BO list yet. NAK, a task can guess the next id number so could get the kernel to use the structure before it is initi

[PATCH 4/4] drm/amdgpu: Optimize mutex usage

2017-06-12 Thread Alex Xie
Use rw_semaphore instead of mutex for bo_lists. In original function amdgpu_bo_list_get, the waiting for result->lock can be quite long while mutex bo_list_lock was holding. It can make other tasks waiting for bo_list_lock for long period too. Change bo_list_lock to rw_semaphore can avoid most of

[PATCH 3/4] drm/amdgpu: Optimization of mutex usage

2017-06-12 Thread Alex Xie
There is no need to lock the bo_list mutex, because there is no other task can access the newly created BO list yet. Signed-off-by: Alex Xie --- drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c b/driver

[PATCH 2/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread Alex Xie
Make the critical section smaller. There is no need to protect the bo_list, because there is no other task can access the newly created BO list yet. Signed-off-by: Alex Xie --- drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dri

[PATCH 1/4] drm/amdgpu: Optimization of critical section

2017-06-12 Thread Alex Xie
This patch is to move a loop of unref BOs and several memory free function calls out of critical sections. Signed-off-by: Alex Xie --- drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_bo_list.c

[PATCH] drm/amdgpu/gfx: use a single pipe for vega10 for now

2017-06-12 Thread Alex Deucher
Spreading queues across pipes regresses performance right now disable until we root cause the issue. Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers

Re: [PATCH] drm/amd/display: Guard some DCN-only code in dc_debug

2017-06-12 Thread Tom St Denis
Acked-By: Tom St Denis It fixes the compile error but since I'm out of time today to actually test that's about all I can say. :-) Tom On 12/06/17 03:01 PM, Harry Wentland wrote: Fixing a compile error when building without CONFIG_DRM_AMD_DC_DCN1_0 Signed-off-by: Harry Wentland --- dri

[PATCH] drm/amd/display: Guard some DCN-only code in dc_debug

2017-06-12 Thread Harry Wentland
Fixing a compile error when building without CONFIG_DRM_AMD_DC_DCN1_0 Signed-off-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc_debug.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_debug.c b/drivers/gpu/drm/amd/display/dc/core/dc_de

[PATCH 02/10] drm/amd/amdgpu: Port GFXHUB over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c | 26 -- 1 file changed, 12 insertions(+), 14 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c b/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c index 90e6c28568eb..1c0b148b 100644 --

[PATCH 04/10] drm/amd/amdgpu: Port MMHUB over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c | 25 +++-- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c b/drivers/gpu/drm/amd/amdgpu/mmhub_v1_0.c index 564d66c73875..f50b5a77f45a 100644 --- a/

[PATCH 06/10] drm/amd/amdgpu: Port NBIO v6.1 driver over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/nbio_v6_1.c | 54 +++--- 1 file changed, 23 insertions(+), 31 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nbio_v6_1.c b/drivers/gpu/drm/amd/amdgpu/nbio_v6_1.c index 97057f4a10de..1e272f785def 100644

[PATCH 07/10] drm/amd/amdgpu: Port NBIO v7.0 driver over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/nbio_v7_0.c | 42 ++ 1 file changed, 17 insertions(+), 25 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/nbio_v7_0.c b/drivers/gpu/drm/amd/amdgpu/nbio_v7_0.c index 7e1206d1df6a..aa04632523fa 100644

[PATCH 08/10] drm/amd/amdgpu: Port PSP v3.1 over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/psp_v3_1.c | 32 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v3_1.c b/drivers/gpu/drm/amd/amdgpu/psp_v3_1.c index 60a6407ba267..58ba3966f070 100644 --- a

[PATCH 10/10] drm/amd/amdgpu: Port VCN over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c | 164 +- 1 file changed, 82 insertions(+), 82 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c b/drivers/gpu/drm/amd/amdgpu/vcn_v1_0.c index ec33e8fa83c1..21e7b88401e1 100644 --

[PATCH 09/10] drm/amd/amdgpu: Port PSP v10.0 over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/psp_v10_0.c | 14 +++--- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c b/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c index 8eb21fd83172..00c0f281f972 100644 --- a/drivers/gpu/drm/

Various SOC15 macro cleanups

2017-06-12 Thread Tom St Denis
These replace some of the more verbose patterns with new SOC15 macros. Should be no functional change to anything. ___ amd-gfx mailing list amd-gfx@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/amd-gfx

[PATCH 03/10] drm/amd/amdgpu: Cleanup gfxhub read-modify-write patterns

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c | 11 +++ 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c b/drivers/gpu/drm/amd/amdgpu/gfxhub_v1_0.c index 1c0b148b..a42f483767e7 100644 --- a/drivers/gpu/d

[PATCH 01/10] drm/amd/amdgpu: Add offset variant to SOC15 macros

2017-06-12 Thread Tom St Denis
Allows reading/writing via SOC15 macros with offset for various register banks. Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/soc15_common.h | 14 ++ 1 file changed, 14 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/soc15_common.h b/drivers/gpu/drm/amd/amdgpu/so

[PATCH 05/10] drm/amd/amdgpu: Port UVD 7.0 over to new SOC15 macros

2017-06-12 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c | 174 +- 1 file changed, 87 insertions(+), 87 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c b/drivers/gpu/drm/amd/amdgpu/uvd_v7_0.c index dd9ec81f116d..987b958368ac 100644 --

RE: [PATCH] drm/amd/amdgpu: gfx9 tidy ups (v2)

2017-06-12 Thread Deucher, Alexander
> -Original Message- > From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf > Of Tom St Denis > Sent: Monday, June 12, 2017 9:18 AM > To: amd-gfx@lists.freedesktop.org > Cc: StDenis, Tom > Subject: [PATCH] drm/amd/amdgpu: gfx9 tidy ups (v2) > > A couple of simple tidy ups

RE: [PATCH 2/2] drm/amd/amdgpu: Rename KIQ ring to avoid spaces

2017-06-12 Thread Deucher, Alexander
> -Original Message- > From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf > Of Tom St Denis > Sent: Monday, June 12, 2017 9:06 AM > To: amd-gfx@lists.freedesktop.org > Cc: StDenis, Tom > Subject: [PATCH 2/2] drm/amd/amdgpu: Rename KIQ ring to avoid spaces > > Swap space

RE: [PATCH libdrm] amdgpu: Add .editorconfig file for amdgpu coding style

2017-06-12 Thread Deucher, Alexander
> -Original Message- > From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf > Of Michel Dänzer > Sent: Monday, June 12, 2017 6:03 AM > To: amd-gfx@lists.freedesktop.org > Subject: [PATCH libdrm] amdgpu: Add .editorconfig file for amdgpu coding > style > > From: Michel Dän

RE: [PATCH libdrm] amdgpu: move asic id table to a separate file

2017-06-12 Thread Deucher, Alexander
> -Original Message- > From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf > Of Michel Dänzer > Sent: Monday, June 12, 2017 5:50 AM > To: amd-gfx@lists.freedesktop.org > Cc: dri-de...@lists.freedesktop.org > Subject: [PATCH libdrm] amdgpu: move asic id table to a separate

Re: [PATCH] drm/core: Fail atomic IOCTL with no CRTC state but with signaling.

2017-06-12 Thread Andrey Grodzovsky
On 06/12/2017 07:08 AM, Maarten Lankhorst wrote: Op 09-06-17 om 23:30 schreef Andrey Grodzovsky: Problem: While running IGT kms_atomic_transition test suite i encountered a hang in drmHandleEvent immidietly follwoing an atomic_commit. After dumping the atomic state I relized that in this case

Re: [Intel-gfx] [PATCH i-g-t] tests: Rename I915_MAX_PIPES to IGT_MAX_PIPES

2017-06-12 Thread Harry Wentland
On 2017-06-12 07:54 AM, Arkadiusz Hiler wrote: > On Fri, Jun 09, 2017 at 06:14:52PM -0400, Harry Wentland wrote: >> Reviewed-by: Harry Wentland >> >> Harry > > Hey, > > Was the mail sent here in the first place? I cannot find it. I would > like to apply it, but having no easily digestible form a

[PATCH] drm/amd/amdgpu: gfx9 tidy ups (v2)

2017-06-12 Thread Tom St Denis
A couple of simple tidy ups to register programming. Signed-off-by: Tom St Denis (v2): Avoid using 'data' unitialized --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 26 +++--- 1 file changed, 7 insertions(+), 19 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c

Re: amdgpu display corruption and hang on AMD A10-9620P

2017-06-12 Thread Carlo Caione
On Tue, May 9, 2017 at 7:03 PM, Deucher, Alexander wrote: >> -Original Message- >> From: Daniel Drake [mailto:dr...@endlessm.com] >> Sent: Tuesday, May 09, 2017 12:55 PM >> To: dri-devel; amd-gfx@lists.freedesktop.org; Deucher, Alexander >> Cc: Chris Chiu; Linux Upstreaming Team >> Subject

Re: [PATCH 00/27] DC Linux Patches Jun 9, 2017

2017-06-12 Thread Harry Wentland
On 2017-06-12 07:12 AM, Tom St Denis wrote: > These don't apply on top of 4.11 it fails on patch 4 "drm/amd/display: > Universal cursor plane hook-up." > > Maybe a rebase mistake when 4.11 was created? > I think the previous set is still missing. I'll merge the lot today. Harry > Tom > > On 0

[PATCH 2/2] drm/amd/amdgpu: Rename KIQ ring to avoid spaces

2017-06-12 Thread Tom St Denis
Swap space for underscore in ring name. Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_gfx.c index dfbf0273585f..e26108aad3fe

[PATCH 1/2] drm/amd/amdgpu: gfx9 tidy ups

2017-06-12 Thread Tom St Denis
A couple of simple tidy ups to register programming. Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 26 +++--- 1 file changed, 7 insertions(+), 19 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.

Re: [Intel-gfx] [PATCH i-g-t v2] tests: Increase value of I915_MAX_PIPES to 6

2017-06-12 Thread Arkadiusz Hiler
On Fri, Jun 09, 2017 at 08:43:18PM +, Deucher, Alexander wrote: > > -Original Message- > > From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf > > Of sunpeng...@amd.com > > Sent: Friday, June 09, 2017 4:18 PM > > To: intel-...@lists.freedesktop.org; amd-gfx@lists.free

Re: [PATCH libdrm] amdgpu: Add .editorconfig file for amdgpu coding style

2017-06-12 Thread Christian König
Am 12.06.2017 um 12:03 schrieb Michel Dänzer: From: Michel Dänzer The .editorconfig file in the toplevel directory doesn't match. Signed-off-by: Michel Dänzer Acked-by: Christian König --- amdgpu/.editorconfig | 9 + 1 file changed, 9 insertions(+) create mode 100644 amdgpu/

Re: [Intel-gfx] [PATCH i-g-t] tests: Rename I915_MAX_PIPES to IGT_MAX_PIPES

2017-06-12 Thread Arkadiusz Hiler
On Fri, Jun 09, 2017 at 06:14:52PM -0400, Harry Wentland wrote: > Reviewed-by: Harry Wentland > > Harry Hey, Was the mail sent here in the first place? I cannot find it. I would like to apply it, but having no easily digestible form available makes it hard. Can you re-sent it to intel-gfx? --

Re: [PATCH 00/27] DC Linux Patches Jun 9, 2017

2017-06-12 Thread Tom St Denis
These don't apply on top of 4.11 it fails on patch 4 "drm/amd/display: Universal cursor plane hook-up." Maybe a rebase mistake when 4.11 was created? Tom On 09/06/17 04:11 PM, Harry Wentland wrote: * Universal cursor plane * Bunch of Raven fixes * Couple of fixes for IGT Amy Zhang (3):

Re: [PATCH] drm/core: Fail atomic IOCTL with no CRTC state but with signaling.

2017-06-12 Thread Maarten Lankhorst
Op 09-06-17 om 23:30 schreef Andrey Grodzovsky: > Problem: > While running IGT kms_atomic_transition test suite i encountered > a hang in drmHandleEvent immidietly follwoing an atomic_commit. > After dumping the atomic state I relized that in this case there was > not even one CRTC attached to the

[PATCH libdrm] amdgpu: Add .editorconfig file for amdgpu coding style

2017-06-12 Thread Michel Dänzer
From: Michel Dänzer The .editorconfig file in the toplevel directory doesn't match. Signed-off-by: Michel Dänzer --- amdgpu/.editorconfig | 9 + 1 file changed, 9 insertions(+) create mode 100644 amdgpu/.editorconfig diff --git a/amdgpu/.editorconfig b/amdgpu/.editorconfig new file m

[PATCH libdrm] amdgpu: move asic id table to a separate file

2017-06-12 Thread Michel Dänzer
From: Xiaojie Yuan v2: fix an off by one error and leading white spaces v3: use thread safe strtok_r(); initialize len before calling getline(); change printf() to drmMsg(); add initial amdgpu.ids v4: integrate some recent internal changes, including format changes v5: fix line number for emp

Fwd: [repo.or.cz] agd5f-linux clone failed

2017-06-12 Thread Yurii Kolesnykov
I had tried to create a mirror for agd5f/linux Git repo with the following error. Can you fix it? -- Forwarded message - From: repo.or.cz Date: сб, 10 черв. 2017 о 18:57 Subject: [repo.or.cz] agd5f-linux clone failed To: Condolences. The clone of project agd5f-linux just faile