aboutsummaryrefslogtreecommitdiffstats
path: root/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4677-drm-amd-display-Return-DMUB_STATUS_OK-when-autoload-.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4677-drm-amd-display-Return-DMUB_STATUS_OK-when-autoload-.patch')
-rw-r--r--meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4677-drm-amd-display-Return-DMUB_STATUS_OK-when-autoload-.patch55
1 files changed, 55 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4677-drm-amd-display-Return-DMUB_STATUS_OK-when-autoload-.patch b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4677-drm-amd-display-Return-DMUB_STATUS_OK-when-autoload-.patch
new file mode 100644
index 00000000..236a3b43
--- /dev/null
+++ b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/4677-drm-amd-display-Return-DMUB_STATUS_OK-when-autoload-.patch
@@ -0,0 +1,55 @@
+From c13b68221785174927af4bfa3b0fbd3a16f422d4 Mon Sep 17 00:00:00 2001
+From: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
+Date: Thu, 7 Nov 2019 15:29:20 -0500
+Subject: [PATCH 4677/4736] drm/amd/display: Return DMUB_STATUS_OK when
+ autoload unsupported
+
+[Why]
+Not having support for autoload isn't an error. If the DMUB firmware
+doesn't support it then don't return DMUB_STATUS_INVALID.
+
+[How]
+Return DMUB_STATUS_OK when ->is_auto_load_done is NULL.
+
+Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
+Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
+Acked-by: Leo Li <sunpeng.li@amd.com>
+---
+ drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c b/drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c
+index 3ec26f6af2e1..70c7a4be9ccc 100644
+--- a/drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c
++++ b/drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c
+@@ -379,9 +379,12 @@ enum dmub_status dmub_srv_wait_for_auto_load(struct dmub_srv *dmub,
+ {
+ uint32_t i;
+
+- if (!dmub->hw_init || !dmub->hw_funcs.is_auto_load_done)
++ if (!dmub->hw_init)
+ return DMUB_STATUS_INVALID;
+
++ if (!dmub->hw_funcs.is_auto_load_done)
++ return DMUB_STATUS_OK;
++
+ for (i = 0; i <= timeout_us; i += 100) {
+ if (dmub->hw_funcs.is_auto_load_done(dmub))
+ return DMUB_STATUS_OK;
+@@ -397,9 +400,12 @@ enum dmub_status dmub_srv_wait_for_phy_init(struct dmub_srv *dmub,
+ {
+ uint32_t i = 0;
+
+- if (!dmub->hw_init || !dmub->hw_funcs.is_phy_init)
++ if (!dmub->hw_init)
+ return DMUB_STATUS_INVALID;
+
++ if (!dmub->hw_funcs.is_phy_init)
++ return DMUB_STATUS_OK;
++
+ for (i = 0; i <= timeout_us; i += 10) {
+ if (dmub->hw_funcs.is_phy_init(dmub))
+ return DMUB_STATUS_OK;
+--
+2.17.1
+