[U-Boot] [PATCH 5/5] DRIVERS: MISC: PMIC: Modify pmic driver to support multibus I2C

Piotr Wilczek p.wilczek at samsung.com
Mon Sep 24 08:49:22 CEST 2012


This patch modify Max8997 driver to support multibus I2C

Signed-off-by: Piotr Wilczek <p.wilczek at samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park at samsung.com>
CC: Minkyu Kang <mk7.kang at samsung.com>
---
 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



More information about the U-Boot mailing list