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 AA6B318EAD; Sun, 17 Mar 2024 12:50:40 +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=1710679840; cv=none; b=QIjev5IFksTUpmTcOfsiKkhGIFYOtf8TfPyUQPvsIfQdbo8W1N38t2b1lTgi0EChCMNLeUUU+8lyrfka/xY+nTugYEGqidhknJyJBVWE4qYv0N0WYE3WHaYRM1aa3FY7FpH0+eSM2EylsoR6k6KGmptPl0WqPSB0F1BMifZ5tRs= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710679840; c=relaxed/simple; bh=u7B/Jvp7P9C5qB9irs/k5g8gIupz4K+Qm2duwLJlnSA=; h=Date:Message-ID:From:To:Cc:Subject:In-Reply-To:References: MIME-Version:Content-Type; b=CMYbciOVJYEdzQzRIwi8q7bjVUvZFm4FMKxQJHm6w/HjjYrxXSxSFkBZgv3jTZFtYnqOjQJo9skpIPYFDAZwvKmYSfNYZ/mozGNfpIGtvR4pL+2YjHwSdSuaFmx//7wybF4hj0bueyruEUIlL+LA+PVn6BLjbXVB4Ww3Ij3r0Ok= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Am52SrIx; 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="Am52SrIx" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1C345C433F1; Sun, 17 Mar 2024 12:50:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1710679840; bh=u7B/Jvp7P9C5qB9irs/k5g8gIupz4K+Qm2duwLJlnSA=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=Am52SrIxS7fDHll0FQ5mKHFmSnTl382wdOSYbvCr8RhIHlI414wIyqvoKQID9Gfjr DNKgeIsZ5ww06jlr7jbyLnN1Dr82A5V9zIgc7mQXLZY/ocOEf9CJBueWxnht6kYazu /ltd3mUGWnHbODLljGd65Th79MzTtoX882H+LPYNNO2nOwRT6U9jL1+pWdFhTU+vN7 wK4yn3HJiiLBQqE1t/beKeg6GixVnXrTzFyjdtGCHuW+kIHXORdtGfrrkB3nXbjIPg q5XNsx6h6eF4VfLLxXug09llPi1w+zpcZpwcakMJQZ+ytMDGxlSED1r9kBmdiKbgPF segoGN0K1sI6g== 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 1rlpyH-00D24G-Ox; Sun, 17 Mar 2024 12:50:37 +0000 Date: Sun, 17 Mar 2024 12:50:37 +0000 Message-ID: <868r2h10pu.wl-maz@kernel.org> From: Marc Zyngier To: =?UTF-8?B?UGllcnJlLUNsw6ltZW50?= Tosi Cc: kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, kvm@vger.kernel.org, James Morse , Suzuki K Poulose , Oliver Upton , Zenghui Yu , Catalin Marinas , Will Deacon Subject: Re: [PATCH 08/10] arm64: Move esr_comment() to In-Reply-To: <6374e3f9d15663e0ea55fa4261ac42f3348ad809.1710446682.git.ptosi@google.com> References: <6374e3f9d15663e0ea55fa4261ac42f3348ad809.1710446682.git.ptosi@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.1 (aarch64-unknown-linux-gnu) MULE/6.0 (HANACHIRUSATO) Precedence: bulk X-Mailing-List: kvm@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=UTF-8 Content-Transfer-Encoding: quoted-printable X-SA-Exim-Connect-IP: 185.219.108.64 X-SA-Exim-Rcpt-To: ptosi@google.com, kvmarm@lists.linux.dev, linux-arm-kernel@lists.infradead.org, kvm@vger.kernel.org, james.morse@arm.com, suzuki.poulose@arm.com, oliver.upton@linux.dev, yuzenghui@huawei.com, catalin.marinas@arm.com, will@kernel.org X-SA-Exim-Mail-From: maz@kernel.org X-SA-Exim-Scanned: No (on disco-boy.misterjones.org); SAEximRunCond expanded to false On Thu, 14 Mar 2024 20:25:29 +0000, Pierre-Cl=C3=A9ment Tosi wrote: >=20 > As it is already defined twice and is about to be needed for CFI error > detection, move esr_comment() to a header so that it can be reused. >=20 > Signed-off-by: Pierre-Cl=C3=A9ment Tosi > --- > arch/arm64/include/asm/esr.h | 5 +++++ > arch/arm64/kernel/debug-monitors.c | 4 +--- > arch/arm64/kernel/traps.c | 2 -- > arch/arm64/kvm/handle_exit.c | 2 +- > 4 files changed, 7 insertions(+), 6 deletions(-) >=20 > diff --git a/arch/arm64/include/asm/esr.h b/arch/arm64/include/asm/esr.h > index 353fe08546cf..b0c23e7d6595 100644 > --- a/arch/arm64/include/asm/esr.h > +++ b/arch/arm64/include/asm/esr.h > @@ -385,6 +385,11 @@ > #ifndef __ASSEMBLY__ > #include > =20 > +static inline unsigned long esr_comment(unsigned long esr) > +{ > + return esr & ESR_ELx_BRK64_ISS_COMMENT_MASK; > +} nit: naming it esr_brk_comment() would make it slightly clearer what this helper applies to, now that it is visible out of the limited context of traps.c. Thanks, M. --=20 Without deviation from the norm, progress is not possible.