From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 533FFC43334 for ; Fri, 24 Jun 2022 13:21:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=XVNLI2qMuBSVoKsevaeQvavRU17Cn3s+6FvJMxEAtbo=; b=pTEt8NEwOqxV9j etbO6dpD5GwaUhIwtj/UUFqSx0b/jLpd8NWR2St4UdPJ6rj14ji+rkBP0Ds78YISa9++lSmlb2KeQ FZC866OSdEp4+I4D35z37HY2St1kO1ghG6IxO3O9aQS8qB00UFQjPQC7UjxlSRpSvIoigaba3feWq HhKxQycSpfX6PzjxUGLiC/hi6kPcA6890hDQwbdrgcboWywn4mZ6UNA6nBFlKMHDGSd2bAcZruxey kqDTdoVqyIzOyG1j4uu9KTyvIn/aLyvQZNmjRCj2iRzxcg9293Up0xFXsOiuYg/DBjNVFehI46Dwv a5GW3JPwvObeYtBgzH2g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o4jEH-002N9P-8e; Fri, 24 Jun 2022 13:20:09 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o4jED-002N7u-Ur for linux-arm-kernel@lists.infradead.org; Fri, 24 Jun 2022 13:20:07 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id B98E061F02; Fri, 24 Jun 2022 13:20:04 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id CEB15C34114; Fri, 24 Jun 2022 13:20:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1656076804; bh=MEsGlL3F/sq2A1ko6y914k6bF1dtF6Taeh6a52h3eGo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=KQ0v4jB7KIwa4tTa6Y4LQuGR6c4qitZwAb2uGtoyV+rkOITdv3b6lFk4ZwL1w+Ij6 vwWj90o479WkG57ikwruokqIO7SaNf46e9wis3D3nKq1C6V3RLCyZcz3M1H5gOl5VC Kr9cFtpZ6adWGb0dUN900PbRREHOXo3CXTwn+3YnZoPP5UtdCP0rY6Ov73uDbnAdEy dvUR+781V776D8yiE5tmmHRhgMh4tUw/YU8jyH0QT+Uhr6mSRhRI0CHSq/GRdil3n3 CCATtxsUXbTqi6JRkdVuFN5TRuMSocfiStiEklBucw3rdmHTN6wYJM41sk4FBa/VR5 R4dpT9M9rG9dw== Date: Fri, 24 Jun 2022 14:19:59 +0100 From: Will Deacon To: Ard Biesheuvel Cc: linux-arm-kernel@lists.infradead.org, linux-hardening@vger.kernel.org, Marc Zyngier , Mark Rutland , Kees Cook , Catalin Marinas , Mark Brown , Anshuman Khandual Subject: Re: [PATCH v4 00/26] arm64: refactor boot flow and add support for WXN Message-ID: <20220624131958.GG18561@willie-the-truck> References: <20220613144550.3760857-1-ardb@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220613144550.3760857-1-ardb@kernel.org> User-Agent: Mutt/1.10.1 (2018-07-13) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220624_062006_075060_85858134 X-CRM114-Status: GOOD ( 21.33 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hi Ard, On Mon, Jun 13, 2022 at 04:45:24PM +0200, Ard Biesheuvel wrote: > [ TL;DR this series does the following: > - move variable definitions and assignments out of early asm code > where possible, and get rid of explicit cache maintenance; > - convert initial ID map so it covers the entire loaded image as well > as the DT blob; > - create the kernel mapping only once instead of twice (for KASLR), > and do it with the MMU and caches on; > - avoid mappings that are both writable and executable entirely; > - avoid parsing the DT while the kernel text and rodata are still > mapped writable; > - allow WXN to be enabled (with an opt-out) so writable mappings are > never executable. ] I really like this series -- it removes quite a few ugly warts from our boot assembly that we've collected over the years and, while functional, they have never been particularly satisfactory. Thank you for putting it together. I've left a handful of minor comments on some of the patches and if you can address those then I'd like to queue the first 21 patches ASAP to give them some more exposure before the next merge window. The remaining patches are the WXN pieces, which I'd like to give others a chance to chime in on first. Cheers, Will _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel