From 04ce68eee39eeaebbea60394cc0bba2c6ea49c12 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=C5=81ukasz=20Majewski?= Date: Thu, 29 Mar 2012 01:29:18 +0000 Subject: [PATCH] misc:pmic:samsung Convert TRATS target to use MAX8997 instead of MAX8998 TRATS target uses MAX8997 PMIC device instead of MAX8998. Signed-off-by: Lukasz Majewski Signed-off-by: Kyungmin Park Acked-by: Minkyu Kang --- board/samsung/trats/trats.c | 27 ++++++++++----------------- include/configs/trats.h | 2 +- 2 files changed, 11 insertions(+), 18 deletions(-) diff --git a/board/samsung/trats/trats.c b/board/samsung/trats/trats.c index aa4291d..a7b4e4a 100644 --- a/board/samsung/trats/trats.c +++ b/board/samsung/trats/trats.c @@ -32,7 +32,7 @@ #include #include #include -#include +#include #include "setup.h" @@ -216,26 +216,19 @@ static int s5pc210_phy_control(int on) return -1; if (on) { - ret |= pmic_set_output(p, - MAX8998_REG_BUCK_ACTIVE_DISCHARGE3, - MAX8998_SAFEOUT1, LDO_ON); - ret |= pmic_set_output(p, MAX8998_REG_ONOFF1, - MAX8998_LDO3, LDO_ON); - ret |= pmic_set_output(p, MAX8998_REG_ONOFF2, - MAX8998_LDO8, LDO_ON); - + ret |= pmic_set_output(p, MAX8997_REG_SAFEOUTCTRL, + ENSAFEOUT1, LDO_ON); + ret |= pmic_reg_write(p, MAX8997_REG_LDO3CTRL, EN_LDO); + ret |= pmic_reg_write(p, MAX8997_REG_LDO8CTRL, EN_LDO); } else { - ret |= pmic_set_output(p, MAX8998_REG_ONOFF2, - MAX8998_LDO8, LDO_OFF); - ret |= pmic_set_output(p, MAX8998_REG_ONOFF1, - MAX8998_LDO3, LDO_OFF); - ret |= pmic_set_output(p, - MAX8998_REG_BUCK_ACTIVE_DISCHARGE3, - MAX8998_SAFEOUT1, LDO_OFF); + ret |= pmic_reg_write(p, MAX8997_REG_LDO8CTRL, DIS_LDO); + ret |= pmic_reg_write(p, MAX8997_REG_LDO3CTRL, DIS_LDO); + ret |= pmic_set_output(p, MAX8997_REG_SAFEOUTCTRL, + ENSAFEOUT1, LDO_OFF); } if (ret) { - puts("MAX8998 LDO setting error!\n"); + puts("MAX8997 LDO setting error!\n"); return -1; } diff --git a/include/configs/trats.h b/include/configs/trats.h index 674bc71..1bc2bb2 100644 --- a/include/configs/trats.h +++ b/include/configs/trats.h @@ -207,7 +207,7 @@ #define CONFIG_PMIC #define CONFIG_PMIC_I2C -#define CONFIG_PMIC_MAX8998 +#define CONFIG_PMIC_MAX8997 #define CONFIG_USB_GADGET #define CONFIG_USB_GADGET_S3C_UDC_OTG -- 2.7.4