summaryrefslogtreecommitdiffstats
path: root/board/BuR/tseries
diff options
context:
space:
mode:
authorHannes Petermaier <hannes.petermaier@br-automation.com>2015-03-19 10:43:15 +0100
committerTom Rini <trini@konsulko.com>2015-03-28 12:07:44 -0400
commit2b5b2be5e9444688e5d8bd0e2d263fccd1f2eee4 (patch)
treebfd53e6a20757fcf21cc8b4d5da042cde1decda0 /board/BuR/tseries
parent3b6e4841225c60aa1bd0212754ba0edc1822393d (diff)
downloadblackbird-obmc-uboot-2b5b2be5e9444688e5d8bd0e2d263fccd1f2eee4.tar.gz
blackbird-obmc-uboot-2b5b2be5e9444688e5d8bd0e2d263fccd1f2eee4.zip
board/BuR/common: move I2C initialization from common part to board-specific
At this time I2C and responsible pin-mux is setup during PMIC initialziation within common.c, this is possible because today PMIC is always connected on I2C0. In Future this will be changed, PMIC isn't anymore connected to bus0 in call cases. So we do following: - rename enable_i2c_pin_mux0 to enable_i2c_pin_mux to be generic for enabling pin-mux on different or more busses. - move the call to i2c_pin_mux and i2c_init from common.c to the specific board.c Signed-off-by: Hannes Petermaier <hannes.petermaier@br-automation.com> Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>
Diffstat (limited to 'board/BuR/tseries')
-rw-r--r--board/BuR/tseries/board.c4
-rw-r--r--board/BuR/tseries/mux.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/board/BuR/tseries/board.c b/board/BuR/tseries/board.c
index 9402aa4205..89e989f246 100644
--- a/board/BuR/tseries/board.c
+++ b/board/BuR/tseries/board.c
@@ -123,6 +123,10 @@ void am33xx_spl_board_init(void)
/* setup LCD-Pixel Clock */
writel(0x2, &cmdpll->clklcdcpixelclk); /* clock comes from perPLL M2 */
+ /* setup I2C */
+ enable_i2c_pin_mux();
+ i2c_set_bus_num(0);
+ i2c_init(CONFIG_SYS_OMAP24_I2C_SPEED, CONFIG_SYS_OMAP24_I2C_SLAVE);
pmicsetup(0);
}
diff --git a/board/BuR/tseries/mux.c b/board/BuR/tseries/mux.c
index 2c87a63b85..ac7e885f61 100644
--- a/board/BuR/tseries/mux.c
+++ b/board/BuR/tseries/mux.c
@@ -226,7 +226,7 @@ void enable_uart0_pin_mux(void)
configure_module_pin_mux(uart0_pin_mux);
}
-void enable_i2c0_pin_mux(void)
+void enable_i2c_pin_mux(void)
{
configure_module_pin_mux(i2c0_pin_mux);
}
OpenPOWER on IntegriCloud