mirror of https://gitee.com/openkylin/linux.git
rtc: ingenic: Fix masking of error code
The code was returning -ENOENT on any error of platform_get_irq(), even if it returned a different error. Signed-off-by: Paul Cercueil <paul@crapouillou.net> Link: https://lore.kernel.org/r/20200505221336.222313-6-paul@crapouillou.net Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
This commit is contained in:
parent
77d8f3c122
commit
15eeadd801
|
@ -323,7 +323,7 @@ static int jz4740_rtc_probe(struct platform_device *pdev)
|
|||
|
||||
irq = platform_get_irq(pdev, 0);
|
||||
if (irq < 0)
|
||||
return -ENOENT;
|
||||
return irq;
|
||||
|
||||
rtc->base = devm_platform_ioremap_resource(pdev, 0);
|
||||
if (IS_ERR(rtc->base))
|
||||
|
|
Loading…
Reference in New Issue