x86/apic: Drop apic::delivery_mode
authorAndrew Cooper <andrew.cooper3@citrix.com>
Thu, 2 Nov 2023 12:26:19 +0000 (12:26 +0000)
committerBorislav Petkov (AMD) <bp@alien8.de>
Tue, 21 Nov 2023 15:58:54 +0000 (16:58 +0100)
commit07e8f88568f558fb0f9529f49b3ab120cbe750fe
tree12cbecaab55388e9cb5db5298c50fbaa1dda9726
parent98b1cc82c4affc16f5598d4fa14b1858671b2263
x86/apic: Drop apic::delivery_mode

This field is set to APIC_DELIVERY_MODE_FIXED in all cases, and is read
exactly once.  Fold the constant in uv_program_mmr() and drop the field.

Searching for the origin of the stale HyperV comment reveals commit
a31e58e129f7 ("x86/apic: Switch all APICs to Fixed delivery mode") which
notes:

  As a consequence of this change, the apic::irq_delivery_mode field is
  now pointless, but this needs to be cleaned up in a separate patch.

6 years is long enough for this technical debt to have survived.

  [ bp: Fold in
    https://lore.kernel.org/r/20231121123034.1442059-1-andrew.cooper3@citrix.com
  ]

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Steve Wahl <steve.wahl@hpe.com>
Link: https://lore.kernel.org/r/20231102-x86-apic-v1-1-bf049a2a0ed6@citrix.com
13 files changed:
arch/x86/include/asm/apic.h
arch/x86/kernel/apic/apic_flat_64.c
arch/x86/kernel/apic/apic_noop.c
arch/x86/kernel/apic/apic_numachip.c
arch/x86/kernel/apic/bigsmp_32.c
arch/x86/kernel/apic/probe_32.c
arch/x86/kernel/apic/x2apic_cluster.c
arch/x86/kernel/apic/x2apic_phys.c
arch/x86/kernel/apic/x2apic_uv_x.c
arch/x86/platform/uv/uv_irq.c
drivers/iommu/amd/iommu.c
drivers/iommu/intel/irq_remapping.c
drivers/pci/controller/pci-hyperv.c