weston: modify display enable api [1/1]
PD#SWPL-185334
Problem:
weston crash when resume from light sleep.
repaint status not correct
Solution:
we need start repaint loop only when repaint is
not scheduled.
Verify:
t5w
Change-Id: I3a13feb11f515ba62ed4fa5b87f266210d9e4c67
Signed-off-by: limin.tian <limin.tian@amlogic.com>
diff --git a/aml-weston/aml-backend.c b/aml-weston/aml-backend.c
index 4c89a83..3fa32ec 100644
--- a/aml-weston/aml-backend.c
+++ b/aml-weston/aml-backend.c
@@ -1106,8 +1106,10 @@
wst_mode, output->base.current_scale);
#endif
if (output->base.start_repaint_loop) {
- output->base.repaint_status = REPAINT_AWAITING_COMPLETION;
- output->base.start_repaint_loop(&output->base);
+ if (output->base.repaint_status == REPAINT_NOT_SCHEDULED) {
+ output->base.repaint_status = REPAINT_AWAITING_COMPLETION;
+ output->base.start_repaint_loop(&output->base);
+ }
}
}
} else if (enable == 0) {