diff options
author | Jacob Pan <jacob.jun.pan@linux.intel.com> | 2024-04-23 19:41:04 +0200 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2024-04-30 00:54:42 +0200 |
commit | 4ec8fd037139a4d8afb2a5c7edb4a17f9449a035 (patch) | |
tree | a56fc47fb9e80924c7d0e5cb00bc9e9750301467 | |
parent | KVM: VMX: Move posted interrupt descriptor out of VMX code (diff) | |
download | linux-4ec8fd037139a4d8afb2a5c7edb4a17f9449a035.tar.xz linux-4ec8fd037139a4d8afb2a5c7edb4a17f9449a035.zip |
x86/irq: Unionize PID.PIR for 64bit access w/o casting
Make the PIR field into u64 such that atomic xchg64 can be used without
ugly casting.
Suggested-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Jacob Pan <jacob.jun.pan@linux.intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Link: https://lore.kernel.org/r/20240423174114.526704-3-jacob.jun.pan@linux.intel.com
-rw-r--r-- | arch/x86/include/asm/posted_intr.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/x86/include/asm/posted_intr.h b/arch/x86/include/asm/posted_intr.h index f0324c56f7af..acf237b2882e 100644 --- a/arch/x86/include/asm/posted_intr.h +++ b/arch/x86/include/asm/posted_intr.h @@ -9,7 +9,10 @@ /* Posted-Interrupt Descriptor */ struct pi_desc { - u32 pir[8]; /* Posted interrupt requested */ + union { + u32 pir[8]; /* Posted interrupt requested */ + u64 pir64[4]; + }; union { struct { /* bit 256 - Outstanding Notification */ |