Fix alignment bug in pci_bios_init_root_regions().
authorKevin O'Connor <kevin@koconnor.net>
Sat, 1 Oct 2011 16:35:32 +0000 (12:35 -0400)
committerKevin O'Connor <kevin@koconnor.net>
Sat, 1 Oct 2011 16:42:51 +0000 (12:42 -0400)
commit3c5fcec00ce1317cda56d549259550fcc018c834
tree5c8b9f50af06b16432bf8ea9dd8aca62b19501df
parentd2deae203dd58db6a9e9f2906dead311d6d07328
Fix alignment bug in pci_bios_init_root_regions().

If there are no memory allocations for a given type then the "max" bar
size is zero.  However, ALIGN_DOWN does not handle an alignment of
zero properly.  Catch and handle the zero case.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
src/pciinit.c