google/oak: Delete rowan
Rowan board is dead, dissect it out of Oak. Signed-off-by: Evan Green <evgreen@chromium.org> BUG=chromium:840888 BRANCH=none TEST=emerge-oak coreboot chromeos-bootimage CQ-DEPEND=CL:1538915,CL:*1087044 Change-Id: Ifb19fa0cd814853270847bc14fc21c841d905146 Reviewed-on: https://review.coreboot.org/c/coreboot/+/32061 Reviewed-by: Julius Werner <jwerner@chromium.org> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
60aaac7ad0
commit
0aa1f9e905
|
@ -20,13 +20,12 @@ if BOARD_GOOGLE_OAK_COMMON
|
||||||
|
|
||||||
config OTHERS_HAVE_TPM1
|
config OTHERS_HAVE_TPM1
|
||||||
bool
|
bool
|
||||||
default y if !BOARD_GOOGLE_ROWAN
|
default y
|
||||||
select MAINBOARD_HAS_I2C_TPM_GENERIC
|
select MAINBOARD_HAS_I2C_TPM_GENERIC
|
||||||
select MAINBOARD_HAS_TPM1
|
select MAINBOARD_HAS_TPM1
|
||||||
|
|
||||||
config OAK_HAS_TPM2
|
config OAK_HAS_TPM2
|
||||||
bool
|
bool
|
||||||
default y if BOARD_GOOGLE_ROWAN
|
|
||||||
default n
|
default n
|
||||||
select MAINBOARD_HAS_I2C_TPM_CR50
|
select MAINBOARD_HAS_I2C_TPM_CR50
|
||||||
select MAINBOARD_HAS_TPM2
|
select MAINBOARD_HAS_TPM2
|
||||||
|
@ -90,7 +89,6 @@ config MAINBOARD_PART_NUMBER
|
||||||
default "Oak" if BOARD_GOOGLE_OAK
|
default "Oak" if BOARD_GOOGLE_OAK
|
||||||
default "Elm" if BOARD_GOOGLE_ELM
|
default "Elm" if BOARD_GOOGLE_ELM
|
||||||
default "Hana" if BOARD_GOOGLE_HANA
|
default "Hana" if BOARD_GOOGLE_HANA
|
||||||
default "Rowan" if BOARD_GOOGLE_ROWAN
|
|
||||||
|
|
||||||
config GBB_HWID
|
config GBB_HWID
|
||||||
string
|
string
|
||||||
|
@ -98,7 +96,6 @@ config GBB_HWID
|
||||||
default "OAK TEST 6858" if BOARD_GOOGLE_OAK
|
default "OAK TEST 6858" if BOARD_GOOGLE_OAK
|
||||||
default "ELM TEST 3839" if BOARD_GOOGLE_ELM
|
default "ELM TEST 3839" if BOARD_GOOGLE_ELM
|
||||||
default "HANA TEST 5855" if BOARD_GOOGLE_HANA
|
default "HANA TEST 5855" if BOARD_GOOGLE_HANA
|
||||||
default "ROWAN TEST 9387" if BOARD_GOOGLE_ROWAN
|
|
||||||
|
|
||||||
# All Oak-derivatives count their board IDs as 0 being equivalent to Oak rev6.
|
# All Oak-derivatives count their board IDs as 0 being equivalent to Oak rev6.
|
||||||
config BOARD_ID_ADJUSTMENT
|
config BOARD_ID_ADJUSTMENT
|
||||||
|
@ -106,6 +103,5 @@ config BOARD_ID_ADJUSTMENT
|
||||||
default 0 if BOARD_GOOGLE_OAK
|
default 0 if BOARD_GOOGLE_OAK
|
||||||
default 7 if BOARD_GOOGLE_ELM
|
default 7 if BOARD_GOOGLE_ELM
|
||||||
default 11 if BOARD_GOOGLE_HANA
|
default 11 if BOARD_GOOGLE_HANA
|
||||||
default 15 if BOARD_GOOGLE_ROWAN
|
|
||||||
|
|
||||||
endif # BOARD_GOOGLE_OAK
|
endif # BOARD_GOOGLE_OAK
|
||||||
|
|
|
@ -11,7 +11,3 @@ config BOARD_GOOGLE_ELM
|
||||||
config BOARD_GOOGLE_HANA
|
config BOARD_GOOGLE_HANA
|
||||||
bool "-> Hana (Lenovo N23 Yoga Chromebook)"
|
bool "-> Hana (Lenovo N23 Yoga Chromebook)"
|
||||||
select BOARD_GOOGLE_OAK_COMMON
|
select BOARD_GOOGLE_OAK_COMMON
|
||||||
|
|
||||||
config BOARD_GOOGLE_ROWAN
|
|
||||||
bool "-> Rowan"
|
|
||||||
select BOARD_GOOGLE_OAK_COMMON
|
|
||||||
|
|
|
@ -17,16 +17,10 @@
|
||||||
#define __MAINBOARD_GOOGLE_OAK_GPIO_H__
|
#define __MAINBOARD_GOOGLE_OAK_GPIO_H__
|
||||||
#include <soc/gpio.h>
|
#include <soc/gpio.h>
|
||||||
|
|
||||||
#if CONFIG(BOARD_GOOGLE_ROWAN)
|
|
||||||
#define LID GPIO(KPROW1)
|
|
||||||
#define RAM_ID_1 GPIO(DSI_TE)
|
|
||||||
#define RAM_ID_2 GPIO(RDP1_A)
|
|
||||||
#else
|
|
||||||
#define LID ((board_id() + CONFIG_BOARD_ID_ADJUSTMENT < 7) ? \
|
#define LID ((board_id() + CONFIG_BOARD_ID_ADJUSTMENT < 7) ? \
|
||||||
GPIO(EINT12) : GPIO(SPI_CK))
|
GPIO(EINT12) : GPIO(SPI_CK))
|
||||||
#define RAM_ID_1 GPIO(RCN_A)
|
#define RAM_ID_1 GPIO(RCN_A)
|
||||||
#define RAM_ID_2 GPIO(RCP_A)
|
#define RAM_ID_2 GPIO(RCP_A)
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Board ID related GPIOS. */
|
/* Board ID related GPIOS. */
|
||||||
#define BOARD_ID_0 GPIO(RDN3_A)
|
#define BOARD_ID_0 GPIO(RDN3_A)
|
||||||
|
|
|
@ -127,12 +127,10 @@ static void configure_usb(void)
|
||||||
if (board_id() + CONFIG_BOARD_ID_ADJUSTMENT > 3) {
|
if (board_id() + CONFIG_BOARD_ID_ADJUSTMENT > 3) {
|
||||||
/* Type C port 0 Over current alert pin */
|
/* Type C port 0 Over current alert pin */
|
||||||
gpio_input_pullup(GPIO(MSDC3_DSL));
|
gpio_input_pullup(GPIO(MSDC3_DSL));
|
||||||
if (!CONFIG(BOARD_GOOGLE_ROWAN)) {
|
/* Enable USB3 type A port 0 5V load switch */
|
||||||
/* Enable USB3 type A port 0 5V load switch */
|
gpio_output(GPIO(CM2MCLK), 1);
|
||||||
gpio_output(GPIO(CM2MCLK), 1);
|
/* USB3 Type A port 0 power over current alert pin */
|
||||||
/* USB3 Type A port 0 power over current alert pin */
|
gpio_input_pullup(GPIO(CMPCLK));
|
||||||
gpio_input_pullup(GPIO(CMPCLK));
|
|
||||||
}
|
|
||||||
/* Type C port 1 over current alert pin */
|
/* Type C port 1 over current alert pin */
|
||||||
if (board_id() + CONFIG_BOARD_ID_ADJUSTMENT < 7)
|
if (board_id() + CONFIG_BOARD_ID_ADJUSTMENT < 7)
|
||||||
gpio_input_pullup(GPIO(PCM_SYNC));
|
gpio_input_pullup(GPIO(PCM_SYNC));
|
||||||
|
@ -150,9 +148,6 @@ static void configure_usb(void)
|
||||||
|
|
||||||
static void configure_usb_hub(void)
|
static void configure_usb_hub(void)
|
||||||
{
|
{
|
||||||
if (CONFIG(BOARD_GOOGLE_ROWAN))
|
|
||||||
return;
|
|
||||||
|
|
||||||
/* set usb hub reset pin (low active) to high */
|
/* set usb hub reset pin (low active) to high */
|
||||||
if (board_id() + CONFIG_BOARD_ID_ADJUSTMENT > 4)
|
if (board_id() + CONFIG_BOARD_ID_ADJUSTMENT > 4)
|
||||||
gpio_output(GPIO(UTXD3), 1);
|
gpio_output(GPIO(UTXD3), 1);
|
||||||
|
@ -203,51 +198,6 @@ static void configure_display(void)
|
||||||
udelay(100);
|
udelay(100);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void configure_backlight_rowan(void)
|
|
||||||
{
|
|
||||||
gpio_output(GPIO(DAIPCMOUT), 0); /* PANEL_LCD_POWER_EN */
|
|
||||||
gpio_output(GPIO(DISP_PWM0), 0); /* DISP_PWM0 */
|
|
||||||
gpio_output(GPIO(PCM_TX), 0); /* PANEL_POWER_EN */
|
|
||||||
}
|
|
||||||
|
|
||||||
static void configure_display_rowan(void)
|
|
||||||
{
|
|
||||||
gpio_output(GPIO(UCTS2), 1); /* VDDIO_EN */
|
|
||||||
/* delay 15 ms for panel vddio to stabilize */
|
|
||||||
mdelay(15);
|
|
||||||
|
|
||||||
gpio_output(GPIO(SRCLKENAI2), 1); /* LCD_RESET */
|
|
||||||
udelay(20);
|
|
||||||
gpio_output(GPIO(SRCLKENAI2), 0); /* LCD_RESET */
|
|
||||||
udelay(20);
|
|
||||||
gpio_output(GPIO(SRCLKENAI2), 1); /* LCD_RESET */
|
|
||||||
mdelay(20);
|
|
||||||
|
|
||||||
/* Rowan panel avdd */
|
|
||||||
gpio_output(GPIO(URTS2), 1);
|
|
||||||
|
|
||||||
/* Rowan panel avee */
|
|
||||||
gpio_output(GPIO(URTS0), 1);
|
|
||||||
|
|
||||||
/* panel.delay.prepare */
|
|
||||||
mdelay(20);
|
|
||||||
}
|
|
||||||
|
|
||||||
static const struct edid rowan_boe_edid = {
|
|
||||||
.panel_bits_per_color = 8,
|
|
||||||
.panel_bits_per_pixel = 24,
|
|
||||||
.mode = {
|
|
||||||
.name = "1536x2048@60Hz",
|
|
||||||
.pixel_clock = 241646,
|
|
||||||
.lvds_dual_channel = 1,
|
|
||||||
.refresh = 60,
|
|
||||||
.ha = 1536, .hbl = 404, .hso = 200, .hspw = 4, .hborder = 0,
|
|
||||||
.va = 2048, .vbl = 28, .vso = 12, .vspw = 2, .vborder = 0,
|
|
||||||
.phsync = '-', .pvsync = '-',
|
|
||||||
.x_mm = 147, .y_mm = 196,
|
|
||||||
},
|
|
||||||
};
|
|
||||||
|
|
||||||
static int read_edid_from_ps8640(struct edid *edid)
|
static int read_edid_from_ps8640(struct edid *edid)
|
||||||
{
|
{
|
||||||
u8 i2c_bus, i2c_addr;
|
u8 i2c_bus, i2c_addr;
|
||||||
|
@ -278,22 +228,11 @@ static void display_startup(void)
|
||||||
u32 mipi_dsi_flags;
|
u32 mipi_dsi_flags;
|
||||||
bool dual_dsi_mode;
|
bool dual_dsi_mode;
|
||||||
|
|
||||||
if (CONFIG(BOARD_GOOGLE_ROWAN)) {
|
if (read_edid_from_ps8640(&edid) < 0)
|
||||||
edid = rowan_boe_edid;
|
return;
|
||||||
dual_dsi_mode = true;
|
|
||||||
mipi_dsi_flags = MIPI_DSI_MODE_VIDEO |
|
|
||||||
MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
|
|
||||||
MIPI_DSI_MODE_LPM | MIPI_DSI_MODE_EOT_PACKET |
|
|
||||||
MIPI_DSI_CLOCK_NON_CONTINUOUS;
|
|
||||||
} else {
|
|
||||||
if (read_edid_from_ps8640(&edid) < 0)
|
|
||||||
return;
|
|
||||||
|
|
||||||
dual_dsi_mode = false;
|
|
||||||
mipi_dsi_flags = MIPI_DSI_MODE_VIDEO |
|
|
||||||
MIPI_DSI_MODE_VIDEO_SYNC_PULSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
dual_dsi_mode = false;
|
||||||
|
mipi_dsi_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE;
|
||||||
edid_set_framebuffer_bits_per_pixel(&edid, 32, 0);
|
edid_set_framebuffer_bits_per_pixel(&edid, 32, 0);
|
||||||
|
|
||||||
mtk_ddp_init(dual_dsi_mode);
|
mtk_ddp_init(dual_dsi_mode);
|
||||||
|
@ -327,13 +266,8 @@ static void mainboard_init(struct device *dev)
|
||||||
|
|
||||||
if (display_init_required()) {
|
if (display_init_required()) {
|
||||||
mtcmos_display_power_on();
|
mtcmos_display_power_on();
|
||||||
if (CONFIG(BOARD_GOOGLE_ROWAN)) {
|
configure_backlight();
|
||||||
configure_backlight_rowan();
|
configure_display();
|
||||||
configure_display_rowan();
|
|
||||||
} else {
|
|
||||||
configure_backlight();
|
|
||||||
configure_display();
|
|
||||||
}
|
|
||||||
display_startup();
|
display_startup();
|
||||||
} else {
|
} else {
|
||||||
printk(BIOS_INFO, "Skipping display init.\n");
|
printk(BIOS_INFO, "Skipping display init.\n");
|
||||||
|
|
Loading…
Reference in New Issue