random: use proper jiffies comparison macro

commit 8a5b8a4a4c upstream.

This expands to exactly the same code that it replaces, but makes things
consistent by using the same macro for jiffy comparisons throughout.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Jason A. Donenfeld 2022-05-10 15:20:42 +02:00 коммит произвёл Greg Kroah-Hartman
Родитель 8df752b82e
Коммит ac0172992c
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -326,7 +326,7 @@ static bool crng_has_old_seed(void)
interval = max_t(unsigned int, CRNG_RESEED_START_INTERVAL,
(unsigned int)uptime / 2 * HZ);
}
return time_after(jiffies, READ_ONCE(base_crng.birth) + interval);
return time_is_before_jiffies(READ_ONCE(base_crng.birth) + interval);
}
/*