summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKrzysztof Kozlowski <k.kozlowski@samsung.com>2014-02-28 10:41:42 (GMT)
committerHyungwon Hwang <human.hwang@samsung.com>2014-12-23 02:09:29 (GMT)
commitcfd71b860551426311be216e3b3ab0447a3645b7 (patch)
tree9a3d130cb2290be2a9f808df45927f2d3b9b23e9
parent34c16a783b687075c56fe134fa4ec780cd67903a (diff)
downloadlinux-3.10-cfd71b860551426311be216e3b3ab0447a3645b7.zip
linux-3.10-cfd71b860551426311be216e3b3ab0447a3645b7.tar.gz
linux-3.10-cfd71b860551426311be216e3b3ab0447a3645b7.tar.bz2
mfd: sec: Select different RTC regmaps for devices
This patch prepares for adding support for S2MPS14 RTC driver by selecting different regmaps for S2MPS1X/S5M876X RTC devices. Change-Id: I9bc7bfb0b1c902629bd52c19808d1f9ac8d8e911 Signed-off-by: Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by: Lee Jones <lee.jones@linaro.org>
-rw-r--r--drivers/mfd/sec-core.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
index badf621..15d8326 100644
--- a/drivers/mfd/sec-core.c
+++ b/drivers/mfd/sec-core.c
@@ -305,7 +305,13 @@ static int sec_pmic_probe(struct i2c_client *i2c,
switch (sec_pmic->device_type) {
case S2MPS11X:
regmap = &s2mps11_regmap_config;
- regmap_rtc = NULL; /* No RTC mfd_cell for S2MPS11 */
+ /*
+ * The rtc-s5m driver does not support S2MPS11 and there
+ * is no mfd_cell for S2MPS11 RTC device.
+ * However we must pass something to devm_regmap_init_i2c()
+ * so use S5M-like regmap config even though it wouldn't work.
+ */
+ regmap_rtc = &s5m_rtc_regmap_config;
break;
case S2MPS14X:
regmap = &s2mps14_regmap_config;