tmp_suning_uos_patched/arch/riscv
Jason A. Donenfeld 714def4497 riscv: use fallback for random_get_entropy() instead of zero
commit 6d01238623faa9425f820353d2066baf6c9dc872 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.

Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Paul Walmsley <paul.walmsley@sifive.com>
Acked-by: Palmer Dabbelt <palmer@rivosinc.com>
Reviewed-by: Palmer Dabbelt <palmer@rivosinc.com>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-05-30 09:33:41 +02:00
..
boot riscv: dts: sifive: fu540-c000: align dma node name with dtschema 2022-05-25 09:17:59 +02:00
configs riscv: defconfig: enable gpio support for HiFive Unleashed 2021-01-27 11:55:01 +01:00
include riscv: use fallback for random_get_entropy() instead of zero 2022-05-30 09:33:41 +02:00
kernel riscv: patch_text: Fixup last cpu should be master 2022-05-09 09:04:59 +02:00
lib
mm riscv: Fix config KASAN && DEBUG_VIRTUAL 2022-03-08 19:09:31 +01:00
net riscv, bpf: Fix potential NULL dereference 2021-11-02 19:48:21 +01:00
Kbuild
Kconfig riscv: Fix asan-stack clang build 2021-11-02 19:48:25 +01:00
Kconfig.debug
Kconfig.socs
Makefile riscv: fix build with binutils 2.38 2022-02-16 12:54:21 +01:00