Skip to content

Commit f768c75

Browse files
niklas88bjorn-helgaas
authored andcommitted
PCI: Make quirk using inw() depend on HAS_IOPORT
In the future inw() and friends will not be compiled on architectures without I/O port support. Co-developed-by: Arnd Bergmann <arnd@kernel.org> Link: https://lore.kernel.org/r/20230703135255.2202721-2-schnelle@linux.ibm.com Signed-off-by: Arnd Bergmann <arnd@kernel.org> Signed-off-by: Niklas Schnelle <schnelle@linux.ibm.com> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
1 parent 06c2afb commit f768c75

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/pci/quirks.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_NEC, PCI_DEVICE_ID_NEC_CBUS_2, quirk_isa_d
361361
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_NEC, PCI_DEVICE_ID_NEC_CBUS_3, quirk_isa_dma_hangs);
362362
#endif
363363

364+
#ifdef CONFIG_HAS_IOPORT
364365
/*
365366
* Intel NM10 "TigerPoint" LPC PM1a_STS.BM_STS must be clear
366367
* for some HT machines to use C4 w/o hanging.
@@ -380,6 +381,7 @@ static void quirk_tigerpoint_bm_sts(struct pci_dev *dev)
380381
}
381382
}
382383
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_TGP_LPC, quirk_tigerpoint_bm_sts);
384+
#endif
383385

384386
/* Chipsets where PCI->PCI transfers vanish or hang */
385387
static void quirk_nopcipci(struct pci_dev *dev)

0 commit comments

Comments
 (0)