Re: [PATCH v8 3/5] RTC: RK808: add RTC driver for RK808

From: Doug Anderson
Date: Wed Sep 03 2014 - 17:30:42 EST


Chris,

On Wed, Sep 3, 2014 at 10:04 AM, Chris Zhong <zyw@xxxxxxxxxxxxxx> wrote:
> + rk808_rtc->irq = platform_get_irq(pdev, 0);
> + if (rk808_rtc->irq <= 0) {
> + dev_err(&pdev->dev, "Wake up is not possible as irq = %d\n",
> + rk808_rtc->irq);
> + return -ENXIO;
> + }

You missed some of my feedback (though your changelog says otherwise).
Note: it would probably be good to also only print if it's not
EPROBE_DEFER.

Thus, the above should be:

rk808_rtc->irq = platform_get_irq(pdev, 0);
if (rk808_rtc->irq < 0) {
if (rk808_rtc->irq != -EPROBE_DEFER)
dev_err(&pdev->dev, "Wake up is not possible as irq = %d\n",
rk808_rtc->irq);
return rk808_rtc->irq;
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/