[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4196e42f-7b04-44a7-ac34-6ca2e9190c21@redhat.com>
Date: Thu, 27 Feb 2025 15:43:09 -0500
From: Luiz Capitulino <luizcap@...hat.com>
To: Will Deacon <will@...nel.org>, Catalin Marinas <catalin.marinas@....com>,
Mark Rutland <mark.rutland@....com>, Ard Biesheuvel <ardb@...nel.org>,
Ryan Roberts <ryan.roberts@....com>
Cc: kernel-team@...roid.com, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1] arm64/mm: Fix Boot panic on Ampere Altra
On 2025-02-27 13:50, Will Deacon wrote:
> On Tue, 25 Feb 2025 11:46:36 +0000, Ryan Roberts wrote:
>> When the range of present physical memory is sufficiently small enough
>> and the reserved address space for the linear map is sufficiently large
>> enough, The linear map base address is randomized in
>> arm64_memblock_init().
>>
>> Prior to commit 62cffa496aac ("arm64/mm: Override PARange for !LPA2 and
>> use it consistently"), we decided if the sizes were suitable with the
>> help of the raw mmfr0.parange. But the commit changed this to use the
>> sanitized version instead. But the function runs before the register has
>> been sanitized so this returns 0, interpreted as a parange of 32 bits.
>> Some fun wrapping occurs and the logic concludes that there is enough
>> room to randomize the linear map base address, when really there isn't.
>> So the top of the linear map ends up outside the reserved address space.
>>
>> [...]
>
> Applied the reduced version to arm64 (for-next/fixes), thanks!
>
> [1/1] arm64/mm: Fix Boot panic on Ampere Altra
> https://git.kernel.org/arm64/c/2b1283e1ea9b
Just in case:
Tested-by: Luiz Capitulino <luizcap@...hat.com>
Powered by blists - more mailing lists