From 677bdb9df55248da3a0c6be0089098f6d6807d3c Mon Sep 17 00:00:00 2001 From: Gabe Black Date: Thu, 21 Nov 2013 00:49:33 -0800 Subject: [PATCH] nyan: Use the board ID to decide how to initialize the PMIC. Use the board ID to figure out how to initialize the PMIC instead of using a config option. BUG=None TEST=Built and booted on both types of nyan. BRANCH=None Change-Id: I26f735f3c7ba910fd237a1d00d616d3d89b9fbd9 Signed-off-by: Gabe Black Reviewed-on: https://chromium-review.googlesource.com/177489 Reviewed-by: David Hendricks Reviewed-by: Tom Warren Commit-Queue: Gabe Black Tested-by: Gabe Black --- src/mainboard/google/nyan/pmic.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/mainboard/google/nyan/pmic.c b/src/mainboard/google/nyan/pmic.c index 6c6a8fc1d5..857e5ffb57 100644 --- a/src/mainboard/google/nyan/pmic.c +++ b/src/mainboard/google/nyan/pmic.c @@ -23,6 +23,7 @@ #include #include +#include "boardid.h" #include "pmic.h" enum { @@ -44,7 +45,7 @@ void pmic_init(unsigned bus) */ /* First set VDD_CPU to 1.2V, then enable the VDD_CPU regulator. */ - if (CONFIG_NYAN_IN_A_PIXEL) + if (board_id() == 0) pmic_write_reg(bus, 0x00, 0x3c); else pmic_write_reg(bus, 0x00, 0x50);