• Dave Martin's avatar
    arm64: Correct ARM64_CORE_REG() size encodings for all core registers · 5ae841d1
    Dave Martin authored
    ARM64_CORE_REG() is currently only used to generate the KVM
    register IDs for registers that happen to be 64 bits in size, so
    KVM_REG_SIZE_U64 is hard-coded in the definition.
    To enable this macro to generate correct encodings for the FPSIMD
    registers too (which are a mix of 128-bit and 32-bit registers),
    this patch extends the macro to encode the correct size for each
    class of register in KVM_REG_ARM_CORE.
    The approach is crude, but because the KVM_REG_ARM_CORE ID
    arrangement is ABI, it's not expected to evolve.
    Signed-off-by: default avatarDave Martin <Dave.Martin@arm.com>
    Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
kvm-cpu.c 6.33 KB