drivers/rtc/rtc-max77686.c: use devm_regmap_init_i2c()
authorSachin Kamat <sachin.kamat@linaro.org>
Mon, 29 Apr 2013 23:20:26 +0000 (16:20 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 30 Apr 2013 01:28:35 +0000 (18:28 -0700)
This driver already uses other devm_* APIs.
Convert regmap_init_i2c too.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Chiwoong Byun <woong.byun@samsung.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/rtc/rtc-max77686.c

index fb08b89c41e7f5ca1da4c2c5b574c10bd8b3a6b3..771812d62e6bd3a961742db477e660771ee593f1 100644 (file)
@@ -514,7 +514,7 @@ static int max77686_rtc_probe(struct platform_device *pdev)
        info->dev = &pdev->dev;
        info->max77686 = max77686;
        info->rtc = max77686->rtc;
-       info->max77686->rtc_regmap = regmap_init_i2c(info->max77686->rtc,
+       info->max77686->rtc_regmap = devm_regmap_init_i2c(info->max77686->rtc,
                                         &max77686_rtc_regmap_config);
        if (IS_ERR(info->max77686->rtc_regmap)) {
                ret = PTR_ERR(info->max77686->rtc_regmap);