Skip to content

Commit ad361ed

Browse files
willdeaconoupton
authored andcommitted
KVM: arm64: Just advertise SEIS as 0 when emulating ICC_CTLR_EL1
ICC_CTLR_EL1 accesses from a guest are trapped and emulated on systems with broken SEIS support and without FEAT_GICv3_TDIR. On such systems, we mask SEIS support in 'kvm_vgic_global_state.ich_vtr_el2' and so the value of ICC_CTLR_EL1.SEIS visible to the guest is always zero. Simplify the ICC_CTLR_EL1 read emulation to return 0 for the SEIS field, rather than reading an always-zero value from the global state. Cc: Marc Zyngier <[email protected]> Cc: Oliver Upton <[email protected]> Signed-off-by: Will Deacon <[email protected]> Reviewed-by: Marc Zyngier <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Oliver Upton <[email protected]>
1 parent 8e929cb commit ad361ed

File tree

1 file changed

+0
-3
lines changed

1 file changed

+0
-3
lines changed

arch/arm64/kvm/hyp/vgic-v3-sr.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1012,9 +1012,6 @@ static void __vgic_v3_read_ctlr(struct kvm_vcpu *vcpu, u32 vmcr, int rt)
10121012
val = ((vtr >> 29) & 7) << ICC_CTLR_EL1_PRI_BITS_SHIFT;
10131013
/* IDbits */
10141014
val |= ((vtr >> 23) & 7) << ICC_CTLR_EL1_ID_BITS_SHIFT;
1015-
/* SEIS */
1016-
if (kvm_vgic_global_state.ich_vtr_el2 & ICH_VTR_SEIS_MASK)
1017-
val |= BIT(ICC_CTLR_EL1_SEIS_SHIFT);
10181015
/* A3V */
10191016
val |= ((vtr >> 21) & 1) << ICC_CTLR_EL1_A3V_SHIFT;
10201017
/* EOImode */

0 commit comments

Comments
 (0)