]> git.baikalelectronics.ru Git - kernel.git/commit
KVM guest: Make pv trampoline code executable
authorAlexander Graf <agraf@suse.de>
Tue, 29 Apr 2014 10:17:26 +0000 (12:17 +0200)
committerAlexander Graf <agraf@suse.de>
Tue, 29 Apr 2014 10:36:09 +0000 (12:36 +0200)
commitd1e48c12ff8137b5bf612d85feee848bf82846f8
tree0bc2511f1c513a919904016a0665949107f36c40
parent30344f699d10e3c05fb17896abd3c00c12453e90
KVM guest: Make pv trampoline code executable

Our PV guest patching code assembles chunks of instructions on the fly when it
encounters more complicated instructions to hijack. These instructions need
to live in a section that we don't mark as non-executable, as otherwise we
fault when jumping there.

Right now we put it into the .bss section where it automatically gets marked
as non-executable. Add a check to the NX setting function to ensure that we
leave these particular pages executable.

Signed-off-by: Alexander Graf <agraf@suse.de>
arch/powerpc/include/asm/sections.h
arch/powerpc/kernel/kvm.c
arch/powerpc/mm/hash_utils_64.c