lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Y1w9Hqh4YZFUIp2z@arm.com>
Date:   Fri, 28 Oct 2022 21:35:42 +0100
From:   Catalin Marinas <catalin.marinas@....com>
To:     Zenghui Yu <yuzenghui@...wei.com>
Cc:     Anders Roxell <anders.roxell@...aro.org>,
        Anshuman Khandual <anshuman.khandual@....com>,
        linux-arm-kernel@...ts.infradead.org,
        James Morse <james.morse@....com>,
        Will Deacon <will@...nel.org>, Marc Zyngier <maz@...nel.org>,
        Suzuki K Poulose <suzuki.poulose@....com>,
        Ard Biesheuvel <ardb@...nel.org>,
        Mark Rutland <mark.rutland@....com>,
        kvmarm@...ts.cs.columbia.edu, linux-efi@...r.kernel.org,
        linux-kernel@...r.kernel.org, alex.bennee@...aro.org, arnd@...db.de
Subject: Re: [PATCH V2] arm64/mm: Fix __enable_mmu() for new TGRAN range
 values

On Fri, Oct 28, 2022 at 10:18:41AM +0800, Zenghui Yu wrote:
> On 2022/8/26 20:00, Anders Roxell wrote:
> > On 2021-03-10 11:23, Anshuman Khandual wrote:
> > > From: James Morse <james.morse@....com>
> > > 
> > > As per ARM ARM DDI 0487G.a, when FEAT_LPA2 is implemented, ID_AA64MMFR0_EL1
> > > might contain a range of values to describe supported translation granules
> > > (4K and 16K pages sizes in particular) instead of just enabled or disabled
> > > values. This changes __enable_mmu() function to handle complete acceptable
> > > range of values (depending on whether the field is signed or unsigned) now
> > > represented with ID_AA64MMFR0_TGRAN_SUPPORTED_[MIN..MAX] pair. While here,
> > > also fix similar situations in EFI stub and KVM as well.
> > > 
> > > Cc: Catalin Marinas <catalin.marinas@....com>
> > > Cc: Will Deacon <will@...nel.org>
> > > Cc: Marc Zyngier <maz@...nel.org>
> > > Cc: James Morse <james.morse@....com>
> > > Cc: Suzuki K Poulose <suzuki.poulose@....com>
> > > Cc: Ard Biesheuvel <ardb@...nel.org>
> > > Cc: Mark Rutland <mark.rutland@....com>
> > > Cc: linux-arm-kernel@...ts.infradead.org
> > > Cc: kvmarm@...ts.cs.columbia.edu
> > > Cc: linux-efi@...r.kernel.org
> > > Cc: linux-kernel@...r.kernel.org
> > > Acked-by: Marc Zyngier <maz@...nel.org>
> > > Signed-off-by: James Morse <james.morse@....com>
> > > Signed-off-by: Anshuman Khandual <anshuman.khandual@....com>
> > 
> > When building an arm64 defconfig kernel from stable/linux-5.10.y and
> > booting that in QEMU (version: 1:7.0+dfsg-2~bpo11+2) with '-cpu max' the
> > kernel doesn't boot. I don't get any output.  The kernel boots fine if I
> > change to '-cpu cortex-a72'.
> > 
> > If I cherry-pick this patch to stable/linux-5.10.y I'm able too boot the
> > kernel with '-cpu max'.
> 
> You can workaround the kernel boot failure by specifying
> '-cpu max,lpa2=off' [*] in the QEMU command line.
> 
> > However, I'm not comfortable to backport this patch to older kernels
> > since there are a lot of conflicts.
> > Can someone help out to do the packport?
> 
> Upstream commit 26f55386f964 ("arm64/mm: Fix __enable_mmu() for new
> TGRAN range values") can still be applied cleanly on top of
> linux-5.10.y. I can send it to <stable@...r.kernel.org> if maintainers
> are okay with the stable-5.10 backport.

If you have a backport, please send it (and cc the original
author/reviewers just to double-check that the backport is correct).

Thanks.

-- 
Catalin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ