android_kernel_motorola_sm6375/arch/mips
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jason A. Donenfeld 6fa912f987 mips: use fallback for random_get_entropy() instead of just c0 random
commit 1c99c6a7c3c599a68321b01b9ec243215ede5a68 upstream.

For situations in which we don't have a c0 counter register available,
we've been falling back to reading the c0 "random" register, which is
usually bounded by the amount of TLB entries and changes every other
cycle or so. This means it wraps extremely often. We can do better by
combining this fast-changing counter with a potentially slower-changing
counter from random_get_entropy_fallback() in the more significant bits.
This commit combines the two, taking into account that the changing bits
are in a different bit position depending on the CPU model. In addition,
we previously were falling back to 0 for ancient CPUs that Linux does
not support anyway; remove that dead path entirely.

Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Arnd Bergmann <arnd@arndb.de>
Tested-by: Maciej W. Rozycki <macro@orcam.me.uk>
Acked-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-06-22 14:11:15 +02:00
..
alchemy
ar7
ath25
ath79
bcm47xx
bcm63xx mips: bcm63xx: add support for clk_set_parent() 2022-01-27 09:19:40 +01:00
bmips MIPS: Use address-of operator on section symbols 2022-05-15 19:54:46 +02:00
boot
cavium-octeon MIPS: OCTEON: add put_device() after of_find_device_by_node() 2022-01-27 09:19:48 +01:00
cobalt
configs
crypto
dec mips: DEC: honor CONFIG_MIPS_FP_SUPPORT=n 2022-04-15 14:18:15 +02:00
emma
fw
generic MIPS: generic/yamon-dt: fix uninitialized variable error 2021-11-26 10:47:19 +01:00
include mips: use fallback for random_get_entropy() instead of just c0 random 2022-06-22 14:11:15 +02:00
jazz
jz4740 MIPS: fix build with gcc-12 2022-05-18 09:47:28 +02:00
kernel mips: cpc: Fix refcount leak in mips_cpc_default_phys_base 2022-06-14 18:11:56 +02:00
kvm
lantiq MIPS: lantiq: check the return value of kzalloc() 2022-05-25 09:14:32 +02:00
lasat
lib
loongson32
loongson64
math-emu
mm
mti-malta
net
netlogic
oprofile
paravirt
pci
pic32 MIPS: Use address-of operator on section symbols 2022-05-15 19:54:46 +02:00
pistachio
pmcs-msp71xx
pnx833x
power
ralink MIPS: Use address-of operator on section symbols 2022-05-15 19:54:46 +02:00
rb532 MIPS: RB532: fix return value of __setup handler 2022-04-15 14:18:16 +02:00
sgi-ip22
sgi-ip27
sgi-ip32
sibyte
sni MIPS: sni: Fix the build 2021-11-26 10:47:16 +01:00
tools
txx9
vdso
vr41xx
Kbuild
Kbuild.platforms
Kconfig MIPS: use 3-level pgtable for 64KB page size on MIPS_VA_BITS_48 2021-12-01 09:23:33 +01:00
Kconfig.debug
Makefile
Makefile.postlink