Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm
[linux-2.6-block.git] / arch / arm64 / kvm / hyp / nvhe / hyp-init.S
index 882fd40d068e09eab8ef7428a63ecf56cbf97af3..c631e29fb001b2e3f8d78bfc00506f7f39467fc0 100644 (file)
@@ -18,7 +18,7 @@
 #include <asm/virt.h>
 
        .text
-       .pushsection    .hyp.idmap.text, "ax"
+       .pushsection    .idmap.text, "ax"
 
        .align  11
 
@@ -57,17 +57,10 @@ __do_hyp_init:
        cmp     x0, #HVC_STUB_HCALL_NR
        b.lo    __kvm_handle_stub_hvc
 
-       // We only actively check bits [24:31], and everything
-       // else has to be zero, which we check at build time.
-#if (KVM_HOST_SMCCC_FUNC(__kvm_hyp_init) & 0xFFFFFFFF00FFFFFF)
-#error Unexpected __KVM_HOST_SMCCC_FUNC___kvm_hyp_init value
-#endif
-
-       ror     x0, x0, #24
-       eor     x0, x0, #((KVM_HOST_SMCCC_FUNC(__kvm_hyp_init) >> 24) & 0xF)
-       ror     x0, x0, #4
-       eor     x0, x0, #((KVM_HOST_SMCCC_FUNC(__kvm_hyp_init) >> 28) & 0xF)
-       cbz     x0, 1f
+       mov     x3, #KVM_HOST_SMCCC_FUNC(__kvm_hyp_init)
+       cmp     x0, x3
+       b.eq    1f
+
        mov     x0, #SMCCC_RET_NOT_SUPPORTED
        eret
 
@@ -141,7 +134,6 @@ alternative_else_nop_endif
 
        /* Set the host vector */
        ldr     x0, =__kvm_hyp_host_vector
-       kimg_hyp_va x0, x1
        msr     vbar_el2, x0
 
        ret
@@ -200,7 +192,6 @@ SYM_CODE_START_LOCAL(__kvm_hyp_init_cpu)
        /* Leave idmap. */
        mov     x0, x29
        ldr     x1, =kvm_host_psci_cpu_entry
-       kimg_hyp_va x1, x2
        br      x1
 SYM_CODE_END(__kvm_hyp_init_cpu)