[PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Ken Wang
Change-Id: If00d5b97ba9e30f9b7f68fdfc134a0f8b3ad2add Signed-off-by: Ken Wang --- drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c | 7 ++- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 7 ++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c b/drivers/g

Re: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Christian König
Am 21.07.2016 um 09:46 schrieb Ken Wang: Change-Id: If00d5b97ba9e30f9b7f68fdfc134a0f8b3ad2add Signed-off-by: Ken Wang --- drivers/gpu/drm/amd/amdgpu/gmc_v7_0.c | 7 ++- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 7 ++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/driv

答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Wang, Qingqing
This doesn't work on 32bit systems since totalram is a long (IIRC) and so this will certainly overflow. -- can you be more specific, how could the overflow happen? Additional if I remember correctly we didn't ended the discussion on what to do here with a conclusion. -- ok, since it happens in

Re: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Christian König
Am 21.07.2016 um 11:16 schrieb Wang, Qingqing: This doesn't work on 32bit systems since totalram is a long (IIRC) and so this will certainly overflow. -- can you be more specific, how could the overflow happen? Both values are 32bit on a 32bit system, so as soon as you have more than 4GB in

[PATCH 1/7] drm/amdgpu: fix indentation in struct amdgpu_ring

2016-07-21 Thread Christian König
From: Christian König Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/amdgpu/amdgpu.h index 459e136..d939038 100644 --- a/drivers/gpu/drm/amd

[PATCH 2/7] drm/amdgpu: remove fence_lock

2016-07-21 Thread Christian König
From: Christian König Was never used as far as I can see. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 1 - 2 files changed, 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gpu/drm/amd/

[PATCH 3/7] drm/amdgpu: add begin/end_use ring callbacks

2016-07-21 Thread Christian König
From: Christian König For manual UVD/VCE power and clock gating. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 3 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 10 ++ 2 files changed, 13 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h

[PATCH 6/7] drm/amdgpu: move UVD IB test into common code v2

2016-07-21 Thread Christian König
From: Christian König Since we now raise the clocks from begin_use() we don't need a separate function for each hw generation any more. v2: remove unintentional lowering of the UVD clocks, fix typos for CIK hw. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 35 ++

[PATCH 4/7] drm/amdgpu: use begin/end_use for UVD power/clock gating

2016-07-21 Thread Christian König
From: Christian König This fixes turning power and clock on when it is actually needed. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 15 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.h | 2 ++ drivers/gpu/drm/amd/amdgpu/uvd_v4_2.c | 2 ++ drivers/gpu

[PATCH 7/7] drm/amdgpu: add a fence timeout for the IB tests v2

2016-07-21 Thread Christian König
From: Christian König 10ms should be enough for now. v2: fix some typos in CIK code Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c | 4 +++- drivers/gpu/drm/amd/amdgpu/amdgpu_uvd.c | 25 +++--

[PATCH 5/7] drm/amdgpu: use begin/end_use for VCE power/clock gating

2016-07-21 Thread Christian König
From: Christian König This fixes turning power and clock on when it is actually needed. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 + drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c | 37 + drivers/gpu/drm/amd/amdgpu/amdgpu_vce.h |

Re: [PATCH 1/7] drm/amdgpu: fix indentation in struct amdgpu_ring

2016-07-21 Thread zhoucm1
On 2016年07月21日 18:01, Christian König wrote: From: Christian König Signed-off-by: Christian König Reviewed-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu.h b/drivers/gp

Re: [PATCH 2/7] drm/amdgpu: remove fence_lock

2016-07-21 Thread zhoucm1
On 2016年07月21日 18:01, Christian König wrote: From: Christian König Was never used as far as I can see. Signed-off-by: Christian König Reviewed-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 1 - drivers/gpu/drm/amd/amdgpu/amdgpu_ring.c | 1 - 2 files changed, 2 dele

Re: [PATCH 7/7] drm/amdgpu: add a fence timeout for the IB tests v2

2016-07-21 Thread zhoucm1
On 2016年07月21日 18:01, Christian König wrote: From: Christian König 10ms should be enough for now. v2: fix some typos in CIK code Signed-off-by: Christian König Reviewed-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c |

Re: [PATCH 1/7] drm/amdgpu: fix indentation in struct amdgpu_ring

2016-07-21 Thread Edward O'Callaghan
This series is, Reviewed-by: Edward O'Callaghan A nice revision of the previous solution btw.. On 07/21/2016 08:01 PM, Christian König wrote: > From: Christian König > > Signed-off-by: Christian König > --- > drivers/gpu/drm/amd/amdgpu/amdgpu.h | 4 ++-- > 1 file changed, 2 insertions(+), 2

[PATCH] drm/ttm: partial revert "cleanup ttm_tt_(unbind|destroy)"

2016-07-21 Thread Christian König
From: Christian König We still need to unbind explicitely during a move. This partial reverts commit ff20caa0bcbfef9f7686f8d1868a3b990921afd6. Signed-off-by: Christian König --- drivers/gpu/drm/ttm/ttm_bo_util.c | 1 + drivers/gpu/drm/ttm/ttm_tt.c | 15 --- include/drm/ttm/t

ATPX changes in drm-next-4.8 and D3cold handling

2016-07-21 Thread Peter Wu
Hi Alex, There are a couple of changes for 4.8 that try to detect whether the "power_cntl" flag is present. Originally attributed to a firmware bug, it seems that the detection is performed too late resulting in flags that are always zero (https://bugzilla.kernel.org/show_bug.cgi?id=115321). What

答复: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Wang, Qingqing
Actually that discussion was held long ago internally but we never got a conclusion on this IIRC. So we should probably continue the discussion on this thread now. -there is a thread for this topic yesterday, some people are not in amd-gfx mail list, we'd better discuss in the internal thread.

Re: 答复: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Christian König
Am 21.07.2016 um 13:15 schrieb Wang, Qingqing: Actually that discussion was held long ago internally but we never got a conclusion on this IIRC. So we should probably continue the discussion on this thread now. -there is a thread for this topic yesterday, some people are not in amd-gfx mail

答复: 答复: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Wang, Qingqing
alright, I didn't realize you're not in that thread. we can add people in if necessary here. so the initial though of this change is with latest big memory GPU released, the remote memory goes very large, like Polaris10. According to the windows WDDM, remote memory size is half of the system me

Re: 答复: 答复: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Christian König
we can add people in if necessary here. so the initial though of this change is with latest big memory GPU released, the remote memory goes very large, like Polaris10. According to the windows WDDM, remote memory size is half of the system memory, I don't know what was discussed before, Please

GFX PG for Stoney/Carrizo and UVD static PG for Carrizo

2016-07-21 Thread Tom St Denis
These patches re-enable GFX PG on Stoney and Carrizo. I've found that AMD_PG_SUPPORT_CP and AMD_PG_SUPPORT_RLC_SMU_HS are both buggy so they are disabled. RLC_SMU_HS results in early system hangs whereas CP powergating results in harder to trigger system hangs. With both disabled I've been able

[PATCH 1/4] Revert "drm/amdgpu: disable GFX PG on CZ/BR/ST"

2016-07-21 Thread Tom St Denis
This partially reverts commit bd0ced160a2a7f1b23058bdca008f7770fd863c3. But keeps the SMU SCLK slowdown and CP PG disabled since that is what is causing the system hangs on Carrizo(AM4) systems. PG is still disabled for ST systems as that hasn't been fully tested yet. Signed-off-by: Tom St Denis

[PATCH 3/4] drm/amd/dpm: Add PG support for UVD on Carrizo

2016-07-21 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/cz_dpm.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/cz_dpm.c b/drivers/gpu/drm/amd/amdgpu/cz_dpm.c index 8ba07e79d4cb..a3e710147a69 100644 --- a/drivers/gpu/drm/amd/amdgpu/cz_dpm.c +++ b/d

[PATCH 4/4] drm/amd/amdgpu: Enable UVD PG on Carrizo

2016-07-21 Thread Tom St Denis
Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/vi.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vi.c b/drivers/gpu/drm/amd/amdgpu/vi.c index 650a89bb3c82..d711a3cf06f1 100644 --- a/drivers/gpu/drm/amd/amdgpu/vi.c +++ b/drivers/gp

[PATCH 2/4] drm/amd/amdgpu: Re-enable PG for GFX on Stoney

2016-07-21 Thread Tom St Denis
With SMU SCLK and CP PG disabled testing passes. Signed-off-by: Tom St Denis --- drivers/gpu/drm/amd/amdgpu/vi.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vi.c b/drivers/gpu/drm/amd/amdgpu/vi.c index e53bec87ec0f..650a89bb3c82 100644 --- a

Re: [PATCH] drm/ttm: partial revert "cleanup ttm_tt_(unbind|destroy)"

2016-07-21 Thread Felix Kuehling
This patch introduces a compile warning: /home/fkuehlin/compute/kernel/drivers/gpu/drm/ttm/ttm_tt.c: In function ‘ttm_tt_destroy’: /home/fkuehlin/compute/kernel/drivers/gpu/drm/ttm/ttm_tt.c:169:6: warning: unused variable ‘ret’ [-Wunused-variable] int ret; ^ Regards, Felix On 16-07-2

Re: 答复: 答复: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Felix Kuehling
TTM limits system memory allocations to 1/2 system memory for regular processes, or 3/4 for privileged processes. For compute we opted to make the GART bigger than system memory to allow for fragmentation. However, we argued that you don't really need GART for most buffers anyways, since they are

Re: [PATCH 1/3] drm/amdgpu: add bypass mode for vce3.0

2016-07-21 Thread Eric Huang
Looks good to me. Reviewed-by: Eric Huang Regards, Eric On 07/18/2016 12:59 PM, Rex Zhu wrote: Change-Id: I68aa5431146b21990a998a777e00139f0478407f Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/amdgpu/vce_v3_0.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/drivers/

Re: [PATCH] drm/ttm: partial revert "cleanup ttm_tt_(unbind|destroy)"

2016-07-21 Thread Edward O'Callaghan
On 07/21/2016 08:34 PM, Christian König wrote: > From: Christian König > > We still need to unbind explicitely during a move. > > This partial reverts commit ff20caa0bcbfef9f7686f8d1868a3b990921afd6. > > Signed-off-by: Christian König > --- > drivers/gpu/drm/ttm/ttm_bo_util.c | 1 + > driv

Re: [PATCH 2/3] drm/amd/powerplay: fix issue can't enable vce dpm.

2016-07-21 Thread Eric Huang
Looks good to me. Reviewed-by: Eric Huang Regards, Eric On 07/18/2016 12:59 PM, Rex Zhu wrote: Change-Id: I4e09b1c1685657c68a1b4a73928bcaf0ac025d7d Signed-off-by: Rex Zhu --- .../powerplay/hwmgr/polaris10_clockpowergating.c | 14 +++-- .../gpu/drm/amd/powerplay/hwmgr/polaris10_hwmgr.

[PATCH 1/2] drm/amdgpu: implement amdgpu_fill_buffer()

2016-07-21 Thread Flora Cui
so that bo could be set to some pattern Change-Id: Iee7b7b28801e4c696b5d217a5d2ffc224dbe0cba Signed-off-by: Flora Cui Reviewed-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu.h | 5 +++ drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 62 +

[PATCH 2/2] drm/amdgpu: expose AMDGPU_GEM_CREATE_VRAM_CLEARED to user space

2016-07-21 Thread Flora Cui
Change-Id: I256178afa18c1a433fe60d8656d1c5cc5d55cf2f Signed-off-by: Flora Cui Reviewed-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 23 +++ include/uapi/drm/amdgpu_drm.h | 2 ++ 2 files changed, 25 insertions(+) diff --git a/drivers/gpu/dr

[PATCH] amdgpu: expose the AMDGPU_GEM_CREATE_VRAM_CLEARED flag

2016-07-21 Thread Flora Cui
With this flag specified, VARM buffer will be cleared at allocation time. Change-Id: Ic587ed7e524a3bfc3862a57b42aa95ff458fe880 Signed-off-by: Flora Cui --- include/drm/amdgpu_drm.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/drm/amdgpu_drm.h b/include/drm/amdgpu_drm.h index fbd

答复: 答复: 答复: 答复: [PATCH] drm/amdgpu: adjust gtt memory size

2016-07-21 Thread Wang, Ken
thanks Felix, I see that logci in TTM as well, so choose 1/2 of system memory as up limit seems good enough here? if no object I will fix the overflow issue and send the review again. 发件人: amd-gfx 代表 Felix Kuehling 发送时间: 2016年7月22日 3:19:38 收件人: amd-gfx@lis

Re: [PATCH] amdgpu: expose the AMDGPU_GEM_CREATE_VRAM_CLEARED flag

2016-07-21 Thread Alexandre Demers
Hi Flora. I suppose this addition preceeds AMDGPU_GEM_CREATE_VRAM_CLEARED's usage that will be introduced in upcoming patches? Could you fix the commit message VARM -> VRAM? With that fixed, you can add my Reviewed-by: Alexandre Demers Alexandre Demers On 2016-07-22 00:02, Flora Cui wrote

Re: [PATCH] amdgpu: expose the AMDGPU_GEM_CREATE_VRAM_CLEARED flag

2016-07-21 Thread Alexandre Demers
Forget my question, I just saw your other patches. ;) Alexandre Demers On 2016-07-22 02:32, Alexandre Demers wrote: Hi Flora. I suppose this addition preceeds AMDGPU_GEM_CREATE_VRAM_CLEARED's usage that will be introduced in upcoming patches? Could you fix the commit message VARM -> VRAM? W