• Dave Hansen's avatar
    x86/selftests/pkeys: Fork() to check for state being preserved · 940343c7
    Dave Hansen authored
    commit e1812933 upstream.
    
    There was a bug where the per-mm pkey state was not being preserved across
    fork() in the child.  fork() is performed in the pkey selftests, but all of
    the pkey activity is performed in the parent.  The child does not perform
    any actions sensitive to pkey state.
    
    To make the test more sensitive to these kinds of bugs, add a fork() where
    the parent exits, and execution continues in the child.
    
    To achieve this let the key exhaustion test not terminate at the first
    allocation failure and fork after 2*NR_PKEYS loops and continue in the
    child.
    Signed-off-by: 's avatarDave Hansen <dave.hansen@linux.intel.com>
    Signed-off-by: 's avatarThomas Gleixner <tglx@linutronix.de>
    Cc: bp@alien8.de
    Cc: hpa@zytor.com
    Cc: peterz@infradead.org
    Cc: mpe@ellerman.id.au
    Cc: will.deacon@arm.com
    Cc: luto@kernel.org
    Cc: jroedel@suse.de
    Cc: stable@vger.kernel.org
    Cc: Borislav Petkov <bp@alien8.de>
    Cc: "H. Peter Anvin" <hpa@zytor.com>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Michael Ellerman <mpe@ellerman.id.au>
    Cc: Will Deacon <will.deacon@arm.com>
    Cc: Andy Lutomirski <luto@kernel.org>
    Cc: Joerg Roedel <jroedel@suse.de>
    Link: https://lkml.kernel.org/r/20190102215657.585704B7@viggo.jf.intel.comSigned-off-by: 's avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
    940343c7
Name
Last commit
Last update
..
accounting Loading commit data...
arch Loading commit data...
bpf Loading commit data...
build Loading commit data...
cgroup Loading commit data...
crypto Loading commit data...
firewire Loading commit data...
gpio Loading commit data...
hv Loading commit data...
iio Loading commit data...
include Loading commit data...
kvm/kvm_stat Loading commit data...
laptop Loading commit data...
leds Loading commit data...
lib Loading commit data...
memory-model Loading commit data...
nfsd Loading commit data...
objtool Loading commit data...
pci Loading commit data...
pcmcia Loading commit data...
perf Loading commit data...
power Loading commit data...
scripts Loading commit data...
spi Loading commit data...
testing Loading commit data...
thermal/tmon Loading commit data...
time Loading commit data...
usb Loading commit data...
virtio Loading commit data...
vm Loading commit data...
wmi Loading commit data...
Makefile Loading commit data...