The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Breno Leitao <leitao@debian.org>
To: Jinjie Ruan <ruanjinjie@huawei.com>
Cc: catalin.marinas@arm.com, will@kernel.org, corbet@lwn.net,
	 skhan@linuxfoundation.org, maz@kernel.org, ardb@kernel.org,
	ilias.apalodimas@linaro.org,  oupton@kernel.org,
	joey.gouly@arm.com, seiden@linux.ibm.com, suzuki.poulose@arm.com,
	 yuzenghui@huawei.com, oleg@redhat.com, mark.rutland@arm.com,
	lpieralisi@kernel.org,  tglx@kernel.org, ada.coupriediaz@arm.com,
	anshuman.khandual@arm.com,  ebiggers@kernel.org,
	broonie@kernel.org, mrigendra.chaubey@gmail.com,
	 baohua@kernel.org, lucaswei@google.com, james.morse@arm.com,
	zengheng4@huawei.com,  thuth@redhat.com,
	yang@os.amperecomputing.com, leo.bras@arm.com,
	 Sascha.Bischoff@arm.com, james.clark@linaro.org,
	peterz@infradead.org, ben.horgan@arm.com,
	 punit.agrawal@oss.qualcomm.com, gshan@redhat.com,
	osama.abdelkader@gmail.com,  fengchengwen@huawei.com,
	ryan.roberts@arm.com, yangyicong@hisilicon.com,
	 kevin.brodsky@arm.com, kees@kernel.org, jeson.gao@unisoc.com,
	zhaoyang.huang@unisoc.com,  ryotkkr98@gmail.com, wsw9603@163.com,
	pasha.tatashin@soleen.com,  jeremy.linton@arm.com,
	schuster.simon@siemens-energy.com, osandov@fb.com, arnd@arndb.de,
	 zhangpengjie2@huawei.com, smostafa@google.com,
	vladimir.murzin@arm.com, tabba@google.com,
	 vdonnefort@google.com, kaleshsingh@google.com, jic23@kernel.org,
	timothy.hayes@arm.com,  alexandru.elisei@arm.com,
	zenghui.yu@linux.dev, david@kernel.org,
	 akpm@linux-foundation.org, ljs@kernel.org, memxor@gmail.com,
	qperret@google.com,  chaitanyas.prakash@arm.com,
	linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org,
	 linux-kernel@vger.kernel.org, linux-efi@vger.kernel.org,
	kvmarm@lists.linux.dev
Subject: Re: [PATCH 01/17] arm64: Move DAIF macros to ptrace.h and use them centrally
Date: Fri, 3 Jul 2026 09:44:11 -0700	[thread overview]
Message-ID: <akfl8VwB-RkHIFgm@gmail.com> (raw)
In-Reply-To: <20260703100135.2512312-2-ruanjinjie@huawei.com>

On Fri, Jul 03, 2026 at 06:01:19PM +0800, Jinjie Ruan wrote:
> So move the definitions of DAIF_PROCCTX, DAIF_PROCCTX_NOIRQ, DAIF_ERRCTX,
> and DAIF_MASK from <asm/daifflags.h> to <asm/ptrace.h>. 

This seems a bit counter intuitive, to have DAIF definitions at
arm/ptrace.h instead of asm/daifflags.h, no?

> diff --git a/arch/arm64/kvm/hyp/nvhe/host.S b/arch/arm64/kvm/hyp/nvhe/host.S
> index 9393fe3ea6a1..cbe2a616c726 100644
> --- a/arch/arm64/kvm/hyp/nvhe/host.S
> +++ b/arch/arm64/kvm/hyp/nvhe/host.S
> @@ -11,6 +11,7 @@
>  #include <asm/kvm_asm.h>
>  #include <asm/kvm_mmu.h>
>  #include <asm/kvm_ptrauth.h>
> +#include <asm/ptrace.h>

..

> diff --git a/arch/arm64/kvm/hyp/nvhe/hyp-init.S b/arch/arm64/kvm/hyp/nvhe/hyp-init.S
> index 89cb553be1e5..26ea02e7f5fd 100644
> --- a/arch/arm64/kvm/hyp/nvhe/hyp-init.S
> +++ b/arch/arm64/kvm/hyp/nvhe/hyp-init.S
> @@ -15,6 +15,7 @@
>  #include <asm/kvm_asm.h>
>  #include <asm/kvm_mmu.h>
>  #include <asm/pgtable-hwdef.h>
> +#include <asm/ptrace.h>

And then you need to do this in many low level files, which sounds less
intuitive to have to have ptrace.h include instead of asm/daifflags.h
(which is clear why we need it).

--breno

  reply	other threads:[~2026-07-03 16:45 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-03 10:01 [PATCH 00/17] arm64: Support FEAT_NMI and Rework Exception Masking Jinjie Ruan
2026-07-03 10:01 ` [PATCH 01/17] arm64: Move DAIF macros to ptrace.h and use them centrally Jinjie Ruan
2026-07-03 16:44   ` Breno Leitao [this message]
2026-07-03 10:01 ` [PATCH 02/17] arm64: Rework exception masking into abstract logical mask Jinjie Ruan
2026-07-03 13:38   ` Leonardo Bras
2026-07-03 13:48   ` Leonardo Bras
2026-07-03 10:01 ` [PATCH 03/17] arm64: entry: arm64: entry: Move DAIF masking for EL1 exit to C code Jinjie Ruan
2026-07-03 10:01 ` [PATCH 04/17] arm64: entry: Add entry-specific helpers Jinjie Ruan
2026-07-03 10:01 ` [PATCH 05/17] arm64: Introduce helpers for restoring standard exception masks Jinjie Ruan
2026-07-03 10:01 ` [PATCH 06/17] arm64/booting: Document boot requirements for FEAT_NMI Jinjie Ruan
2026-07-03 10:01 ` [PATCH 07/17] arm64/sysreg: Add definitions for immediate versions of MSR ALLINT Jinjie Ruan
2026-07-03 10:01 ` [PATCH 08/17] arm64/hyp-stub: Enable access to ALLINT Jinjie Ruan
2026-07-03 10:01 ` [PATCH 09/17] arm64/idreg: Add an override for FEAT_NMI Jinjie Ruan
2026-07-03 10:01 ` [PATCH 10/17] arm64/cpufeature: Detect PE support " Jinjie Ruan
2026-07-03 10:01 ` [PATCH 11/17] KVM: arm64: Hide FEAT_NMI from guests Jinjie Ruan
2026-07-03 10:01 ` [PATCH 12/17] arm64/nmi: Manage masking for superpriority interrupts along with DAIF Jinjie Ruan
2026-07-03 10:01 ` [PATCH 13/17] arm64/entry: Don't call preempt_schedule_irq() with NMIs masked Jinjie Ruan
2026-07-03 10:01 ` [PATCH 14/17] arm64/irq: Document handling of FEAT_NMI in irqflags.h Jinjie Ruan
2026-07-03 10:01 ` [PATCH 15/17] arm64/nmi: Add handling of superpriority interrupts as NMIs Jinjie Ruan
2026-07-03 10:01 ` [PATCH 16/17] arm64/nmi: Add Kconfig for NMI Jinjie Ruan
2026-07-03 10:01 ` [PATCH 17/17] irqchip/gic-v3: Implement FEAT_GICv3_NMI support Jinjie Ruan
2026-07-03 14:15 ` [PATCH 00/17] arm64: Support FEAT_NMI and Rework Exception Masking Mark Rutland

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=akfl8VwB-RkHIFgm@gmail.com \
    --to=leitao@debian.org \
    --cc=Sascha.Bischoff@arm.com \
    --cc=ada.coupriediaz@arm.com \
    --cc=akpm@linux-foundation.org \
    --cc=alexandru.elisei@arm.com \
    --cc=anshuman.khandual@arm.com \
    --cc=ardb@kernel.org \
    --cc=arnd@arndb.de \
    --cc=baohua@kernel.org \
    --cc=ben.horgan@arm.com \
    --cc=broonie@kernel.org \
    --cc=catalin.marinas@arm.com \
    --cc=chaitanyas.prakash@arm.com \
    --cc=corbet@lwn.net \
    --cc=david@kernel.org \
    --cc=ebiggers@kernel.org \
    --cc=fengchengwen@huawei.com \
    --cc=gshan@redhat.com \
    --cc=ilias.apalodimas@linaro.org \
    --cc=james.clark@linaro.org \
    --cc=james.morse@arm.com \
    --cc=jeremy.linton@arm.com \
    --cc=jeson.gao@unisoc.com \
    --cc=jic23@kernel.org \
    --cc=joey.gouly@arm.com \
    --cc=kaleshsingh@google.com \
    --cc=kees@kernel.org \
    --cc=kevin.brodsky@arm.com \
    --cc=kvmarm@lists.linux.dev \
    --cc=leo.bras@arm.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-efi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ljs@kernel.org \
    --cc=lpieralisi@kernel.org \
    --cc=lucaswei@google.com \
    --cc=mark.rutland@arm.com \
    --cc=maz@kernel.org \
    --cc=memxor@gmail.com \
    --cc=mrigendra.chaubey@gmail.com \
    --cc=oleg@redhat.com \
    --cc=osama.abdelkader@gmail.com \
    --cc=osandov@fb.com \
    --cc=oupton@kernel.org \
    --cc=pasha.tatashin@soleen.com \
    --cc=peterz@infradead.org \
    --cc=punit.agrawal@oss.qualcomm.com \
    --cc=qperret@google.com \
    --cc=ruanjinjie@huawei.com \
    --cc=ryan.roberts@arm.com \
    --cc=ryotkkr98@gmail.com \
    --cc=schuster.simon@siemens-energy.com \
    --cc=seiden@linux.ibm.com \
    --cc=skhan@linuxfoundation.org \
    --cc=smostafa@google.com \
    --cc=suzuki.poulose@arm.com \
    --cc=tabba@google.com \
    --cc=tglx@kernel.org \
    --cc=thuth@redhat.com \
    --cc=timothy.hayes@arm.com \
    --cc=vdonnefort@google.com \
    --cc=vladimir.murzin@arm.com \
    --cc=will@kernel.org \
    --cc=wsw9603@163.com \
    --cc=yang@os.amperecomputing.com \
    --cc=yangyicong@hisilicon.com \
    --cc=yuzenghui@huawei.com \
    --cc=zengheng4@huawei.com \
    --cc=zenghui.yu@linux.dev \
    --cc=zhangpengjie2@huawei.com \
    --cc=zhaoyang.huang@unisoc.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox