[PATCH] arm/arm64: KVM: Fix hyp mappings of vmalloc regions
Christoffer Dall
christoffer.dall at linaro.org
Sat Nov 16 20:26:45 EST 2013
On 16 November 2013 15:30, Santosh Shilimkar <santosh.shilimkar at ti.com> wrote:
> On Saturday 16 November 2013 12:15 PM, Christoffer Dall wrote:
>> On Sat, Nov 16, 2013 at 10:01:01AM +0000, Marc Zyngier wrote:
>>> On 2013-11-15 23:24, Christoffer Dall wrote:
>>>> Using virt_to_phys on percpu mappings is horribly wrong as it may be
>>>> backed by vmalloc. Introduce kvm_kaddr_to_phys which translates both
>>>> types of valid kernel addresses to the corresponding physical
>>>> address.
>>>>
>>>> At the same time resolves a typing issue where we were storing the
>>>> physical address as a 32 bit unsigned long (on arm), truncating the
>>>> physical address for addresses above the 4GB limit. This caused
>>>> breakage on Keystone.
>>>>
>>>> Reported-by: Santosh Shilimkar <santosh.shilimkar at ti.com>
>>>> Signed-off-by: Marc Zyngier <marc.zyngier at arm.com>
>>>> Signed-off-by: Christoffer Dall <christoffer.dall at linaro.org>
>>>> ---
>>>>
>>>> This patch is loosely based on Marc's previous patch from today but
>>>> instead of introducing another Hyp mapping function, it fixes the
>>>> existing one to deal with both kinds of kernel addresses.
>>>
>>> Looks good to me! This should probably be merged quickly (after
>>> testing by Santosh), and possibly Cc-ed to stable.
>>>
>> Agreed, Santhos, can you give this a quick spin?
>>
> Works as expected.
>
great, I'll merge the patch. Thanks for testing it.
-Christoffer
More information about the linux-arm-kernel
mailing list