This patch modify Max8997 driver to support multibus I2C
Signed-off-by: Piotr Wilczek <[email protected]>
Signed-off-by: Kyungmin Park <[email protected]>
CC: Minkyu Kang <[email protected]>
---
drivers/misc/pmic_max8997.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/pmic_max8997.c b/drivers/misc/pmic_max8997.c
index 62dbc05..c6e2d98 100644
--- a/drivers/misc/pmic_max8997.c
+++ b/drivers/misc/pmic_max8997.c
@@ -37,7 +37,10 @@ int pmic_init(void)
p->number_of_regs = PMIC_NUM_OF_REGS;
p->hw.i2c.addr = MAX8997_I2C_ADDR;
p->hw.i2c.tx_num = 1;
- p->bus = I2C_PMIC;
-
+#ifdef CONFIG_PMIC_BUS_NUM
+ p->bus = CONFIG_PMIC_BUS_NUM;
+#else
+ p->bus = I2C_PMIC;
+#endif
return 0;
}
--
1.7.5.4
_______________________________________________
U-Boot mailing list
[email protected]
http://lists.denx.de/mailman/listinfo/u-boot