Ryu: Move I2C6 init to ramstage
BUG=chrome-os-partner:31820 BRANCH=none TEST=Dumped Speaker Driver (AD SSM4567) regs on Ryu, looks good. Change-Id: I9b094e9d22726d67d41f2ce78088f361c73895fd Signed-off-by: Patrick Georgi <pgeorgi@chromium.org> Original-Commit-Id: 4c0bfb5f747f55009b7c2b2ba4b24d91443b1639 Original-Change-Id: Idd5b95cfec7d3ade7508393b81ab3049ce15a2fb Original-Signed-off-by: Tom Warren <twarren@nvidia.com> Original-Reviewed-on: https://chromium-review.googlesource.com/218950 Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-on: http://review.coreboot.org/9095 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
This commit is contained in:
parent
40edd3864f
commit
bfbfcf719c
|
@ -27,6 +27,7 @@
|
|||
#include <soc/funitcfg.h>
|
||||
#include <soc/padconfig.h>
|
||||
#include <soc/nvidia/tegra132/clk_rst.h>
|
||||
#include <soc/nvidia/tegra/i2c.h>
|
||||
|
||||
static const struct pad_config mmcpads[] = {
|
||||
/* MMC4 (eMMC) */
|
||||
|
@ -45,6 +46,8 @@ static const struct pad_config mmcpads[] = {
|
|||
static const struct funit_cfg funits[] = {
|
||||
/* MMC on SDMMC4 controller at 48MHz. */
|
||||
FUNIT_CFG(SDMMC4, PLLP, 48000, mmcpads, ARRAY_SIZE(mmcpads)),
|
||||
/* I2C6 for audio, temp sensor, etc. */
|
||||
FUNIT_CFG(I2C6, PLLP, 400, NULL, 0),
|
||||
FUNIT_CFG_USB(USBD),
|
||||
};
|
||||
|
||||
|
@ -60,6 +63,10 @@ static void mainboard_init(device_t dev)
|
|||
if (disp_clk != req_disp_clk)
|
||||
printk(BIOS_DEBUG, "display clock: %u vs %u (r)\n", disp_clk,
|
||||
req_disp_clk);
|
||||
|
||||
/* I2C6 bus (audio, etc.) */
|
||||
soc_configure_i2c6pad();
|
||||
i2c_init(I2C6_BUS);
|
||||
}
|
||||
|
||||
static void mainboard_enable(device_t dev)
|
||||
|
|
|
@ -57,8 +57,6 @@ static const struct funit_cfg funits[] = {
|
|||
FUNIT_CFG(I2C3, PLLP, 400, tpm_pads, ARRAY_SIZE(tpm_pads)),
|
||||
/* EC on I2C2 - pulled to 3.3V @ 100kHz */
|
||||
FUNIT_CFG(I2C2, PLLP, 100, ec_i2c_pads, ARRAY_SIZE(ec_i2c_pads)),
|
||||
/* I2C6 for audio, temp sensor, etc. */
|
||||
FUNIT_CFG(I2C6, PLLP, 400, NULL, 0),
|
||||
};
|
||||
|
||||
static void lte_modem_init(void)
|
||||
|
@ -92,14 +90,11 @@ void romstage_mainboard_init(void)
|
|||
/* Bring up controller interfaces for ramstage loading. */
|
||||
soc_configure_funits(funits, ARRAY_SIZE(funits));
|
||||
soc_configure_pads(padcfgs, ARRAY_SIZE(padcfgs));
|
||||
soc_configure_i2c6pad();
|
||||
|
||||
/* TPM */
|
||||
i2c_init(I2C3_BUS);
|
||||
/* EC */
|
||||
i2c_init(I2C2_BUS);
|
||||
/* I2C6 bus (audio, etc.) */
|
||||
i2c_init(I2C6_BUS);
|
||||
|
||||
lte_modem_init();
|
||||
}
|
||||
|
|
|
@ -32,7 +32,6 @@ romstage-y += cpu.c
|
|||
romstage-y += reset.c
|
||||
romstage-y += spi.c
|
||||
romstage-y += i2c.c
|
||||
romstage-y += i2c6.c
|
||||
romstage-y += dma.c
|
||||
romstage-y += monotonic_timer.c
|
||||
romstage-y += padconfig.c
|
||||
|
@ -58,6 +57,8 @@ ramstage-y += clock.c
|
|||
ramstage-y += soc.c
|
||||
ramstage-y += spi.c
|
||||
ramstage-y += i2c.c
|
||||
ramstage-y += i2c6.c
|
||||
ramstage-y += power.c
|
||||
ramstage-y += dma.c
|
||||
ramstage-y += gic.c
|
||||
ramstage-y += monotonic_timer.c
|
||||
|
|
Loading…
Reference in New Issue