summaryrefslogtreecommitdiff
path: root/src/mainboard
diff options
context:
space:
mode:
authorJulius Werner <jwerner@chromium.org>2014-11-06 12:51:24 -0800
committerPatrick Georgi <pgeorgi@google.com>2015-04-10 20:49:46 +0200
commit0353c9f640086d543762a12797ba51987bfd6fc5 (patch)
tree76586f0afa6fc0f44a46b08baf10c697e9929381 /src/mainboard
parentf3d5736c8f079321af3cc8dc7210dc0b1a05a327 (diff)
downloadcoreboot-0353c9f640086d543762a12797ba51987bfd6fc5.tar.xz
veyron_jerry: Remove board ID based assumptions
The veyron_jerry board code was just copied over from veyron_pinky 1-to-1. The Jerry board IDs start at 1, but there has never been a Jerry rev0 so we can remove the code for board ID 0 from it. BRANCH=none BUG=None TEST=Booted Jerry image on a Pinky rev2, worked fine. Change-Id: I0f2ffdc577934c1695e8d2dcf71512696ac1d5a5 Signed-off-by: Patrick Georgi <pgeorgi@chromium.org> Original-Commit-Id: aa36da69ac584b845e15282dae100eec27fc7f12 Original-Change-Id: I45a18b288c8d8b1399ceedf582addcce1c7e857d Original-Signed-off-by: Julius Werner <jwerner@chromium.org> Original-Reviewed-on: https://chromium-review.googlesource.com/228254 Original-Reviewed-by: David Hendricks <dhendrix@chromium.org> Reviewed-on: http://review.coreboot.org/9546 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'src/mainboard')
-rw-r--r--src/mainboard/google/veyron_jerry/board.h2
-rw-r--r--src/mainboard/google/veyron_jerry/chromeos.c4
-rw-r--r--src/mainboard/google/veyron_jerry/mainboard.c44
3 files changed, 8 insertions, 42 deletions
diff --git a/src/mainboard/google/veyron_jerry/board.h b/src/mainboard/google/veyron_jerry/board.h
index 6162b030c6..2b1643d4bd 100644
--- a/src/mainboard/google/veyron_jerry/board.h
+++ b/src/mainboard/google/veyron_jerry/board.h
@@ -25,7 +25,7 @@
#define PMIC_BUS 0
-#define GPIO_RESET (board_id() > 0 ? GPIO(0, B, 5) : GPIO(0, B, 2))
+#define GPIO_RESET GPIO(0, B, 5)
/* TODO: move setup_chromeos_gpios() here once bootblock code is in mainboard */
diff --git a/src/mainboard/google/veyron_jerry/chromeos.c b/src/mainboard/google/veyron_jerry/chromeos.c
index dc224a5a2f..68f72a0e03 100644
--- a/src/mainboard/google/veyron_jerry/chromeos.c
+++ b/src/mainboard/google/veyron_jerry/chromeos.c
@@ -25,10 +25,8 @@
#include <string.h>
#include <vendorcode/google/chromeos/chromeos.h>
-#include "board.h"
-
#define GPIO_WP GPIO(7, A, 6)
-#define GPIO_LID (board_id() > 0 ? GPIO(0, A, 6) : GPIO(7, B, 5))
+#define GPIO_LID GPIO(0, A, 6)
#define GPIO_POWER GPIO(0, A, 5)
#define GPIO_RECOVERY GPIO(0, B, 1)
diff --git a/src/mainboard/google/veyron_jerry/mainboard.c b/src/mainboard/google/veyron_jerry/mainboard.c
index 0166796b9e..b641fad2ee 100644
--- a/src/mainboard/google/veyron_jerry/mainboard.c
+++ b/src/mainboard/google/veyron_jerry/mainboard.c
@@ -42,14 +42,6 @@ static void configure_usb(void)
{
gpio_output(GPIO(0, B, 3), 1); /* HOST1_PWR_EN */
gpio_output(GPIO(0, B, 4), 1); /* USBOTG_PWREN_H */
-
- switch (board_id()) {
- case 0:
- gpio_output(GPIO(7, B, 3), 1); /* 5V_DRV */
- break;
- default:
- break; /* 5V_DRV moved to EC after rev1 */
- }
}
static void configure_sdmmc(void)
@@ -59,16 +51,8 @@ static void configure_sdmmc(void)
/* use sdmmc0 io, disable JTAG function */
writel(RK_CLRBITS(1 << 12), &rk3288_grf->soc_con0);
- switch (board_id()) {
- case 0:
- rk808_configure_ldo(PMIC_BUS, 8, 3300); /* VCCIO_SD */
- gpio_output(GPIO(7, C, 5), 1); /* SD_EN */
- break;
- default:
- rk808_configure_ldo(PMIC_BUS, 4, 3300); /* VCCIO_SD */
- rk808_configure_ldo(PMIC_BUS, 5, 3300); /* VCC33_SD */
- break;
- }
+ rk808_configure_ldo(PMIC_BUS, 4, 3300); /* VCCIO_SD */
+ rk808_configure_ldo(PMIC_BUS, 5, 3300); /* VCC33_SD */
gpio_input(GPIO(7, A, 5)); /* SD_DET */
}
@@ -95,14 +79,7 @@ static void configure_codec(void)
writel(IOMUX_I2S, &rk3288_grf->iomux_i2s);
writel(IOMUX_I2SCLK, &rk3288_grf->iomux_i2sclk);
- switch (board_id()) {
- case 0:
- rk808_configure_ldo(PMIC_BUS, 5, 1800); /* VCC18_CODEC */
- break;
- default:
- rk808_configure_ldo(PMIC_BUS, 6, 1800); /* VCC18_CODEC */
- break;
- }
+ rk808_configure_ldo(PMIC_BUS, 6, 1800); /* VCC18_CODEC */
/* AUDIO IO domain 1.8V voltage selection */
writel(RK_SETBITS(1 << 6), &rk3288_grf->io_vsel);
@@ -113,18 +90,9 @@ static void configure_lcd(void)
{
writel(IOMUX_LCDC, &rk3288_grf->iomux_lcdc);
- switch (board_id()) {
- case 0:
- rk808_configure_ldo(PMIC_BUS, 4, 1800); /* VCC18_LCD */
- rk808_configure_ldo(PMIC_BUS, 6, 1000); /* VCC10_LCD */
- gpio_output(GPIO(7, B, 7), 1); /* LCD_EN */
- break;
- default:
- rk808_configure_switch(PMIC_BUS, 2, 1); /* VCC18_LCD */
- rk808_configure_ldo(PMIC_BUS, 7, 3300); /* VCC10_LCD_PWREN_H */
- rk808_configure_switch(PMIC_BUS, 1, 1); /* VCC33_LCD */
- break;
- }
+ rk808_configure_switch(PMIC_BUS, 2, 1); /* VCC18_LCD */
+ rk808_configure_ldo(PMIC_BUS, 7, 3300); /* VCC10_LCD_PWREN_H */
+ rk808_configure_switch(PMIC_BUS, 1, 1); /* VCC33_LCD */
gpio_output(GPIO(7, A, 0), 0); /* LCDC_BL */
gpio_output(GPIO(7, A, 2), 1); /* BL_EN */