[PATCH v2] drm/amd/display: Improvise error handling for DP sink power states

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Log if we fail to setup sink power states.

Cc: Fangzhi Zuo <Jerry.Zuo@xxxxxxx>
Cc: Aurabindo Pillai <aurabindo.pillai@xxxxxxx>
Signed-off-by: Srinivasan Shanmugam <srinivasan.shanmugam@xxxxxxx>
---

v2:

- Change DC_LOG_HW_LINK_TRAINING to DC_LOG_DC, as link training related
  code moved to drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_training.c (Aurabindo)


 .../gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c b/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c
index c840ef17802e..ba98013fecd0 100644
--- a/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c
+++ b/drivers/gpu/drm/amd/display/dc/link/protocols/link_dp_capability.c
@@ -1043,6 +1043,9 @@ static enum dc_status wake_up_aux_channel(struct dc_link *link)
 				DP_SET_POWER,
 				&dpcd_power_state,
 				sizeof(dpcd_power_state));
+		if (status < 0)
+			DC_LOG_DC("%s: Failed to power up sink: %s\n", __func__,
+				  dpcd_power_state == DP_SET_POWER_D0 ? "D0" : "D3");
 		return DC_ERROR_UNEXPECTED;
 	}
 
-- 
2.25.1




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux