mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-28 11:18:45 +07:00
0e27d27e0d
Returning a negative value for a boolean function seem to have the undesired effect of returning true. require_paranoia_below() is a boolean function, but the variable used to store the return value is an integer, receiving -1 or 0. This patch converts rc to bool, replaces -1 by false, and 0 by true. mpe: This wasn't exhibiting in practice because the common case, where we do the comparison of the desired level vs the current value, was being compiled into a computation based on the result of the comparison, ie. it wasn't using the default -1 value at all. However that was just luck and the code is still wrong. Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com> Signed-off-by: Andrew Shadura <andrew.shadura@collabora.co.uk> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> |
||
---|---|---|
.. | ||
breakpoints | ||
capabilities | ||
cpu-hotplug | ||
efivarfs | ||
exec | ||
filesystems | ||
firmware | ||
ftrace | ||
futex | ||
ia64 | ||
intel_pstate | ||
ipc | ||
kcmp | ||
lib | ||
media_tests | ||
membarrier | ||
memfd | ||
memory-hotplug | ||
mount | ||
mqueue | ||
net | ||
networking/timestamping | ||
nsfs | ||
ntb | ||
powerpc | ||
prctl | ||
pstore | ||
ptp | ||
ptrace | ||
rcutorture | ||
seccomp | ||
sigaltstack | ||
size | ||
static_keys | ||
sysctl | ||
timers | ||
user | ||
vDSO | ||
vm | ||
watchdog | ||
x86 | ||
zram | ||
gen_kselftest_tar.sh | ||
kselftest_install.sh | ||
kselftest.h | ||
lib.mk | ||
Makefile |