summaryrefslogtreecommitdiff
path: root/arch/x86
diff options
context:
space:
mode:
authorDave Hansen <dave.hansen@linux.intel.com>2019-01-03 00:56:57 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2019-01-31 10:13:46 +0300
commitce20aba74c69084c1f87725b68a507735733c798 (patch)
treeed807c5b48c27bc8e6dd326a650657beb3ee2a97 /arch/x86
parent92296f7ddac6c3bfee6fb952b6f776291ef4df48 (diff)
downloadlinux-ce20aba74c69084c1f87725b68a507735733c798.tar.xz
x86/selftests/pkeys: Fork() to check for state being preserved
commit e1812933b17be7814f51b6c310c5d1ced7a9a5f5 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: Dave Hansen <dave.hansen@linux.intel.com> Signed-off-by: Thomas 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.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'arch/x86')
0 files changed, 0 insertions, 0 deletions