root/arch/arm/kvm/hyp/s2-setup.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. __init_stage2_translation

   1 // SPDX-License-Identifier: GPL-2.0-only
   2 /*
   3  * Copyright (C) 2016 - ARM Ltd
   4  * Author: Marc Zyngier <marc.zyngier@arm.com>
   5  */
   6 
   7 #include <linux/types.h>
   8 #include <asm/kvm_arm.h>
   9 #include <asm/kvm_asm.h>
  10 #include <asm/kvm_hyp.h>
  11 
  12 void __hyp_text __init_stage2_translation(void)
  13 {
  14         u64 val;
  15 
  16         val = read_sysreg(VTCR) & ~VTCR_MASK;
  17 
  18         val |= read_sysreg(HTCR) & VTCR_HTCR_SH;
  19         val |= KVM_VTCR_SL0 | KVM_VTCR_T0SZ | KVM_VTCR_S;
  20 
  21         write_sysreg(val, VTCR);
  22 }

/* [<][>][^][v][top][bottom][index][help] */