[PATCH] s390, ioremap: fix

From: Baoquan He
Date: Mon Oct 10 2022 - 21:30:49 EST


On s390 systems (aka mainframes), it has classic channel devices for
networking and permanent storage that are currently even more common
than PCI devices. Hence it's likely to have a fully functional s390
kernel with CONFIG_PCI=n.

So let GENERIC_IOREMAP depend on PCI in s390 arch since the drivers for
those channel devices do not use ioremap() which is only used for PCI,
in theory it should be fine not to have ioremap() for CONFIG_PCI=n.

And let QCOM_HIDMA and PCMCIA PCMCIA depend on HAS_IOMEM so that they
won't be built if PCI is unset.

Signed-off-by: Baoquan He <bhe@xxxxxxxxxx>
---
arch/s390/Kconfig | 2 +-
drivers/dma/qcom/Kconfig | 1 +
drivers/pcmcia/Kconfig | 1 +
3 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index c59e1b25f59d..f6a7f1752f0f 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -135,7 +135,7 @@ config S390
select GENERIC_SMP_IDLE_THREAD
select GENERIC_TIME_VSYSCALL
select GENERIC_VDSO_TIME_NS
- select GENERIC_IOREMAP
+ select GENERIC_IOREMAP if PCI
select HAVE_ALIGNED_STRUCT_PAGE if SLUB
select HAVE_ARCH_AUDITSYSCALL
select HAVE_ARCH_JUMP_LABEL
diff --git a/drivers/dma/qcom/Kconfig b/drivers/dma/qcom/Kconfig
index 3f926a653bd8..ace75d7b835a 100644
--- a/drivers/dma/qcom/Kconfig
+++ b/drivers/dma/qcom/Kconfig
@@ -45,6 +45,7 @@ config QCOM_HIDMA_MGMT

config QCOM_HIDMA
tristate "Qualcomm Technologies HIDMA Channel support"
+ depends on HAS_IOMEM
select DMA_ENGINE
help
Enable support for the Qualcomm Technologies HIDMA controller.
diff --git a/drivers/pcmcia/Kconfig b/drivers/pcmcia/Kconfig
index 1525023e49b6..7c412bbe8bbe 100644
--- a/drivers/pcmcia/Kconfig
+++ b/drivers/pcmcia/Kconfig
@@ -20,6 +20,7 @@ if PCCARD

config PCMCIA
tristate "16-bit PCMCIA support"
+ depends on HAS_IOMEM
select CRC32
default y
help
--
2.34.1