On Mon, Jan 14, 2013 at 09:08:54PM +0000, Christoffer Dall wrote: > On Mon, Jan 14, 2013 at 10:31 AM, Will Deacon <will.deacon@xxxxxxx> wrote: > > On Tue, Jan 08, 2013 at 06:41:51PM +0000, Christoffer Dall wrote: > >> + case ACCESS_READ_VALUE: > >> + *((u32 *)mmio->data) = (regval >> shift) & mask; > >> + } > >> + } > >> +} > > > > As I mentioned previously, I suspect that this doesn't work with big-endian > > systems. Whilst that's reasonable for the moment, a comment would be useful > > for the unlucky soul that decides to do that work in future (or add > > accessors for mmio->data as I suggested before). > > > admittedly this really hurts my brain, but I think there's actually no > problem with endianness: whatever comes in mmio->data will have native > endianness and the vgic is always little-endian, so a guest would have > to make sure to do its own endianness conversion before writing data, > or did I get this backwards? (some nasty feeling about if the OS is > compiled in another endianness than the hardware everything may > break). No, you're right. As long as the vgic is always little-endian the access will be ok. Sorry for the false alarm, Will -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html