aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/display/dc/inc/core_status.h
diff options
context:
space:
mode:
authorRodrigo Siqueira <Rodrigo.Siqueira@amd.com>2020-05-26 16:53:38 -0400
committerAlex Deucher <alexander.deucher@amd.com>2020-07-01 01:59:20 -0400
commit74a166759d692efe18996076736b61533936892b (patch)
tree76972cb31139b64d23a8a089752f4159d22f808b /drivers/gpu/drm/amd/display/dc/inc/core_status.h
parentdrm/amd/display: add support for per-state dummy-pstate latency (diff)
downloadlinux-dev-74a166759d692efe18996076736b61533936892b.tar.xz
linux-dev-74a166759d692efe18996076736b61533936892b.zip
drm/amd/display: Add helper to convert DC status
During the debugging process related to a hot-plug problem with 4k display, we realized that we had some issues related to the global state validation. This problem was not explicitly highlighted in the dmesg log, for this reason, this commit adds a function that converts `enum dc_status` to a human-readable string and appends the proper warning message in case of failure. Signed-off-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Reviewed-by: Harry Wentland <Harry.Wentland@amd.com> Acked-by: Qingqing Zhuo <qingqing.zhuo@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/inc/core_status.h')
-rw-r--r--drivers/gpu/drm/amd/display/dc/inc/core_status.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/inc/core_status.h b/drivers/gpu/drm/amd/display/dc/inc/core_status.h
index 4ead89dd7c41..f932801235c6 100644
--- a/drivers/gpu/drm/amd/display/dc/inc/core_status.h
+++ b/drivers/gpu/drm/amd/display/dc/inc/core_status.h
@@ -53,4 +53,6 @@ enum dc_status {
DC_ERROR_UNEXPECTED = -1
};
+char *dc_status_to_str(enum dc_status status);
+
#endif /* _CORE_STATUS_H_ */