aboutsummaryrefslogtreecommitdiffstats
path: root/arch/sh/include
diff options
context:
space:
mode:
Diffstat (limited to 'arch/sh/include')
-rw-r--r--arch/sh/include/asm/pci.h22
1 files changed, 2 insertions, 20 deletions
diff --git a/arch/sh/include/asm/pci.h b/arch/sh/include/asm/pci.h
index e8265fd0bb6f..532428289772 100644
--- a/arch/sh/include/asm/pci.h
+++ b/arch/sh/include/asm/pci.h
@@ -26,6 +26,8 @@ struct pci_channel {
26 int enabled; 26 int enabled;
27 unsigned long reg_base; 27 unsigned long reg_base;
28 unsigned long io_base; 28 unsigned long io_base;
29
30 unsigned long io_map_base;
29}; 31};
30 32
31/* 33/*
@@ -110,31 +112,11 @@ static inline int __is_pci_memory(unsigned long phys_addr, unsigned long size)
110 } 112 }
111 return 0; 113 return 0;
112} 114}
113
114static inline void __iomem *__get_pci_io_base(unsigned long port,
115 unsigned long size)
116{
117 struct pci_channel *p;
118 struct resource *res;
119
120 for (p = board_pci_channels; p->init; p++) {
121 res = p->io_resource;
122 if (p->enabled && (port >= res->start) &&
123 (port + size) <= (res->end + 1))
124 return (void __iomem *)(p->io_base + port);
125 }
126 return NULL;
127}
128#else 115#else
129static inline int __is_pci_memory(unsigned long phys_addr, unsigned long size) 116static inline int __is_pci_memory(unsigned long phys_addr, unsigned long size)
130{ 117{
131 return 0; 118 return 0;
132} 119}
133static inline void __iomem *__get_pci_io_base(unsigned long port,
134 unsigned long size)
135{
136 return NULL;
137}
138#endif 120#endif
139 121
140/* Board-specific fixup routines. */ 122/* Board-specific fixup routines. */