Skip to content

Commit

Permalink
KVM: PPC: Move KVM trampolines before __end_interrupts
Browse files Browse the repository at this point in the history
When using a relocatable kernel we need to make sure that the trampline code
and the interrupt handlers are both copied to low memory. The only way to do
this reliably is to put them in the copied section.

This patch should make relocated kernels work with KVM.

KVM-Stable-Tag
Signed-off-by: Alexander Graf <agraf@suse.de>
Signed-off-by: Avi Kivity <avi@redhat.com>
  • Loading branch information
Alexander Graf authored and Avi Kivity committed Oct 24, 2010
1 parent 2b05d71 commit a58ddea
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 6 additions & 0 deletions arch/powerpc/kernel/exceptions-64s.S
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,12 @@ slb_miss_user_pseries:
b . /* prevent spec. execution */
#endif /* __DISABLED__ */

/* KVM's trampoline code needs to be close to the interrupt handlers */

#ifdef CONFIG_KVM_BOOK3S_64_HANDLER
#include "../kvm/book3s_rmhandlers.S"
#endif

.align 7
.globl __end_interrupts
__end_interrupts:
Expand Down
6 changes: 0 additions & 6 deletions arch/powerpc/kernel/head_64.S
Original file line number Diff line number Diff line change
Expand Up @@ -166,12 +166,6 @@ exception_marker:
#include "exceptions-64s.S"
#endif

/* KVM trampoline code needs to be close to the interrupt handlers */

#ifdef CONFIG_KVM_BOOK3S_64_HANDLER
#include "../kvm/book3s_rmhandlers.S"
#endif

_GLOBAL(generic_secondary_thread_init)
mr r24,r3

Expand Down

0 comments on commit a58ddea

Please sign in to comment.