[PATCH] drm/amdkfd: Use ARRAY_SIZE macro in kfd_build_sysfs_node_entry

2018-01-18 Thread Gustavo A. R. Silva
Use ARRAY_SIZE instead of dividing sizeof array with sizeof an element. This issue was detected with the help of Coccinelle. Signed-off-by: Gustavo A. R. Silva --- drivers/gpu/drm/amd/amdkfd/kfd_topology.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/a

Re: [PATCH 3/4] drm/gem: adjust per file OOM badness on handling buffers

2018-01-18 Thread Chunming Zhou
On 2018年01月19日 00:47, Andrey Grodzovsky wrote: Large amounts of VRAM are usually not CPU accessible, so they are not mapped into the processes address space. But since the device drivers usually support swapping buffers from VRAM to system memory we can still run into an out of memory situation

[PATCH 02/24] drm/amd/display: Update the register GRPH_SWAP_CNTL if surface pixel format changed.

2018-01-18 Thread Harry Wentland
From: Duke Du Signed-off-by: Duke Du --- drivers/gpu/drm/amd/display/dc/core/dc.c | 3 +++ drivers/gpu/drm/amd/display/dc/dc.h | 1 + drivers/gpu/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 1 + 3 files changed, 5 insertions(+) diff --git a/drivers/gp

RE: [PATCH 2/2] drm/ttm: Don't unreserve swapped BOs that were previously reserved

2018-01-18 Thread He, Roger
good catch! Thanks Roger(Hongbo.He) -Original Message- From: Kuehling, Felix Sent: Friday, January 19, 2018 12:56 AM To: amd-gfx@lists.freedesktop.org; dri-de...@lists.freedesktop.org; Koenig, Christian ; He, Roger Cc: Kuehling, Felix Subject: [PATCH 2/2] drm/ttm: Don't unreserve swap

RE: [RFC] Per file OOM badness

2018-01-18 Thread He, Roger
-Original Message- From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf Of Michal Hocko Sent: Friday, January 19, 2018 1:14 AM To: Grodzovsky, Andrey Cc: linux...@kvack.org; amd-gfx@lists.freedesktop.org; linux-ker...@vger.kernel.org; dri-de...@lists.freedesktop.org;

RE: [RFC] Per file OOM badness

2018-01-18 Thread He, Roger
Basically the idea is right to me. 1. But we need smaller granularity to control the contribution to OOM badness. Because when the TTM buffer resides in VRAM rather than evict to system memory, we should not take this account into badness. But I think it is not easy to implement. 2. If

[PATCH v2 1/1] drm: add kernel doc for exported gem dmabuf_ops

2018-01-18 Thread Samuel Li
Signed-off-by: Samuel Li Reviewed-by: Daniel Vetter --- drivers/gpu/drm/drm_prime.c | 88 + 1 file changed, 88 insertions(+) diff --git a/drivers/gpu/drm/drm_prime.c b/drivers/gpu/drm/drm_prime.c index ca09ce7..e82a976 100644 --- a/drivers/gpu/drm/drm

[PATCH 09/24] drm/amd/display: Add timing generator count to resource pool.

2018-01-18 Thread Harry Wentland
From: Yongqiang Sun Use tg count in resource pool for further reference. Signed-off-by: Yongqiang Sun Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c | 1 + drivers/gpu/drm/amd/display/dc/dce110/dce110_resource.c | 2 +- driver

[PATCH 07/24] drm/amd/display: Demote error print to debug print when ATOM impl missing

2018-01-18 Thread Harry Wentland
I assumed wrongfully that all relevant functions should be implemented. Apparently this isn't the case. Demote the print to debug level for now. Signed-off-by: Harry Wentland Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- .../gpu/drm/amd/display/dc/bios/command_table.c| 22 ++

Re: [PATCH 1/2] drm/ttm: Don't add swapped BOs to swap-LRU list

2018-01-18 Thread Felix Kuehling
On 2018-01-18 01:09 PM, Christian König wrote: > Am 18.01.2018 um 17:56 schrieb Felix Kuehling: >> A BO that's already swapped would be added back to the swap-LRU list >> for example if its validation failed under high memory pressure. This >> could later lead to swapping it out again and leaking p

[PATCH 20/24] drm/amd/display: Fix unused variable compilation error

2018-01-18 Thread Harry Wentland
From: "Leo (Sunpeng) Li" Fix: drivers/gpu/drm/amd/amdgpu/../dal-dev/dc/dce110/dce110_hw_sequencer.c: In function ‘dce110_blank_stream’: drivers/gpu/drm/amd/amdgpu/../dal-dev/dc/dce110/dce110_hw_sequencer.c:1008:31: error: unused variable ‘params’ [-Werror=unused-variable] struct encoder_unblan

[PATCH 13/24] drm/amd/display: revert to hacking bounding box for pipe split

2018-01-18 Thread Harry Wentland
From: Dmytro Laktyushkin Directly editing pipe config outside of formula is error prone and results in higher clocks being used when splitting. For this reason we reverted to using bounding box hacking to split. Since sometimes this erroneusly results in higher dpm being required we unhack the bo

[PATCH 22/24] drm/amd/display: Remove unnecessary register programming

2018-01-18 Thread Harry Wentland
From: Mikita Lipski Remove aux engine register programming,when freeing the engine as it was a temporary workaround. Signed-off-by: Mikita Lipski Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/i2caux/dce110/aux_engine_dce110.c | 4 1 file changed, 4

[PATCH 21/24] drm/amd/display: Add temporary delay on disconnect patch

2018-01-18 Thread Harry Wentland
From: John Barberiz Signed-off-by: John Barberiz Reviewed-by: Jun Lei Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc_link.c | 14 ++ drivers/gpu/drm/amd/display/dc/dc_types.h | 6 ++ 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/driv

[PATCH 24/24] drm/amd/display: Fix warning about misaligned code

2018-01-18 Thread Harry Wentland
Signed-off-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc_link.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/core/dc_link.c b/drivers/gpu/drm/amd/display/dc/core/dc_link.c index 420bc2d859eb..0023754e034b 100644 --- a/driv

[PATCH 19/24] drm/amd/display: eDP sequence BL off first then DP blank.

2018-01-18 Thread Harry Wentland
From: Charlene Liu Signed-off-by: Charlene Liu Reviewed-by: Anthony Koo Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc_link.c | 7 ++- .../gpu/drm/amd/display/dc/dce/dce_link_encoder.c | 3 +++ .../amd/display/dc/dce110/dce110_hw_sequencer.c| 22 ++

[PATCH 05/24] drm/amd/display: Early return on crc get

2018-01-18 Thread Harry Wentland
From: "Leo (Sunpeng) Li" If crc is disabled, early return when getting crc's. That way, we avoid reading extra registers within the pflip high irq. Signed-off-by: Leo (Sunpeng) Li Reviewed-by: Harry Wentland --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 1 + .../gpu/drm/amd/displa

Re: [PATCH 1/2] drm/ttm: Don't add swapped BOs to swap-LRU list

2018-01-18 Thread Deucher, Alexander
From: Kuehling, Felix Sent: Thursday, January 18, 2018 4:12 PM To: Koenig, Christian; amd-gfx@lists.freedesktop.org; dri-de...@lists.freedesktop.org; He, Roger; Deucher, Alexander Subject: Re: [PATCH 1/2] drm/ttm: Don't add swapped BOs to swap-LRU list On 2018-01

[PATCH 14/24] drm/amd/display: dpms off mute az audio endpoint only.

2018-01-18 Thread Harry Wentland
From: Charlene Liu Signed-off-by: Charlene Liu Reviewed-by: Krunoslav Kovac Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dc.h | 1 + drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c | 6 +- drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resour

[PATCH 10/24] drm/amd/display: fix backlight not off at resume from S4

2018-01-18 Thread Harry Wentland
From: Charlene Liu Signed-off-by: Charlene Liu Reviewed-by: Krunoslav Kovac Acked-by: Harry Wentland --- .../amd/display/dc/dce110/dce110_hw_sequencer.c| 33 ++ 1 file changed, 27 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dce110/dce110_

[PATCH 03/24] drm/amd/display: Remove unused param in DML

2018-01-18 Thread Harry Wentland
From: Ken Chalmers Signed-off-by: Ken Chalmers --- drivers/gpu/drm/amd/display/dc/dml/display_mode_structs.h | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dml/display_mode_structs.h b/drivers/gpu/drm/amd/display/dc/dml/display_mode_structs.h index aeebd8bee6

[PATCH 06/24] drm/amd/display: Call update_stream_signal directly from amdgpu_dm

2018-01-18 Thread Harry Wentland
There's no good place in DC to cover all place where stream signal should be updated. update_stream_signal depends on timing which comes from DM. Signed-off-by: Harry Wentland Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 10 +++---

[PATCH 16/24] drm/amd/display: dal 3.1.29

2018-01-18 Thread Harry Wentland
From: Tony Cheng Signed-off-by: Tony Cheng Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h index deccbc2020e2

[PATCH 17/24] drm/amd/display: Force full update on pixel_format_change

2018-01-18 Thread Harry Wentland
From: Krunoslav Kovac Signed-off-by: Krunoslav Kovac Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc.c | 1 + drivers/gpu/drm/amd/display/dc/dc.h | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/

[PATCH 04/24] drm/amd/display: Move output_tf to stream_state/update

2018-01-18 Thread Harry Wentland
From: Yongqiang Sun Signed-off-by: Yongqiang Sun Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dc.h| 1 - drivers/gpu/drm/amd/display/dc/dc_stream.h | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/

[PATCH 00/24] DC Patches Jan 18, 2018

2018-01-18 Thread Harry Wentland
* Don't spam for lacking BIOS cmd table implementation * Couple audio fixes * Couple fixes for driver unload (more to follow) * Bunch of Raven work * Some cleanups Arun Pandey (1): drm/amd/display: Define dpp1_set_cursor_position in header Charlene Liu (4): drm/amd/display: fix backlight

[PATCH 23/24] drm/amd/display: Add temporary delay on disconnect patch

2018-01-18 Thread Harry Wentland
From: John Barberiz - Sequencing bug of not resetting delay on disconnect to default values Signed-off-by: John Barberiz Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc_link.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/am

[PATCH 11/24] drm/amd/display: Define dpp1_set_cursor_position in header

2018-01-18 Thread Harry Wentland
From: Arun Pandey Signed-off-by: Arun Pandey Reviewed-by: Charlene Liu Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dcn10/dcn10_dpp.h | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_dpp.h b/drivers/gpu/drm/amd/display/dc/dcn

[PATCH 18/24] drm/amd/display: Add debug flag for p010_mpo_support

2018-01-18 Thread Harry Wentland
From: Geling Li Signed-off-by: AMD\geling Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dc.h | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/display/dc/dc.h b/drivers/gpu/drm/amd/display/dc/dc.h index c889e7b2b370..865b05d325ad 10

[PATCH 08/24] drm/amd/display: Synchronize update plane addr for freesync

2018-01-18 Thread Harry Wentland
From: SivapiriyanKumarasamy Lock top_pipe when doing update plane addr for split pipe freesync case Signed-off-by: SivapiriyanKumarasamy Reviewed-by: Tony Cheng Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/core/dc.c | 47 +--- 1 file changed, 31 ins

[PATCH 15/24] drm/amd/display: Fix deadlock when flushing irq

2018-01-18 Thread Harry Wentland
From: Mikita Lipski Lock irq table when reading a work in queue, unlock to flush the work, lock again till all tasks are cleared Signed-off-by: Mikita Lipski Reviewed-by: Harry Wentland --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_irq.c | 5 +++-- 1 file changed, 3 insertions(+), 2 del

[PATCH 12/24] drm/amd/display: disable az_clock_gating for endpoint register access only

2018-01-18 Thread Harry Wentland
From: Charlene Liu Signed-off-by: Charlene Liu Reviewed-by: Krunoslav Kovac Acked-by: Harry Wentland --- drivers/gpu/drm/amd/display/dc/dce/dce_audio.c | 18 +- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_audio.c b/driv

Re: [RFC] Per file OOM badness

2018-01-18 Thread Michal Hocko
On Thu 18-01-18 18:00:06, Michal Hocko wrote: > On Thu 18-01-18 11:47:48, Andrey Grodzovsky wrote: > > Hi, this series is a revised version of an RFC sent by Christian König > > a few years ago. The original RFC can be found at > > https://lists.freedesktop.org/archives/dri-devel/2015-September/08

Re: [RFC] Per file OOM badness

2018-01-18 Thread Eric Anholt
Michal Hocko writes: > On Thu 18-01-18 18:00:06, Michal Hocko wrote: >> On Thu 18-01-18 11:47:48, Andrey Grodzovsky wrote: >> > Hi, this series is a revised version of an RFC sent by Christian König >> > a few years ago. The original RFC can be found at >> > https://lists.freedesktop.org/archive

Re: [PATCH] drm/amdgpu: quick fix since gmc rename

2018-01-18 Thread Christian König
Am 18.01.2018 um 08:13 schrieb Chunming Zhou: Change-Id: Ie6a4a4219d92ac1ad28a7c341cb7d73930f9386d Signed-off-by: Chunming Zhou Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/a

Re: [PATCH 1/2] drm/ttm: Don't add swapped BOs to swap-LRU list

2018-01-18 Thread Christian König
Am 18.01.2018 um 17:56 schrieb Felix Kuehling: A BO that's already swapped would be added back to the swap-LRU list for example if its validation failed under high memory pressure. This could later lead to swapping it out again and leaking previous swap storage. This commit adds a condition to p

Re: [RFC] Per file OOM badness

2018-01-18 Thread Michal Hocko
On Thu 18-01-18 11:47:48, Andrey Grodzovsky wrote: > Hi, this series is a revised version of an RFC sent by Christian König > a few years ago. The original RFC can be found at > https://lists.freedesktop.org/archives/dri-devel/2015-September/089778.html > > This is the same idea and I've just adr

[PATCH 2/2] drm/ttm: Don't unreserve swapped BOs that were previously reserved

2018-01-18 Thread Felix Kuehling
If ttm_bo_swapout doesn't own the lock, don't release it. Someone else probably depends on it still being locked. Signed-off-by: Felix Kuehling --- drivers/gpu/drm/ttm/ttm_bo.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/

[PATCH 1/2] drm/ttm: Don't add swapped BOs to swap-LRU list

2018-01-18 Thread Felix Kuehling
A BO that's already swapped would be added back to the swap-LRU list for example if its validation failed under high memory pressure. This could later lead to swapping it out again and leaking previous swap storage. This commit adds a condition to prevent that from happening. v2: Check page_flags

[PATCH 1/4] fs: add OOM badness callback in file_operatrations struct.

2018-01-18 Thread Andrey Grodzovsky
This allows device drivers to specify an additional badness for the OOM when they allocate memory on behalf of userspace. Signed-off-by: Andrey Grodzovsky --- include/linux/fs.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/linux/fs.h b/include/linux/fs.h index 511fbaa..938394a 100

[PATCH 3/4] drm/gem: adjust per file OOM badness on handling buffers

2018-01-18 Thread Andrey Grodzovsky
Large amounts of VRAM are usually not CPU accessible, so they are not mapped into the processes address space. But since the device drivers usually support swapping buffers from VRAM to system memory we can still run into an out of memory situation when userspace starts to allocate to much. This p

[PATCH 4/4] drm/amdgpu: Use drm_oom_badness for amdgpu.

2018-01-18 Thread Andrey Grodzovsky
Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c index 46a0c93..6a733cdc8 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c +++ b/d

[PATCH 2/4] oom: take per file badness into account

2018-01-18 Thread Andrey Grodzovsky
Try to make better decisions which process to kill based on per file OOM badness Signed-off-by: Andrey Grodzovsky --- mm/oom_kill.c | 23 +++ 1 file changed, 23 insertions(+) diff --git a/mm/oom_kill.c b/mm/oom_kill.c index 29f8555..825ed52 100644 --- a/mm/oom_kill.c +++ b/m

[RFC] Per file OOM badness

2018-01-18 Thread Andrey Grodzovsky
Hi, this series is a revised version of an RFC sent by Christian König a few years ago. The original RFC can be found at https://lists.freedesktop.org/archives/dri-devel/2015-September/089778.html This is the same idea and I've just adressed his concern from the original RFC and switched to a ca

Re: [PATCH 4/5] drm/amd/pp: Update smu7 dpm table with OD clock/voltage

2018-01-18 Thread Alex Deucher
On Thu, Jan 18, 2018 at 3:38 AM, Rex Zhu wrote: > delete old OD type code path when populate clk. > > Change-Id: I9beb7e751ac720edb4ffb1deaf7984e86e2e41b1 > Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher > --- > drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 110 > ---

Re: [PATCH 2/5] drm/amd/pp: Add edit/commit/show OD clock/voltage support in sysfs

2018-01-18 Thread Alex Deucher
On Thu, Jan 18, 2018 at 3:37 AM, Rex Zhu wrote: > when cat pp_od_clk_voltage it show > OD_SCLK: > 0:300Mhz800 mV > 1:466Mhz818 mV > 2:751Mhz824 mV > 3: 1019Mhz987 mV > 4: 1074Mhz 1037 mV > 5: 1126Mhz 1087 mV > 6:

Re: [PATCH 1/5] drm/amd/pp: Add hwmgr interface for edit dpm table

2018-01-18 Thread Alex Deucher
On Thu, Jan 18, 2018 at 3:37 AM, Rex Zhu wrote: > Add odn_edit_dpm_table function > points for setting user assigned clock/voltage. > > Change-Id: I7e49ffdc30b77d07b46bf12ebb275fa0ff901588 > Signed-off-by: Rex Zhu Reviewed-by: Alex Deucher > --- > drivers/gpu/drm/amd/include/kgd_pp_interface.

Re: [PATCH 5/5] drm/amd/pp: Add update_avfs call when set_power_state

2018-01-18 Thread Alex Deucher
On Thu, Jan 18, 2018 at 3:38 AM, Rex Zhu wrote: > when Overdrive voltage, need to disable AVFS. > when OverDriv engine clock, need to recalculate > AVFS voltage by disable/enable avfs feature. > > Change-Id: Iac82ed92a8484c04c18339968f3d215b063ac050 > Signed-off-by: Rex Zhu > --- > drivers/gpu/d

Re: [PATCH 3/5] drm/amd/pp: Implement edit_dpm_table on smu7

2018-01-18 Thread Alex Deucher
On Thu, Jan 18, 2018 at 3:38 AM, Rex Zhu wrote: > Change-Id: Ib7414e1afc49d7b313188349b396aeac3a5054b7 > Signed-off-by: Rex Zhu > --- > drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 121 > ++- > 1 file changed, 120 insertions(+), 1 deletion(-) > > diff --git a/drivers/g

[PATCH 1/3] drm/amd/amdgpu: Move UVD TRAP after amdgpu_uvd_sw_init

2018-01-18 Thread James Zhu
Signed-off-by: James Zhu --- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c b/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c index c6e22ef..612455d 100644 --- a/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c +

[PATCH 3/3] drm/amd/amdgpu: Add Polaris version check

2018-01-18 Thread James Zhu
Add Polaris version check if firmware support UVD encode Signed-off-by: James Zhu --- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 21 + 1 file changed, 21 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c b/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c index 319d4b3..e72

[PATCH 2/3] drm/amd/amdgpu: Replace uvd_v6_0_enc_support with uvd.num_enc_rings after uvd_v6_0_early_init

2018-01-18 Thread James Zhu
Signed-off-by: James Zhu --- drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c | 55 +++ 1 file changed, 23 insertions(+), 32 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c b/drivers/gpu/drm/amd/amdgpu/uvd_v6_0.c index 612455d..319d4b3 100644 --- a/drivers/g

Re: [PATCH] drm/amdgpu: disable MMHUB power gating on raven

2018-01-18 Thread Deucher, Alexander
Acked-by: Alex Deucher From: amd-gfx on behalf of Huang Rui Sent: Thursday, January 18, 2018 7:26:11 AM To: Deucher, Alexander; amd-gfx@lists.freedesktop.org Cc: Huang, Ray Subject: [PATCH] drm/amdgpu: disable MMHUB power gating on raven MMHUB power gating sti

Re: [PATCH 2/2] drm/amdgpu: Bump driver version for sensor pstate clk

2018-01-18 Thread Deucher, Alexander
Series is: Reviewed-by: Alex Deucher From: amd-gfx on behalf of Rex Zhu Sent: Wednesday, January 17, 2018 10:12:03 PM To: amd-gfx@lists.freedesktop.org Cc: Zhu, Rex Subject: [PATCH 2/2] drm/amdgpu: Bump driver version for sensor pstate clk Change-Id: I7fc6e49

amd powerplay firmware load oops.

2018-01-18 Thread José Pekkarinen
Good morning amd-gfx, I'd like to share the following oops that doesn't seem to be straight forward, to learn and identify what is the final issue in the background. The ouput is the following: Jan 16 06:35:30 bee kernel: [ 27.534407] amdgpu: [powerplay] smu not running, uplo

[PATCH] drm: amd: Fix trailing semicolons

2018-01-18 Thread Luis de Bethencourt
The trailing semicolon is an empty statement that does no operation. Removing the two instances of them since they don't do anything. Signed-off-by: Luis de Bethencourt --- Hi, After fixing the same thing in drivers/staging/rtl8723bs/, Joe Perches suggested I fix it treewide [0]. Best regards

[PATCH] drm/amdgpu: disable MMHUB power gating on raven

2018-01-18 Thread Huang Rui
MMHUB power gating still has issue, and doesn't work on raven at current. So disable it for the moment. Signed-off-by: Huang Rui Acked-by: Hawking Zhang --- drivers/gpu/drm/amd/amdgpu/soc15.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/soc1

Re: Why the vram always with WC flag even if the architecture don't support WC memory

2018-01-18 Thread Lvzhihong (ReJohn)
> I think it's fine. Platforms without write-combining should fall back to > normal uncacheable mappings. This is fine for VRAM, because it can't be > cacheable. But for GTT, we want to use cacheable mappings if write- > combining isn't available, because uncacheable mappings would be much slower

Re: Why the vram always with WC flag even if the architecture don't support WC memory

2018-01-18 Thread Michel Dänzer
On 2018-01-18 12:08 PM, Lvzhihong (ReJohn) wrote: > Hi All, > > I have a logical question when create buffer object in the amdgpu > kernel driver code. My ARM64 architecture don't support WC memory , but > in the driver , the VRAM BO still set WC flags. > > At file: drivers/gpu/drm/amd/amdgp

Why the vram always with WC flag even if the architecture don't support WC memory

2018-01-18 Thread Lvzhihong (ReJohn)
Hi All, I have a logical question when create buffer object in the amdgpu kernel driver code. My ARM64 architecture don't support WC memory , but in the driver , the VRAM BO still set WC flags. At file: drivers/gpu/drm/amd/amdgpu/amdgpu_object.c In function amdgpu_bo_do_create , it determine

x11vnc display output problem while the physical monitor display is normal.

2018-01-18 Thread Lvzhihong (ReJohn)
Hi, I use x11vnc for remote control, the environment is an arm server with AMDGPU which enabled by open source driver. we start x server by : startx , and start x11vnc by : export DISPLAY=:0 & x11vnc. From the beginning, the x11vnc output and the physical monitor output is the same and

[PATCH 1/5] drm/amd/pp: Add hwmgr interface for edit dpm table

2018-01-18 Thread Rex Zhu
Add odn_edit_dpm_table function points for setting user assigned clock/voltage. Change-Id: I7e49ffdc30b77d07b46bf12ebb275fa0ff901588 Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/include/kgd_pp_interface.h | 6 ++ drivers/gpu/drm/amd/powerplay/inc/hwmgr.h | 3 +++ 2 files changed, 9 in

[PATCH 3/5] drm/amd/pp: Implement edit_dpm_table on smu7

2018-01-18 Thread Rex Zhu
Change-Id: Ib7414e1afc49d7b313188349b396aeac3a5054b7 Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 121 ++- 1 file changed, 120 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c b/drivers/gpu/drm/amd/po

[PATCH 2/5] drm/amd/pp: Add edit/commit/show OD clock/voltage support in sysfs

2018-01-18 Thread Rex Zhu
when cat pp_od_clk_voltage it show OD_SCLK: 0:300Mhz800 mV 1:466Mhz818 mV 2:751Mhz824 mV 3: 1019Mhz987 mV 4: 1074Mhz 1037 mV 5: 1126Mhz 1087 mV 6: 1169Mhz 1137 mV 7: 1206Mhz 1150 mV OD_MCLK

[PATCH 0/5] Add sysfs to support OverDrive feature

2018-01-18 Thread Rex Zhu
OD feature is disabled by default. can be enabled by module parameter ppfeaturemask=0x7fff (ppfeaturemask default value is 0x3fff) Add new sysfs pp_od_clk_voltage. cat pp_od_clk_voltage output as OD_SCLK: 0:300Mhz800 mV 1:466Mhz818 mV 2:751Mhz824 m

Re: [PATCH 14/21] drm/amdgpu: add new amdgpu_gmc_emit_flush_gpu_tlb callback

2018-01-18 Thread Christian König
Am 18.01.2018 um 08:08 schrieb Chunming Zhou: On 2018年01月17日 20:19, Christian König wrote: Am 17.01.2018 um 07:24 schrieb Chunming Zhou: I'm not sure if this is a good ongoing, as I know, our per IP topology is intended for every generation asic bringup. Actually the intention goes beyond t

[PATCH 5/5] drm/amd/pp: Add update_avfs call when set_power_state

2018-01-18 Thread Rex Zhu
when Overdrive voltage, need to disable AVFS. when OverDriv engine clock, need to recalculate AVFS voltage by disable/enable avfs feature. Change-Id: Iac82ed92a8484c04c18339968f3d215b063ac050 Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 86 ---

[PATCH 4/5] drm/amd/pp: Update smu7 dpm table with OD clock/voltage

2018-01-18 Thread Rex Zhu
delete old OD type code path when populate clk. Change-Id: I9beb7e751ac720edb4ffb1deaf7984e86e2e41b1 Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c | 110 - drivers/gpu/drm/amd/powerplay/smumgr/fiji_smumgr.c | 18 +++- .../drm/amd/powerplay/smu

Re: [PATCH] drm/ttm: Don't add swapped BOs to swap-LRU list

2018-01-18 Thread Christian König
Am 18.01.2018 um 06:16 schrieb Felix Kuehling: A BO that's already swapped would be added back to the swap-LRU list for example if it validation failed under high memory pressure. This could later lead to swapping it out again and leaking previous swap storage. This commit adds a condition to pr

[PATCH] quick fix since gmc rename

2018-01-18 Thread Chunming Zhou
Change-Id: Ie6a4a4219d92ac1ad28a7c341cb7d73930f9386d Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c index 591df869b52b..14

RE: [PATCH v3] drm/amdgpu: reserved requested gtt buffer for smu

2018-01-18 Thread Quan, Evan
Reviewed-by: Evan Quan Regards, Evan >-Original Message- >From: amd-gfx [mailto:amd-gfx-boun...@lists.freedesktop.org] On Behalf Of Rex >Zhu >Sent: Wednesday, January 17, 2018 1:56 PM >To: amd-gfx@lists.freedesktop.org >Cc: Zhu, Rex >Subject: [PATCH v3] drm/amdgpu: reserved requ

[PATCH] drm/amdgpu: quick fix since gmc rename

2018-01-18 Thread Chunming Zhou
Change-Id: Ie6a4a4219d92ac1ad28a7c341cb7d73930f9386d Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c index 591df869b52b..14

RE: [PATCH] drm/amdgpu: disable ECC check for Raven to avoid error message annoyance

2018-01-18 Thread Zhang, Jerry
Thanks Alex, That's fine for me. Reviewed-by: Junwei Zhang Regards, Jerry (Junwei Zhang) Linux Base Graphics SRDC Software Development _ From: Deucher, Alexander Sent: Wednesday, January 17, 2018 22:12 To: Zhang, Jerry; amd-gfx@lists.freedesktop.org Subject:

[PATCH] drm/amdgpu: quick fix since gmc rename

2018-01-18 Thread Chunming Zhou
Change-Id: Ie6a4a4219d92ac1ad28a7c341cb7d73930f9386d Signed-off-by: Chunming Zhou --- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c index 591df869b52b..14

Re: [PATCH libdrm] amdgpu: Copy .editorconfig to tests/amdgpu

2018-01-18 Thread Michel Dänzer
On 2018-01-17 05:18 PM, Christian König wrote: > Am 17.01.2018 um 17:06 schrieb Michel Dänzer: >> From: Michel Dänzer >> >> In order to use consistent editorconfig settings in both amdgpu >> directories. >> >> Signed-off-by: Michel Dänzer > > Maybe use a symlink instead of a copy? Just in case w

Re: [PATCH] drm/amd/powerplay: Fix smu_table_entry.handle type

2018-01-18 Thread Deucher, Alexander
Reviewed-by: Alex Deucher From: Andrey Grodzovsky Sent: Wednesday, January 17, 2018 5:35 PM To: amd-gfx@lists.freedesktop.org Cc: Lipski, Mikita; Zhu, Rex; Deucher, Alexander; Grodzovsky, Andrey Subject: [PATCH] drm/amd/powerplay: Fix smu_table_entry.handle type

[PATCH 2/2] drm/amdgpu: Bump driver version for sensor pstate clk

2018-01-18 Thread Rex Zhu
Change-Id: I7fc6e49fc2c37502e66903331f64c7418c1684dd Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_drv.c index 46a0c93..24bc3e9 1

Re: TTM leaking swap space?

2018-01-18 Thread Felix Kuehling
I find that ttm_bo_swapout tries to swap the first BO from the swap LRU list. But I don't find what removes a BO from that list. It looks like the same BO can be swapped again, even when it's already swapped. What am I missing? Should swapped out BOs still be on the swap LRU list? In that case we

[PATCH] drm/ttm: Don't add swapped BOs to swap-LRU list

2018-01-18 Thread Felix Kuehling
A BO that's already swapped would be added back to the swap-LRU list for example if it validation failed under high memory pressure. This could later lead to swapping it out again and leaking previous swap storage. This commit adds a condition to prevent that from happening. Signed-off-by: Felix

Re: [PATCH 14/21] drm/amdgpu: add new amdgpu_gmc_emit_flush_gpu_tlb callback

2018-01-18 Thread Chunming Zhou
On 2018年01月17日 20:19, Christian König wrote: Am 17.01.2018 um 07:24 schrieb Chunming Zhou: I'm not sure if this is a good ongoing, as I know, our per IP topology is intended for every generation asic bringup. Actually the intention goes beyond that, e.g. we want to reuse IPs for newer ASICs

[PATCH 1/2] drm/amdgpu: Expose more GPU sensor queries

2018-01-18 Thread Rex Zhu
Add sub-queries for stable pstate shader/memory clock. Change-Id: I2e524ec28dff1e679bee93718d8ceb468f7f6d22 Reviewed-by: Alex Deucher Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 18 ++ include/uapi/drm/amdgpu_drm.h | 4 2 files changed, 2

RE: [PATCH] drm/amd/powerplay: Fix smu_table_entry.handle type

2018-01-18 Thread Zhu, Rex
Reviewed-by: Rex Zhu Best Regards Rex From: Deucher, Alexander Sent: Thursday, January 18, 2018 7:11 AM To: Grodzovsky, Andrey; amd-gfx@lists.freedesktop.org Cc: Lipski, Mikita; Zhu, Rex Subject: Re: [PATCH] drm/amd/powerplay: Fix smu_table_entry.handle type Reviewed-by: Alex Deucher mailto:al

Re: TTM leaking swap space?

2018-01-18 Thread Felix Kuehling
On 2018-01-17 03:33 PM, Andrey Grodzovsky wrote: > I have a private libdrm amdgpu test which allocates very big BOs in > loop until all VRAM, GTT and swap are full, and I don't release them > in the test (yet) . > > Once the test process terminates everything always gets cleared > including swap .

Re: TTM leaking swap space?

2018-01-18 Thread Andrey Grodzovsky
I have a private libdrm amdgpu test which allocates very big BOs in loop until all VRAM, GTT and swap are full, and I don't release them in the test (yet) . Once the test process terminates everything always gets cleared including swap . Could this point to KFD specific issue ? Thanks, Andr

[PATCH] drm/amd/powerplay: Fix smu_table_entry.handle type

2018-01-18 Thread Andrey Grodzovsky
Handle describes kernel logical address, should be unsigned long and not uint32_t. Fixes KASAN error and GFP on driver unload. Signed-off-by: Andrey Grodzovsky --- drivers/gpu/drm/amd/powerplay/smumgr/rv_smumgr.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/dr

Re: [PATCH 1/1] drm: add kernel doc for exported gem dmabuf_ops

2018-01-18 Thread Daniel Vetter
On Wed, Jan 17, 2018 at 11:47:40AM -0500, Samuel Li wrote: > Signed-off-by: Samuel Li Thanks a lot for updating the docs. > --- > drivers/gpu/drm/drm_prime.c | 81 > + > 1 file changed, 81 insertions(+) > > diff --git a/drivers/gpu/drm/drm_prime.c b

[PATCH] drm/amdgpu: fix build error in gmc_v9_0.c.

2018-01-18 Thread Rex Zhu
error: ‘struct amdgpu_device’ has no member named ‘mc’ adev->mc.aper_size = adev->mc.real_vram_size; Change-Id: I6ae5b6fb86c361500242d25c364223cf9e1cb004 Signed-off-by: Rex Zhu --- drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drive