mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 03:01:39 -04:00
rtc: gemini: fix ptr_ret.cocci warnings
drivers/rtc/rtc-gemini.c:151:1-3: WARNING: PTR_ERR_OR_ZERO can be used Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR Generated by: scripts/coccinelle/api/ptr_ret.cocci Signed-off-by: Fengguang Wu <[email protected]> Signed-off-by: Viresh Kumar <[email protected]> Signed-off-by: Alexandre Belloni <[email protected]>
This commit is contained in:
parent
e7cba884af
commit
202cc98acf
1 changed files with 1 additions and 4 deletions
|
|
@ -148,10 +148,7 @@ static int gemini_rtc_probe(struct platform_device *pdev)
|
|||
|
||||
rtc->rtc_dev = rtc_device_register(pdev->name, dev,
|
||||
&gemini_rtc_ops, THIS_MODULE);
|
||||
if (IS_ERR(rtc->rtc_dev))
|
||||
return PTR_ERR(rtc->rtc_dev);
|
||||
|
||||
return 0;
|
||||
return PTR_ERR_OR_ZERO(rtc->rtc_dev);
|
||||
}
|
||||
|
||||
static int gemini_rtc_remove(struct platform_device *pdev)
|
||||
|
|
|
|||
Loading…
Reference in a new issue