diff options
author | Martin Tsai | 2018-12-13 05:25:19 +0100 |
---|---|---|
committer | Alex Deucher | 2019-01-14 21:39:22 +0100 |
commit | ffb6c1c6c5a12a623205c0d984851ed10dabb75f (patch) | |
tree | 7c0c493237f93e7e0536bd7839263251df0ea891 /drivers/gpu/drm/amd/display/modules | |
parent | drm/amd/display: fix PME notification not working in RV desktop (diff) | |
download | kernel-qcow2-linux-ffb6c1c6c5a12a623205c0d984851ed10dabb75f.tar.gz kernel-qcow2-linux-ffb6c1c6c5a12a623205c0d984851ed10dabb75f.tar.xz kernel-qcow2-linux-ffb6c1c6c5a12a623205c0d984851ed10dabb75f.zip |
drm/amd/display: Redefine DMCU_SCRATCH to identify DMCU state
[why]
To resume system before entering S0i3 completely will cause PSP not
reload DMCU FW since there is not HW power state change.
In this case, driver cannot get correct DMCU version from IRAM
since driver override it and DMCU didn't reload to update it.
It makes driver return false in dcn10_dmcu_init().
[how]
1.To redefine DMCU_SCRATCH to identify different DMCU state.
2.To reserve IRAM 0xF0~0xFF write by DMCU only.
3.To remove dcn10_get_dmcu_state
Signed-off-by: Martin Tsai <martin.tsai@amd.com>
Reviewed-by: Anthony Koo <Anthony.Koo@amd.com>
Acked-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/modules')
-rw-r--r-- | drivers/gpu/drm/amd/display/modules/power/power_helpers.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/modules/power/power_helpers.c b/drivers/gpu/drm/amd/display/modules/power/power_helpers.c index c11a443dcbc8..89b082b5d107 100644 --- a/drivers/gpu/drm/amd/display/modules/power/power_helpers.c +++ b/drivers/gpu/drm/amd/display/modules/power/power_helpers.c @@ -56,6 +56,7 @@ static const unsigned char abm_config[abm_defines_max_config][abm_defines_max_le #define NUM_AGGR_LEVEL 4 #define NUM_POWER_FN_SEGS 8 #define NUM_BL_CURVE_SEGS 16 +#define IRAM_RESERVE_AREA_START 0xF0 // reserve 0xF0~0xFF are write by DMCU only #pragma pack(push, 1) /* NOTE: iRAM is 256B in size */ @@ -324,5 +325,5 @@ bool dmcu_load_iram(struct dmcu *dmcu, params, &ram_table); return dmcu->funcs->load_iram( - dmcu, 0, (char *)(&ram_table), sizeof(ram_table)); + dmcu, 0, (char *)(&ram_table), IRAM_RESERVE_AREA_START); } |