From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B51BB19E96D for ; Thu, 19 Dec 2024 17:11:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734628295; cv=none; b=a8/LohxcWK+vMH3AvsmKBPLyzss3uI+eDJZIoeR/AuDfsDEEkZZ1b5ZH5/rAi5MdXo6pSNMuI1dD/ZAPegnWEQb0lJJ3prHlGM6UWjb241kKSY/MQ8IrOA+eHGpJOYKsIZL4C2uCk9Qa9dieuTfdaFVu6bM75oKXmMqRR1GPlSs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734628295; c=relaxed/simple; bh=zSAk4gJKXUo3cdNuOkGvkqa0l5ek5qLzATtOpSwDR1o=; h=Date:Message-ID:From:To:Cc:Subject:In-Reply-To:References: MIME-Version:Content-Type; b=McE/z20eKRqJy9MS+hdIVnX5KsI3gwLwKrVeZyS6TA5jtHERPlD0p+TdUmI5l9OomMcowuoxo4dtxsfHOvblljQdsOgRK7u7Tb3LtDiSdyJbjr8Pc5MgNZLGiKcwJ2DZZxDK5lAdtKb81Yidx0tSnAWx80r9nwcjGvBH4uKv8IM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=NYlHK909; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="NYlHK909" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4B8A8C4CECE; Thu, 19 Dec 2024 17:11:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1734628294; bh=zSAk4gJKXUo3cdNuOkGvkqa0l5ek5qLzATtOpSwDR1o=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=NYlHK909W6Pq0viZhsS7wsad706j6bJC8E2wrMos9vNYu/v1j715/vj7PWyD5JnxB JAhdpbFHlxZrx0PMWyWdDKCKQzJyRS8T30KF7MDMvjq6pDIZfIY1UQVFVoZ283lvqW Pb77X/OX9delrXySoU/gHGcInp+6dOGF31gj8s3HZ911J/QtarWv48l0N8OcRxJz8k 5dml4zTuL7F4W3YArXn4/6da5OqfMZrhA8r16KlU9zYA7iU289YX94s8Btz5tn3PM8 DlndN/+G0syiGESchxMmZCueLsQ+YzDGQxZRuvmD1wVZk2WNpeY+Q+gcROfFbFo3J+ nqt5FTjNeZE3A== Received: from sofa.misterjones.org ([185.219.108.64] helo=goblin-girl.misterjones.org) by disco-boy.misterjones.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.95) (envelope-from ) id 1tOK3f-005L6o-PN; Thu, 19 Dec 2024 17:11:31 +0000 Date: Thu, 19 Dec 2024 17:11:31 +0000 Message-ID: <86y10bpph8.wl-maz@kernel.org> From: Marc Zyngier To: Ard Biesheuvel Cc: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Ard Biesheuvel , Catalin Marinas , Will Deacon , Mark Rutland , Ryan Roberts , Anshuman Khandual , Kees Cook , Quentin Perret Subject: Re: [PATCH v3 0/6] arm64: Clean up and simplify PA space size handling In-Reply-To: <20241212081841.2168124-8-ardb+git@google.com> References: <20241212081841.2168124-8-ardb+git@google.com> User-Agent: Wanderlust/2.15.9 (Almost Unreal) SEMI-EPG/1.14.7 (Harue) FLIM-LB/1.14.9 (=?UTF-8?B?R29qxY0=?=) APEL-LB/10.8 EasyPG/1.0.0 Emacs/29.4 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 (generated by SEMI-EPG 1.14.7 - "Harue") Content-Type: text/plain; charset=US-ASCII X-SA-Exim-Connect-IP: 185.219.108.64 X-SA-Exim-Rcpt-To: ardb+git@google.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, ardb@kernel.org, catalin.marinas@arm.com, will@kernel.org, mark.rutland@arm.com, ryan.roberts@arm.com, anshuman.khandual@arm.com, keescook@chromium.org, qperret@google.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false On Thu, 12 Dec 2024 08:18:42 +0000, Ard Biesheuvel wrote: > > From: Ard Biesheuvel > > This series addresses a number of buglets related to how we handle the > size of the physical address space when building LPA2 capable kernels: > > - reject 52-bit physical addressess in the mapping routines when LPA2 is > configured but not available at runtime > - ensure that TCR.IPS is not set to 52-bits if LPA2 is not supported > - ensure that TCR_EL2.PS and DS match the host, regardless of whether > LPA2 is available at stage 2 > - don't rely on kvm_get_parange() and invalid physical addresses as > control flags in the pKVM page donation APIs > > Finally, the configurable 48-bit physical address space limit is dropped > entirely, as it doesn't buy us a lot now that all the PARange and {I}PS > handling is done at runtime. Acked-by: Marc Zyngier M. -- Without deviation from the norm, progress is not possible.