aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mn10300/unit-asb2305/pci-asb2305.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/mn10300/unit-asb2305/pci-asb2305.c')
-rw-r--r--arch/mn10300/unit-asb2305/pci-asb2305.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/arch/mn10300/unit-asb2305/pci-asb2305.c b/arch/mn10300/unit-asb2305/pci-asb2305.c
index 78cd134ddf7d..b0b3758fba08 100644
--- a/arch/mn10300/unit-asb2305/pci-asb2305.c
+++ b/arch/mn10300/unit-asb2305/pci-asb2305.c
@@ -31,9 +31,11 @@
31 * but we want to try to avoid allocating at 0x2900-0x2bff 31 * but we want to try to avoid allocating at 0x2900-0x2bff
32 * which might have be mirrored at 0x0100-0x03ff.. 32 * which might have be mirrored at 0x0100-0x03ff..
33 */ 33 */
34void pcibios_align_resource(void *data, struct resource *res, 34resource_size_t pcibios_align_resource(void *data, struct resource *res,
35 resource_size_t size, resource_size_t align) 35 resource_size_t size, resource_size_t align)
36{ 36{
37 resource_size_t start = res->start;
38
37#if 0 39#if 0
38 struct pci_dev *dev = data; 40 struct pci_dev *dev = data;
39 41
@@ -47,14 +49,10 @@ void pcibios_align_resource(void *data, struct resource *res,
47 ); 49 );
48#endif 50#endif
49 51
50 if (res->flags & IORESOURCE_IO) { 52 if ((res->flags & IORESOURCE_IO) && (start & 0x300))
51 unsigned long start = res->start; 53 start = (start + 0x3ff) & ~0x3ff;
52 54
53 if (start & 0x300) { 55 return start;
54 start = (start + 0x3ff) & ~0x3ff;
55 res->start = start;
56 }
57 }
58} 56}
59 57
60 58