aboutsummaryrefslogtreecommitdiffstats
path: root/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/1976-drm-amd-display-Disable-ABM-before-destroy-ABM-struc.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/1976-drm-amd-display-Disable-ABM-before-destroy-ABM-struc.patch')
-rw-r--r--meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/1976-drm-amd-display-Disable-ABM-before-destroy-ABM-struc.patch37
1 files changed, 37 insertions, 0 deletions
diff --git a/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/1976-drm-amd-display-Disable-ABM-before-destroy-ABM-struc.patch b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/1976-drm-amd-display-Disable-ABM-before-destroy-ABM-struc.patch
new file mode 100644
index 00000000..e80de0d7
--- /dev/null
+++ b/meta-amd-bsp/recipes-kernel/linux/linux-yocto-4.19.8/1976-drm-amd-display-Disable-ABM-before-destroy-ABM-struc.patch
@@ -0,0 +1,37 @@
+From f7ef3c7eff7bfbf7572393a9c8311811c7e4c0f3 Mon Sep 17 00:00:00 2001
+From: Paul Hsieh <paul.hsieh@amd.com>
+Date: Fri, 3 May 2019 23:50:10 +0800
+Subject: [PATCH 1976/2940] drm/amd/display: Disable ABM before destroy ABM
+ struct
+
+[Why]
+When disable driver, OS will set backlight optimization
+then do stop device. But this flag will cause driver to
+enable ABM when driver disabled.
+
+[How]
+Send ABM disable command before destroy ABM construct
+
+Signed-off-by: Paul Hsieh <paul.hsieh@amd.com>
+Reviewed-by: Anthony Koo <Anthony.Koo@amd.com>
+Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
+---
+ drivers/gpu/drm/amd/display/dc/dce/dce_abm.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_abm.c b/drivers/gpu/drm/amd/display/dc/dce/dce_abm.c
+index da96229db53a..2959c3c9390b 100644
+--- a/drivers/gpu/drm/amd/display/dc/dce/dce_abm.c
++++ b/drivers/gpu/drm/amd/display/dc/dce/dce_abm.c
+@@ -473,6 +473,8 @@ void dce_abm_destroy(struct abm **abm)
+ {
+ struct dce_abm *abm_dce = TO_DCE_ABM(*abm);
+
++ abm_dce->base.funcs->set_abm_immediate_disable(*abm);
++
+ kfree(abm_dce);
+ *abm = NULL;
+ }
+--
+2.17.1
+