[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <201112011815.pB1IFGZe004948@farm-0002.internal.tilera.com>
Date: Thu, 1 Dec 2011 12:59:19 -0500
From: Chris Metcalf <cmetcalf@...era.com>
To: linux-kernel@...r.kernel.org, <linux-pci@...r.kernel.org>,
<linux-arch@...r.kernel.org>,
Rolf Eike Beer <eike-kernel@...tec.de>,
Andrew Morton <akpm@...ux-foundation.org>,
"Maxin B. John" <maxin.john@...il.com>, Tejun Heo <tj@...nel.org>,
"Michael S. Tsirkin" <mst@...hat.com>,
"Lucas De Marchi" <lucas.demarchi@...fusion.mobi>,
"Paul Mundt" <lethal@...ux-sh.org>,
"Jesse Barnes" <jbarnes@...tuousgeek.org>,
"David S. Miller" <davem@...emloft.net>
Subject: [PATCH] lib/devres.c: allow specifying NO_IOPORT while using PCI
The tile architecture does not support IOPORT, but it does support
PCI and IOMEM. We were not specifying NO_IOPORT, though, because it
was causing a couple of functions (pcim_iomap_regions and pcim_iomap_table)
that are needed to not get provided. Moving the #ifdef fixes this
so that those functions and some related ones are now always provided
if CONFIG_PCI is true.
Signed-off-by: Chris Metcalf <cmetcalf@...era.com>
---
This commit was inspired by the recent linux-arch discussion about
what to do with ioport_map on architectures that can't do it, so I went
back to figure out why I hadn't set NO_IOPORT in the first place.
I'm willing to take this into the tile tree if the PCI folks are OK
with it, or if someone else can pick it up, that's fine too.
arch/tile/Kconfig | 2 +-
lib/devres.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/tile/Kconfig b/arch/tile/Kconfig
index 70a0de4..e7b1e07 100644
--- a/arch/tile/Kconfig
+++ b/arch/tile/Kconfig
@@ -333,7 +333,7 @@ config NO_IOMEM
def_bool !PCI
config NO_IOPORT
- def_bool !PCI
+ def_bool y
source "drivers/pci/Kconfig"
diff --git a/lib/devres.c b/lib/devres.c
index 7c0e953..5f36cfd 100644
--- a/lib/devres.c
+++ b/lib/devres.c
@@ -144,6 +144,7 @@ void devm_ioport_unmap(struct device *dev, void __iomem *addr)
devm_ioport_map_match, (void *)addr));
}
EXPORT_SYMBOL(devm_ioport_unmap);
+#endif
#ifdef CONFIG_PCI
/*
@@ -349,4 +350,3 @@ void pcim_iounmap_regions(struct pci_dev *pdev, u16 mask)
}
EXPORT_SYMBOL(pcim_iounmap_regions);
#endif
-#endif
--
1.6.5.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists