[PATCH 2/5] roc-pc-rk3399: Enable I2C in SPL for add-on board detection
sunil at amarulasolutions.com
sunil at amarulasolutions.com
Fri May 22 20:03:25 CEST 2020
From: Suniel Mahesh <sunil at amarulasolutions.com>
This patch enables I2C in SPL for any add-on board detection
at run time.
Signed-off-by: Suniel Mahesh <sunil at amarulasolutions.com>
Signed-off-by: Jagan Teki <jagan at amarulasolutions.com>
---
arch/arm/dts/rk3399-roc-pc-u-boot.dtsi | 13 +++++++++++++
configs/roc-pc-rk3399_defconfig | 5 ++++-
2 files changed, 17 insertions(+), 1 deletion(-)
diff --git a/arch/arm/dts/rk3399-roc-pc-u-boot.dtsi b/arch/arm/dts/rk3399-roc-pc-u-boot.dtsi
index 141dd0b..6de30d4 100644
--- a/arch/arm/dts/rk3399-roc-pc-u-boot.dtsi
+++ b/arch/arm/dts/rk3399-roc-pc-u-boot.dtsi
@@ -56,3 +56,16 @@
&vcc_sdio {
regulator-always-on;
};
+
+&pcfg_pull_none_12ma {
+ u-boot,dm-pre-reloc;
+};
+
+&i2c2 {
+ u-boot,dm-pre-reloc;
+ status= "okay";
+};
+
+&i2c2_xfer {
+ u-boot,dm-pre-reloc;
+};
diff --git a/configs/roc-pc-rk3399_defconfig b/configs/roc-pc-rk3399_defconfig
index 76e76c1..4d1a077 100644
--- a/configs/roc-pc-rk3399_defconfig
+++ b/configs/roc-pc-rk3399_defconfig
@@ -13,19 +13,22 @@ CONFIG_DISPLAY_BOARDINFO_LATE=y
# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set
CONFIG_SPL_STACK_R=y
CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN=0x10000
+CONFIG_SPL_I2C_SUPPORT=y
CONFIG_TPL=y
CONFIG_TPL_GPIO_SUPPORT=y
CONFIG_CMD_BOOTZ=y
CONFIG_CMD_GPT=y
+CONFIG_CMD_I2C=y
CONFIG_CMD_MMC=y
CONFIG_CMD_USB=y
# CONFIG_CMD_SETEXPR is not set
CONFIG_CMD_TIME=y
CONFIG_SPL_OF_CONTROL=y
CONFIG_DEFAULT_DEVICE_TREE="rk3399-roc-pc"
-CONFIG_OF_SPL_REMOVE_PROPS="pinctrl-0 pinctrl-names clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents"
CONFIG_ENV_IS_IN_MMC=y
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
+CONFIG_SPL_DM_SEQ_ALIAS=y
CONFIG_ROCKCHIP_GPIO=y
CONFIG_SYS_I2C_ROCKCHIP=y
CONFIG_MISC=y
--
2.7.4
More information about the U-Boot
mailing list