summaryrefslogtreecommitdiff
path: root/drivers/rtc
diff options
context:
space:
mode:
authorAlexandre Belloni <alexandre.belloni@bootlin.com>2018-02-12 23:47:31 +0100
committerAlexandre Belloni <alexandre.belloni@bootlin.com>2018-03-01 10:49:22 +0100
commit88d3aadea0c72bc9bfaec2504b331134056e9bce (patch)
treee666fd0f797e4a166d29ae78c9159231ed2b583b /drivers/rtc
parent0e7a412fa24c021cba7feebbc82878a44f58b33a (diff)
rtc: rv8803: call rtc_nvmem_register()
Call rtc_nvmem_register instead of letting the core do it and stop using the nvmem_config member of struct rtc_device. Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r--drivers/rtc/rtc-rv8803.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/rtc/rtc-rv8803.c b/drivers/rtc/rtc-rv8803.c
index aae2576741a6..c10132d8cf2e 100644
--- a/drivers/rtc/rtc-rv8803.c
+++ b/drivers/rtc/rtc-rv8803.c
@@ -591,12 +591,13 @@ static int rv8803_probe(struct i2c_client *client,
rv8803->nvmem_cfg.priv = client;
rv8803->rtc->ops = &rv8803_rtc_ops;
- rv8803->rtc->nvmem_config = &rv8803->nvmem_cfg;
rv8803->rtc->nvram_old_abi = true;
err = rtc_register_device(rv8803->rtc);
if (err)
return err;
+ rtc_nvmem_register(rv8803->rtc, &rv8803->nvmem_cfg);
+
err = rv8803_write_reg(rv8803->client, RV8803_EXT, RV8803_EXT_WADA);
if (err)
return err;