diff options
author | Jeremy Fitzhardinge <jeremy@goop.org> | 2008-09-11 01:31:50 -0700 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-09-14 17:24:27 +0200 |
commit | 8308c54d7e312f7a03e2ce2057d0837e6fe3843f (patch) | |
tree | 452b32a3d2182c4d150d632f243e31f16b2ac0ce /drivers/pci/setup-bus.c | |
parent | 947d0496cf3e12ebfa70b3eaf561c25403247ce9 (diff) |
generic: redefine resource_size_t as phys_addr_t
There's no good reason why a resource_size_t shouldn't just be a
physical address, so simply redefine it in terms of phys_addr_t.
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'drivers/pci/setup-bus.c')
-rw-r--r-- | drivers/pci/setup-bus.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c index 1aad599816f7..f250a90ee450 100644 --- a/drivers/pci/setup-bus.c +++ b/drivers/pci/setup-bus.c @@ -378,11 +378,10 @@ static int pbus_size_mem(struct pci_bus *bus, unsigned long mask, unsigned long align = 0; min_align = 0; for (order = 0; order <= max_order; order++) { -#ifdef CONFIG_RESOURCES_64BIT - resource_size_t align1 = 1ULL << (order + 20); -#else - resource_size_t align1 = 1U << (order + 20); -#endif + resource_size_t align1 = 1; + + align1 <<= (order + 20); + if (!align) min_align = align1; else if (ALIGN(align + min_align, min_align) < align1) |