linux-stable/arch
Jason A. Donenfeld 227221a9c9 xtensa: use fallback for random_get_entropy() instead of zero
commit e10e2f5803 upstream.

In the event that random_get_entropy() can't access a cycle counter or
similar, falling back to returning 0 is really not the best we can do.
Instead, at least calling random_get_entropy_fallback() would be
preferable, because that always needs to return _something_, even
falling back to jiffies eventually. It's not as though
random_get_entropy_fallback() is super high precision or guaranteed to
be entropic, but basically anything that's not zero all the time is
better than returning zero all the time.

This is accomplished by just including the asm-generic code like on
other architectures, which means we can get rid of the empty stub
function here.

Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Arnd Bergmann <arnd@arndb.de>
Acked-by: Max Filippov <jcmvbkbc@gmail.com>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-05-30 09:27:15 +02:00
..
alpha alpha: define get_cycles macro for arch-override 2022-05-30 09:27:13 +02:00
arc ARC: entry: fix syscall_trace_exit argument 2022-04-27 14:41:15 +02:00
arm arm: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:14 +02:00
arm64 arm64: Enable repeat tlbi workaround on KRYO4XX gold CPUs 2022-05-25 09:59:15 +02:00
csky uaccess: fix type mismatch warnings from access_ok() 2022-04-08 13:58:44 +02:00
h8300 bitmap patches for 5.17-rc1 2022-01-23 06:20:44 +02:00
hexagon uaccess: fix integer overflow on access_ok() 2022-03-28 10:03:21 +02:00
ia64 ia64: define get_cycles macro for arch-override 2022-05-30 09:27:13 +02:00
m68k m68k: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:14 +02:00
microblaze uaccess: fix nios2 and microblaze get_user_8() 2022-04-08 13:57:49 +02:00
mips mips: use fallback for random_get_entropy() instead of just c0 random 2022-05-30 09:27:14 +02:00
nds32 nds32: fix access_ok() checks in get/put_user 2022-03-28 10:03:22 +02:00
nios2 nios2: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:14 +02:00
openrisc bitmap patches for 5.17-rc1 2022-01-23 06:20:44 +02:00
parisc parisc: define get_cycles macro for arch-override 2022-05-30 09:27:13 +02:00
powerpc powerpc: define get_cycles macro for arch-override 2022-05-30 09:27:13 +02:00
riscv riscv: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:14 +02:00
s390 s390: define get_cycles macro for arch-override 2022-05-30 09:27:13 +02:00
sh bitmap patches for 5.17-rc1 2022-01-23 06:20:44 +02:00
sparc sparc: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:15 +02:00
um um: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:14 +02:00
x86 x86/tsc: Use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:14 +02:00
xtensa xtensa: use fallback for random_get_entropy() instead of zero 2022-05-30 09:27:15 +02:00
.gitignore
Kconfig stack: Constrain and fix stack offset randomization with Clang builds 2022-04-08 13:57:34 +02:00