Fix brcm43xx build for PCI-less systems (patch from Michael Buesch)
[openwrt/svn-archive/archive.git] / target / linux / brcm47xx-2.6 / patches-2.6.22 / 220-ssb_pci_deps.patch
1 From: Michael Buesch <mb@bu3sch.de>
2 Date: Fri, 22 Jun 2007 22:13:00 +0000 (+0200)
3 Subject: bcm43xx-mac80211: Fix build for PCI-less systems.
4 X-Git-Url: http://bu3sch.de/gitweb?p=wireless-dev.git;a=commitdiff_plain;h=edd2b9cc18cf2eb15ea35d34af556b614f07114b
5
6 bcm43xx-mac80211: Fix build for PCI-less systems.
7
8 pci_iomap() and pci_iounmap() are not available if PCI
9 support is disabled.
10
11 Signed-off-by: Michael Buesch <mb@bu3sch.de>
12 ---
13
14 diff --git a/drivers/ssb/scan.c b/drivers/ssb/scan.c
15 index feaf1e5..b5d909c 100644
16 --- a/drivers/ssb/scan.c
17 +++ b/drivers/ssb/scan.c
18 @@ -202,7 +202,11 @@ void ssb_iounmap(struct ssb_bus *bus)
19 iounmap(bus->mmio);
20 break;
21 case SSB_BUSTYPE_PCI:
22 +#ifdef CONFIG_SSB_PCIHOST
23 pci_iounmap(bus->host_pci, bus->mmio);
24 +#else
25 + assert(0); /* Can't reach this code. */
26 +#endif
27 break;
28 }
29 bus->mmio = NULL;
30 @@ -222,7 +226,11 @@ static void __iomem * ssb_ioremap(struct ssb_bus *bus,
31 mmio = ioremap(baseaddr, SSB_CORE_SIZE);
32 break;
33 case SSB_BUSTYPE_PCI:
34 +#ifdef CONFIG_SSB_PCIHOST
35 mmio = pci_iomap(bus->host_pci, 0, ~0UL);
36 +#else
37 + assert(0); /* Can't reach this code. */
38 +#endif
39 break;
40 }
41