summaryrefslogtreecommitdiff
path: root/drivers/rtc/rtc-rv3028.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/rtc/rtc-rv3028.c')
-rw-r--r--drivers/rtc/rtc-rv3028.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/rtc/rtc-rv3028.c b/drivers/rtc/rtc-rv3028.c
index 2b316661a578..bbdfebd70644 100644
--- a/drivers/rtc/rtc-rv3028.c
+++ b/drivers/rtc/rtc-rv3028.c
@@ -625,6 +625,8 @@ static int rv3028_probe(struct i2c_client *client)
return -ENOMEM;
rv3028->regmap = devm_regmap_init_i2c(client, &regmap_config);
+ if (IS_ERR(rv3028->regmap))
+ return PTR_ERR(rv3028->regmap);
i2c_set_clientdata(client, rv3028);