mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-26 19:44:21 +08:00
drivers/rtc: Replace PTR_RET with PTR_ERR_OR_ZERO
PTR_RET is now deprecated. Use PTR_ERR_OR_ZERO instead. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
parent
6b4f2b56a4
commit
dac30a9843
@ -250,7 +250,7 @@ static int da9052_rtc_probe(struct platform_device *pdev)
|
||||
|
||||
rtc->rtc = devm_rtc_device_register(&pdev->dev, pdev->name,
|
||||
&da9052_rtc_ops, THIS_MODULE);
|
||||
return PTR_RET(rtc->rtc);
|
||||
return PTR_ERR_OR_ZERO(rtc->rtc);
|
||||
}
|
||||
|
||||
static struct platform_driver da9052_rtc_driver = {
|
||||
|
@ -268,7 +268,7 @@ static int isl12022_probe(struct i2c_client *client,
|
||||
isl12022->rtc = devm_rtc_device_register(&client->dev,
|
||||
isl12022_driver.driver.name,
|
||||
&isl12022_rtc_ops, THIS_MODULE);
|
||||
return PTR_RET(isl12022->rtc);
|
||||
return PTR_ERR_OR_ZERO(isl12022->rtc);
|
||||
}
|
||||
|
||||
static const struct i2c_device_id isl12022_id[] = {
|
||||
|
@ -175,7 +175,7 @@ static int m48t35_probe(struct platform_device *pdev)
|
||||
|
||||
priv->rtc = devm_rtc_device_register(&pdev->dev, "m48t35",
|
||||
&m48t35_ops, THIS_MODULE);
|
||||
return PTR_RET(priv->rtc);
|
||||
return PTR_ERR_OR_ZERO(priv->rtc);
|
||||
}
|
||||
|
||||
static struct platform_driver m48t35_platform_driver = {
|
||||
|
@ -264,7 +264,7 @@ static int pcf8563_probe(struct i2c_client *client,
|
||||
pcf8563_driver.driver.name,
|
||||
&pcf8563_rtc_ops, THIS_MODULE);
|
||||
|
||||
return PTR_RET(pcf8563->rtc);
|
||||
return PTR_ERR_OR_ZERO(pcf8563->rtc);
|
||||
}
|
||||
|
||||
static const struct i2c_device_id pcf8563_id[] = {
|
||||
|
@ -285,7 +285,7 @@ static int pcf8583_probe(struct i2c_client *client,
|
||||
pcf8583_driver.driver.name,
|
||||
&pcf8583_rtc_ops, THIS_MODULE);
|
||||
|
||||
return PTR_RET(pcf8583->rtc);
|
||||
return PTR_ERR_OR_ZERO(pcf8583->rtc);
|
||||
}
|
||||
|
||||
static const struct i2c_device_id pcf8583_id[] = {
|
||||
|
Loading…
Reference in New Issue
Block a user