summaryrefslogtreecommitdiffstats
path: root/drivers/rtc
diff options
context:
space:
mode:
authorWolfram Sang <wsa+renesas@sang-engineering.com>2019-07-22 13:26:15 -0400
committerAlexandre Belloni <alexandre.belloni@bootlin.com>2019-07-22 16:30:19 -0400
commit46eabee1f6e6495ea465d7ad8bb971c40ba4dc9e (patch)
tree7e978c6c72ae247d293aebfc69bcd0eecdb17c13 /drivers/rtc
parent564225415e7791f809122d8d16f089d276686bda (diff)
rtc: isl12026: convert to i2c_new_dummy_device
Move from i2c_new_dummy() to i2c_new_dummy_device(), so we now get an ERRPTR which we use in error handling. Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> Link: https://lore.kernel.org/r/20190722172618.4061-2-wsa+renesas@sang-engineering.com Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r--drivers/rtc/rtc-isl12026.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/rtc/rtc-isl12026.c b/drivers/rtc/rtc-isl12026.c
index 97f594f9667c..5b6b17fb6d62 100644
--- a/drivers/rtc/rtc-isl12026.c
+++ b/drivers/rtc/rtc-isl12026.c
@@ -454,9 +454,9 @@ static int isl12026_probe_new(struct i2c_client *client)
454 454
455 isl12026_force_power_modes(client); 455 isl12026_force_power_modes(client);
456 456
457 priv->nvm_client = i2c_new_dummy(client->adapter, ISL12026_EEPROM_ADDR); 457 priv->nvm_client = i2c_new_dummy_device(client->adapter, ISL12026_EEPROM_ADDR);
458 if (!priv->nvm_client) 458 if (IS_ERR(priv->nvm_client))
459 return -ENOMEM; 459 return PTR_ERR(priv->nvm_client);
460 460
461 priv->rtc = devm_rtc_allocate_device(&client->dev); 461 priv->rtc = devm_rtc_allocate_device(&client->dev);
462 ret = PTR_ERR_OR_ZERO(priv->rtc); 462 ret = PTR_ERR_OR_ZERO(priv->rtc);