From 0686445847dac456e867f96968b2ee29d7cce74a Mon Sep 17 00:00:00 2001 From: Gwendal Grignou Date: Fri, 16 Oct 2015 01:13:58 -0700 Subject: [PATCH] motion: reenable double tap in S5. Double TAP must be enabled in S5, even if it has been disabled by the AP, otherwise we would not be able to check the battery level if the AP did not shutdown properly or does not reenable double tap on shutdown. BRANCH=none BUG=chrome-os-partner:46572 TEST=Check double tap is working after unit has been powered down. Change-Id: Ic798399a3e4ae4d87c6e80eab4cf1fd680f99585 Signed-off-by: Gwendal Grignou Reviewed-on: https://chromium-review.googlesource.com/306697 Reviewed-by: Alec Berg --- common/motion_sense.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/common/motion_sense.c b/common/motion_sense.c index d6b94d0128..3bd2dfcd5c 100644 --- a/common/motion_sense.c +++ b/common/motion_sense.c @@ -420,6 +420,9 @@ static void motion_sense_shutdown(void) int activity = get_next_bit(&enabled); sensor->drv->manage_activity(sensor, activity, 0, NULL); } + /* Renable double tap in case AP disabled it */ + sensor->drv->manage_activity(sensor, + MOTIONSENSE_ACTIVITY_DOUBLE_TAP, 1, NULL); } #endif }