Re: kvm oops vgic_v2_sync_lr_elrsr

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 23 September 2014 08:52, Christoffer Dall
<christoffer.dall@xxxxxxxxxx> wrote: > Assuming we don't have some
> ridiculous bug in KVM reporting the incorrect codes

Funny you should suggest that :-)

The ARM ARM says DFSC is ESR_ELx [5:0]. However we have
#define ESR_EL2_FSC_TYPE       (0x3c)

static inline u8 kvm_vcpu_trap_get_fault(const struct kvm_vcpu *vcpu)
{
        return kvm_vcpu_get_hsr(vcpu) & ESR_EL2_FSC_TYPE;
}

which throws away the lower 2 bits (because they mostly
indicate the translation level of of the fault), and
we're reporting the result of that function in the
error message rather than the full DFSC.

I would suggest:
(1) renaming the function above so it's a bit clearer
it doesn't get you the full DFSC
(2) reporting the full DFSC rather than the truncated
version in the error message

Anyway, now we know the DFSC is actually 0b1000xx we
can make a good guess that it's "100001: Alignment fault".
What in the guest is trying to do unaligned device
accesses? (I think the case we're hitting here is
"unaligned accesses generate Alignment faults at
the first level of translation that defines the location
as being Device" plus 1st stage defining it as normal
and 2nd stage defining it as device, because I think
all other kinds of alignment fault will go to EL1
rather than EL2. But maybe I missed one...)

-- PMM
_______________________________________________
kvmarm mailing list
kvmarm@xxxxxxxxxxxxxxxxxxxxx
https://lists.cs.columbia.edu/mailman/listinfo/kvmarm




[Index of Archives]     [Linux KVM]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux