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 E513EC3DA64 for ; Tue, 6 Aug 2024 07:58:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Type:MIME-Version: References:In-Reply-To:Subject:Cc:To:From:Message-ID:Date:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=b0BUSTwdQ0U8sef887Wt7vYj84cSK0ZYj1fIMtHK05s=; b=unhZSv3bcm46paf2fQeLHM/Vdc maqx94MB4PgXuI+b19gjjQqsg1yzCqFk0Zm/BaB5ncVpjul2NLIPiH0ZdMEGGskKcNYxFIsBXzzp5 RL3psTjOMmSXrscCsgIA8lLftJo5XYbooHntmP/y7cCo99D7aInSzi8TDs2xxptEiNwE9Aw6w+uV7 fJAHEcSfeWYhOiA7UBCAD1rVZTz6Ft7NIvz1KOXKQfEpGpkDFpwJp3bcAmEmid1k/5SO02D8lZtuT HxgHYi0YXXDoGrvNMsXZpWmo5FgqJTzsG8NaGl5IfB68uU3dWSZLAhYCc5+CS+DCgRB1s4hvLWWiS jdISHYEQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sbF4k-00000000rHz-20TQ; Tue, 06 Aug 2024 07:57:46 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sbF4E-00000000rEa-0kGj for linux-arm-kernel@lists.infradead.org; Tue, 06 Aug 2024 07:57:15 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by dfw.source.kernel.org (Postfix) with ESMTP id E774760EDE; Tue, 6 Aug 2024 07:57:11 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9172EC32786; Tue, 6 Aug 2024 07:57:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1722931031; bh=4YJj2gsxj+8UTQSPNPDtfIQRagEP8mjqnnwJSG8Ot8c=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=nUpB0BEQgjcZCoyy9GFcPMSczmNxSwyrriq+5rSaPJB0PQZdNP0lNeXuf7uw7Xtrr IV5B+j9DIlIz/auKWAtQub7c8S5z473hiXBMZcWtL124t8HNRK2tSNwg3KIPLyR9SR Hl0CcGNP45d3s0AZSn1kz8Yp/UoluodlQ8q8bm+ITqZyx2VsU7ssBtuxck+e9/Umaa U/shFjx6rE6ByyzVmfqkejoleWRDcO17yje9o3kcKsPdgFK+c0G2tMEdBBWFwZSqhm TB4b4RmdNDwCnXWnTv5bb4ovZzca2PbDlSuP9FBdPMMVraEiJGIjhn6XHYDMJ+zogc TtJKl0rgJQ1LA== 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 1sbF49-001I6U-8I; Tue, 06 Aug 2024 08:57:09 +0100 Date: Tue, 06 Aug 2024 08:57:01 +0100 Message-ID: <86le1a2ieq.wl-maz@kernel.org> From: Marc Zyngier To: Yicong Yang Cc: , , , , , , , , , , , , , Subject: Re: [PATCH 1/2] arm64: Add support for FEAT_HAFT In-Reply-To: References: <20240802093458.32683-1-yangyicong@huawei.com> <20240802093458.32683-2-yangyicong@huawei.com> <86ed771a98.wl-maz@kernel.org> 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.3 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) 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: yangyicong@huawei.com, yangyicong@hisilicon.com, catalin.marinas@arm.com, will@kernel.org, mark.rutland@arm.com, linux-arm-kernel@lists.infradead.org, oliver.upton@linux.dev, broonie@kernel.org, ryan.roberts@arm.com, linuxarm@huawei.com, jonathan.cameron@huawei.com, shameerali.kolothum.thodi@huawei.com, prime.zeng@hisilicon.com, xuwei5@huawei.com, wangkefeng.wang@huawei.com X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240806_005714_369708_6981AB49 X-CRM114-Status: GOOD ( 20.53 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Tue, 06 Aug 2024 04:09:09 +0100, Yicong Yang wrote: > > >> +#ifdef CONFIG_ARM64_HAFT > >> + { > >> + .desc = "Hardware managed Access Flag for Table Descriptor", > >> + /* > >> + * Per Spec, software management of Access Flag for Table > >> + * descriptor is not supported, so make this feature system > >> + * wide. > >> + */ > > > > I don't understand what you mean by this. Can you please clarify? > > > > Since this cannot be managed by the software, we should restrict all the CPUs > in the system to have and enable this feature which is indicated by > ARM64_CPUCAP_BOOT_CPU_FEATURE. It's not possible for part of the CPUs don't have > this feature and managed manually. > > I make this comment here since it's handled different from what ARM64_HW_DBM does (which > is ARM64_CPUCAP_WEAK_LOCAL_CPU_FEATURE). Maybe it's redundant and can be dropped. Ah, I see what you mean. I think this is still important to capture, but maybe in a clearer manner. Something like: Contrary to the page/block access flag, the table access flag cannot be emulated in software (no access fault will occur). Therefore mandate that all CPUs have FEAT_HAFT. Thanks, M. -- Without deviation from the norm, progress is not possible.