Re: [PATCH] rtc: brcmstb-waketimer: fix settime function

From: Florian Fainelli
Date: Wed Jun 28 2017 - 19:15:25 EST


On 06/28/2017 01:07 PM, Arnd Bergmann wrote:
> gcc warns about an unused variable in the new driver:
>
> drivers/rtc/rtc-brcmstb-waketimer.c: In function 'brcmstb_waketmr_settime':
> drivers/rtc/rtc-brcmstb-waketimer.c:142:6: error: unused variable 'ret' [-Werror=unused-variable]
>
> The same function also doesn't handle overflow correctly, this makes
> it return -EINVAL when passed a time that doesn't fit within the
> range of the register.

Yes, thanks for doing that.

>
> Fixes: 9f4ad359c801 ("rtc: brcmstb-waketimer: Add Broadcom STB wake-timer")
> Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>

Reviewed-by: Florian Fainelli <f.fainelli@xxxxxxxxx>
--
Florian