lid_switch: Support forced lid open

Factory test process need lid switch no function or keep lid opened

BUG=chrome-os-partner:33304
BRANCH=paine,yuna
TEST=Run command "ectool forcelidopen 1" and "reboot". Then lid close
quickly, the system boot as lid opened.
Deault value  or run command "ectool forcelidopen 0" make the device normal.

Change-Id: I94527b7ef7f9efe779c6b86f3eab651f99af6000
Signed-off-by: Henry Hsu <Henry.Hsu@quantatw.com>
Reviewed-on: https://chromium-review.googlesource.com/230180
Reviewed-by: Mohammed Habibulla <moch@chromium.org>
Reviewed-by: Bowgo Tsai <bowgotsai@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Commit-Queue: Shawn Nematbakhsh <shawnn@chromium.org>
Tested-by: Shawn Nematbakhsh <shawnn@chromium.org>
This commit is contained in:
Henry Hsu
2014-10-01 12:32:12 +08:00
committed by chrome-internal-fetch
parent e96afe490f
commit 89442037be
3 changed files with 56 additions and 1 deletions

View File

@@ -1465,6 +1465,16 @@ struct ec_response_motion_sense {
};
} __packed;
/*****************************************************************************/
/* Force lid open command */
/* Make lid event always open */
#define EC_CMD_FORCE_LID_OPEN 0x2c
struct ec_params_force_lid_open {
uint8_t enabled;
} __packed;
/*****************************************************************************/
/* USB charging control commands */