changeset 447:4b6acb68b851

../drv_app/power: fixed button power-off for ACI vs. MFW builds
author Mychaela Falconia <falcon@freecalypso.org>
date Sun, 28 Jan 2018 21:12:22 +0000
parents bed6d393f3e0
children e56e74e8b730
files src/cs/drivers/drv_app/power/board/power.c
diffstat 1 files changed, 4 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/src/cs/drivers/drv_app/power/board/power.c	Sun Jan 28 19:26:10 2018 +0000
+++ b/src/cs/drivers/drv_app/power/board/power.c	Sun Jan 28 21:12:22 2018 +0000
@@ -72,11 +72,8 @@
      When we build for ACI, we have no MMI, so there's no point waiting 
       for a keypress.  See CR 17958.
    */
-#if (MMI == 0)
-   return;
-#endif
 
-#if (OP_WCP == 0)
+#if (OP_WCP == 0) && (MMI != 0)
 
    /* Wait until the pointers initialization by the SMI */
    while(!(Kp.pressed && Kp.released))
@@ -114,10 +111,12 @@
    rvf_send_trace("Power off button", 16, NULL_PARAM, RV_TRACE_LEVEL_WARNING, LCC_USE_ID);
    SPI_GBL_INFO_PTR->is_gsm_on = FALSE;
 #ifndef _WINDOWS
-  #if (OP_WCP == 0)
+  #if (OP_WCP == 0) && (MMI != 0)
    (Kp.pressed)(KPD_PWR);  /* tell key is pressed */
    rvf_delay(5);
    (Kp.released)();        /* tell key is released */
+  #else
+   ABB_Power_Off();
   #endif
 #endif  // _WINDOWS
 }