From 58f27d7d061b47f57c84cad7d9af239c6bc6977e Mon Sep 17 00:00:00 2001 From: Sachin Kamat Date: Tue, 12 Nov 2013 15:10:28 -0800 Subject: drivers/rtc/rtc-vt8500.c: fix return value Propagate the return value from platform_get_irq() instead of hardcoding. Signed-off-by: Sachin Kamat Cc: Jingoo Han Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/rtc/rtc-vt8500.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/rtc/rtc-vt8500.c b/drivers/rtc/rtc-vt8500.c index c2d6331fc712..5be217df1d75 100644 --- a/drivers/rtc/rtc-vt8500.c +++ b/drivers/rtc/rtc-vt8500.c @@ -228,7 +228,7 @@ static int vt8500_rtc_probe(struct platform_device *pdev) vt8500_rtc->irq_alarm = platform_get_irq(pdev, 0); if (vt8500_rtc->irq_alarm < 0) { dev_err(&pdev->dev, "No alarm IRQ resource defined\n"); - return -ENXIO; + return vt8500_rtc->irq_alarm; } vt8500_rtc->res = devm_request_mem_region(&pdev->dev, -- cgit v1.2.1