Nami: Disable ALS for Akali

Use OEM ID to update motion_sensor_count to disable ALS for Akali.

BUG=b:78537332
BRANCH=master
TEST=make buildall successfully

Change-Id: I29774c1be4e43218f6aaeb14b3e16637482e1ec4
Signed-off-by: Tino Liu <tino.liu@quanta.corp-partner.google.com>
Reviewed-on: https://chromium-review.googlesource.com/1029397
Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com>
Tested-by: Ryan Zhang <ryan.zhang@quanta.corp-partner.google.com>
Reviewed-by: Ryan Zhang <ryan.zhang@quanta.corp-partner.google.com>
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
This commit is contained in:
Tino Liu
2018-04-26 18:42:27 +08:00
committed by chrome-bot
parent 7fa708389a
commit 8ba6446d97

View File

@@ -664,7 +664,7 @@ DECLARE_HOOK(HOOK_CHIPSET_SUSPEND, board_chipset_suspend, HOOK_PRIO_DEFAULT);
static void board_set_motion_sensor_count(void)
{
/* There are two possible sensor configurations.
* Vayne/Sona/Pantheon are without ALS sensor
* Vayne/Sona/Pantheon/Akali are without ALS sensor
* Nami is with ALS sensor
* Use the oem id to different them.
*/
@@ -672,7 +672,8 @@ static void board_set_motion_sensor_count(void)
if (cbi_get_oem_id(&oem_id) == EC_SUCCESS) {
if (oem_id == PROJECT_VAYNE || oem_id == PROJECT_SONA
|| oem_id == PROJECT_PANTHEON)
|| oem_id == PROJECT_PANTHEON
|| oem_id == PROJECT_AKALI)
motion_sensor_count = ARRAY_SIZE(motion_sensors) - 1;
}
}