summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorYue Hin Lau <Yuehin.Lau@amd.com>2018-06-27 13:49:20 -0400
committerAlex Deucher <alexander.deucher@amd.com>2018-07-13 14:51:28 -0500
commit6c4fff068f7940993b3ec74a9996f4b514089d1a (patch)
treeefd734e017c54883ec32e4632a52200cdf05f666 /drivers
parentc2c09ed5cd1b7423b2d2bf372e4c62394264324d (diff)
drm/amd/display: Add NULL check for local sink in edp_power_control
[WHY] PNP cause bsod regression fix [HOW] Add NULL check Signed-off-by: Yue Hin Lau <Yuehin.Lau@amd.com> Reviewed-by: Hugo Hu <Hugo.Hu@amd.com> Acked-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c b/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
index 109d4103d10d..e48eb3056af5 100644
--- a/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
+++ b/drivers/gpu/drm/amd/display/dc/dce110/dce110_hw_sequencer.c
@@ -871,9 +871,11 @@ void hwss_edp_power_control(
unsigned long long wait_time_ms = 0;
/* max 500ms from LCDVDD off to on */
- unsigned long long edp_poweroff_time_ms =
- 500 + link->local_sink->edid_caps.panel_patch.extra_t12_ms;
+ unsigned long long edp_poweroff_time_ms = 500;
+ if (link->local_sink != NULL)
+ edp_poweroff_time_ms =
+ 500 + link->local_sink->edid_caps.panel_patch.extra_t12_ms;
if (link->link_trace.time_stamp.edp_poweroff == 0)
wait_time_ms = edp_poweroff_time_ms;
else if (duration_in_ms < edp_poweroff_time_ms)