[PATCH] ARM: head: fix swapper and idmap population with LPAE and big-endian

Marc Zyngier marc.zyngier at arm.com
Mon Feb 25 15:17:02 EST 2013


On 25/02/13 20:08, Rob Herring wrote:
> On 02/25/2013 10:05 AM, Marc Zyngier wrote:
>> On Mon, 25 Feb 2013 15:16:41 +0000, Will Deacon <will.deacon at arm.com>
>> wrote:
>>> The LPAE page table format uses 64-bit descriptors, so we need to take
>>> endianness into account when populating the swapper and idmap tables
>>> during early initialisation.
>>>
>>> This patch ensures that we store the two words making up each page table
>>> entry in the correct order when running big-endian.
>>>
>>> Cc: <stable at vger.kernel.org>
>>> Acked-by: Catalin Marinas <catalin.marinas at arm.com>
>>> Signed-off-by: Will Deacon <will.deacon at arm.com>
>>
>> FWIW, tested as a KVM guest.
> 
> That was a for BE guest on LE host, right? :o

Yep. Actually, a 32bit BE guest on 64bit LE host. Scary, isn't it? ;-)

> Any ideas about much work that would be?

A substantial amount. I have a branch there:
git://git.kernel.org/pub/scm/linux/kernel/git/maz/arm-platforms.git
kvm-arm64/mmio-be

It contains all kind of patches to KVM, virtio and kvmtool. I need to
split things into reviewable bits. And maybe get a life. ;-)

	M.
-- 
Jazz is not dead. It just smells funny...




More information about the linux-arm-kernel mailing list