Re: [PATCH] power: supply: ab8500: stop using getnstimeofday64()

From: Linus Walleij
Date: Thu Jun 28 2018 - 10:15:04 EST


On Mon, Jun 18, 2018 at 4:23 PM Arnd Bergmann <arnd@xxxxxxxx> wrote:

> getnstimeofday64() is deprecated in favor of the ktime_get() family.
>
> The direct replacement would be ktime_get_real_ts64(), but we only need
> the seconds value, and it seems better to use boottime than real time
> to avoid unexpected behavior with a concurrent settimeofday().
>
> ktime_get_seconds() might also work, but it seems better to use
> boottime than monotonic time since I assume that the charging
> process continues during suspend.
>
> Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>

Acked-by: Linus Walleij <linus.walleij@xxxxxxxxxx>

Yours,
Linus Walleij