[PATCH] drm/amd: Don't fail on backlight = 0

2018-11-06 Thread David Francis
of 1 to hardware. Signed-off-by: David Francis Bugzilla: https://bugs.freedesktop.org/108668 Fixes: 416615ea9578 ("drm/amd/display: set backlight level limit to 1") Cc: suresh.gutt...@amd.com Cc: harry.wentl...@amd.com Cc: samant...@posteo.net --- .../gpu/drm/amd/display/amdgpu_dm/a

[PATCH v3 2/3] drm/amdgpu: Fix a bad unit conversion in vega12 powerplay

2018-11-02 Thread David Francis
The default unit in powerplay is 10kHz To convert from 10kHz to kHz, multiply by 10 Signed-off-by: David Francis --- drivers/gpu/drm/amd/powerplay/hwmgr/vega12_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega12_hwmgr.c b

[PATCH v3 3/3] drm/amdgpu: Change powerplay clock requests to MHz

2018-11-02 Thread David Francis
This will clean up powerplay code, as we are no longer multiplying the clocks by 1000 in DM and then dividing them by 1000 in powerplay Signed-off-by: David Francis --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 6 +++--- drivers/gpu/drm/amd/include/dm_pp_interface.h

[PATCH v3 1/3] drm/amdgpu: Stop dividing watermarks by 1000 in powerplay

2018-11-02 Thread David Francis
Watermarks were being multiplied by 1000 in amdgpu_dm and divided by 1000 in powerplay. Change watermarks to units of MHz to stop doing that. Signed-off-by: David Francis --- .../amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 24 +- .../drm/amd/display/dc/dm_services_types.h| 16

[PATCH v2 3/3] drm/amdgpu: Change powerplay clock requests to mHz

2018-11-01 Thread David Francis
This will clean up powerplay code, as we are no longer multiplying the clocks by 1000 in DM and then dividing them by 1000 in powerplay Signed-off-by: David Francis --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 6 +++--- drivers/gpu/drm/amd/include/dm_pp_interface.h

[PATCH v2 2/3] drm/amdgpu: Fix a bad unit conversion in vega12 powerplay

2018-11-01 Thread David Francis
The default unit in powerplay is 10kHz To convert from 10kHz to kHz, multiply by 10 Signed-off-by: David Francis --- drivers/gpu/drm/amd/powerplay/hwmgr/vega12_hwmgr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega12_hwmgr.c b

[PATCH v2 1/3] drm/amdgpu: Stop dividing watermarks by 1000 in powerplay

2018-11-01 Thread David Francis
Watermarks were being multiplied by 1000 in amdgpu_dm and divided by 1000 in powerplay. Change watermarks to units of mhz to stop doing that. Signed-off-by: David Francis --- .../amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 24 +- .../drm/amd/display/dc/dm_services_types.h| 16

[PATCH 2/2] drm/amdgpu: Change pp clock requests to mHz

2018-10-30 Thread David Francis
We were multiplying clock requests by 1000 in amdgpu_dm and then dividing them by 1000 in powerplay. Also, the vega12 code was dividing by 10 when it should have been multiplying (to convert units of 10kHz to units of kHz). Signed-off-by: David Francis --- drivers/gpu/drm/amd/display/amdgpu_dm

[PATCH 1/2] drm/amdgpu: Stop dividing watermarks by 1000 in powerplay

2018-10-30 Thread David Francis
Watermarks were being multiplied by 1000 in amdgpu_dm and divided by 1000 in powerplay. Change watermarks to units of mhz to stop doing that. Signed-off-by: David Francis --- .../amd/display/amdgpu_dm/amdgpu_dm_pp_smu.c | 24 +- .../drm/amd/display/dc/dm_services_types.h| 16

[PATCH 1/2] drm/amd/display: Add DMCU firmware version

2018-09-13 Thread David Francis
Read the version number from the common firmware header and store it in the dm struct Signed-off-by: David Francis --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 ++ drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/gpu

[PATCH 2/2] drm/amdgpu: Add DMCU to firmware query interface

2018-09-13 Thread David Francis
DMCU firmware version can be read using the AMDGPU_INFO ioctl or the amdgpu_firmware_info debugfs entry Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 12 include/uapi/drm/amdgpu_drm.h | 2 ++ 2 files changed, 14 insertions(+) diff --git

[PATCH 0/2] DMCU firmware version storing and access

2018-09-13 Thread David Francis
David Francis (2): drm/amd/display: Add DMCU firmware version drm/amdgpu: Add DMCU to firmware query interface drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c | 12 drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 2 ++ drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h

[PATCH v2 2/3] drm/amd: Add PSP DMCU support

2018-09-12 Thread David Francis
. Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/psp_v10_0.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c b/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c index 02be34e72ed9..240dc8c85867 100644 --- a/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c +++ b

[PATCH v2 3/3] drm/amd: Add DM DMCU support

2018-09-12 Thread David Francis
is loaded by the kernel's loading mechanism and split into two ucodes according to the header. DMCU is optional, so if the firmware is not found, no error or warning is raised. Signed-off-by: David Francis --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 91 ++- .../gpu/drm/amd

[PATCH v2 1/3] drm/amd: Add ucode DMCU support

2018-09-12 Thread David Francis
and parsing logic similar to MEC, to extract the two ucodes from a single struct firmware. Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 21 +++-- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 10 ++ 2 files changed, 29 insertions(+), 2 deletions

[PATCH v2 0/3] Add DMCU fw loading on raven

2018-09-12 Thread David Francis
v2: measure intv offset in bytes instead of words David Francis (3): drm/amd: Add ucode DMCU support drm/amd: Add PSP DMCU support drm/amd: Add DM DMCU support drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 21 - drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 10 ++ drivers/gpu/drm

[PATCH 3/3] drm/amd: Add DM DMCU support

2018-09-11 Thread David Francis
is loaded by the kernel's loading mechanism and split into two ucodes according to the header. DMCU is optional, so if the firmware is not found, no error or warning is raised. Signed-off-by: David Francis --- .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 91 ++- .../gpu/drm/amd

[PATCH 2/3] drm/amd: Add PSP DMCU support

2018-09-11 Thread David Francis
. Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/psp_v10_0.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c b/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c index 02be34e72ed9..240dc8c85867 100644 --- a/drivers/gpu/drm/amd/amdgpu/psp_v10_0.c +++ b

[PATCH 1/3] drm/amd: Add ucode DMCU support

2018-09-11 Thread David Francis
and parsing logic similar to MEC, to extract the two ucodes from a single struct firmware. Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 21 +++-- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 10 ++ 2 files changed, 29 insertions(+), 2 deletions

[PATCH 0/3] Add DMCU fw loading on raven

2018-09-11 Thread David Francis
David Francis (3): drm/amd: Add ucode DMCU support drm/amd: Add PSP DMCU support drm/amd: Add DM DMCU support drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 21 - drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 10 ++ drivers/gpu/drm/amd/amdgpu/psp_v10_0.c| 6 ++ .../gpu/drm

[PATCH v3] drm/amd: Add DMCU firmware loading on raven

2018-09-11 Thread David Francis
loading into its own function, properly release firmware, add debug messages v3: Use one binary file which contains both firmware pieces Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.c | 21 - drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 10 ++ drivers/gpu/drm

[PATCH v2] drm/amd: Add DMCU firmware loading on raven

2018-09-07 Thread David Francis
loading into its own function, properly release firmware, add debug messages Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 2 + drivers/gpu/drm/amd/amdgpu/psp_v10_0.c| 6 + .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 114 +- 3 files

[PATCH] drm/amd: Add DMCU firmware loading on raven

2018-09-07 Thread David Francis
- the initial eram and the interrupt vectors. These are treated as seperate pieces of firmware and loaded by PSP The loading occurs in the sw_init hook of DM If the firmware is not found, the sw_init hook returns without error. DMCU is not a requirement for DM to run. Signed-off-by: David Francis

[PATCH] drm/amd: Add DMCU firmware loading on raven

2018-09-07 Thread David Francis
- the initial eram and the interrupt vectors. These are treated as seperate pieces of firmware and loaded by PSP The loading occurs in the sw_init hook of DM Signed-off-by: David Francis --- drivers/gpu/drm/amd/amdgpu/amdgpu_ucode.h | 2 + drivers/gpu/drm/amd/amdgpu/psp_v10_0.c| 6

[PATCH] amd/dc/dce100: On dce100, set clocks to 0 on suspend

2018-07-12 Thread David Francis
active pipes. If no, set clocks to 0 Signed-off-by: David Francis --- .../amd/display/dc/dce100/dce100_resource.c | 19 --- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dce100/dce100_resource.c b/drivers/gpu/drm/amd/display/dc/dce100

[PATCH] amd/include: Move register declarations from display to include/asic_reg

2018-05-31 Thread David Francis
A few register addresses were declared in amd/display/dc/dce*/dce*_resource.c. They have been consolidated with the appropriate master list of registers in amd/include/asic_reg/dce/... This will make them accessible to external tools that need direct asic register access Signed-off-by: David

<    1   2