[SPARC64]: Use bootmem_bootmap_pages() in choose_bootmap_pfn().
authorDavid S. Miller <davem@sunset.davemloft.net>
Fri, 16 Mar 2007 02:36:53 +0000 (19:36 -0700)
committerDavid S. Miller <davem@sunset.davemloft.net>
Thu, 26 Apr 2007 08:55:34 +0000 (01:55 -0700)
Signed-off-by: David S. Miller <davem@davemloft.net>
arch/sparc64/mm/init.c

index df4e37e0b0fcee068a967dcf516e19ad9b5baef9..40276189c10762dfb7779ef1fe41884ff577d835 100644 (file)
@@ -770,8 +770,8 @@ static unsigned long __init choose_bootmap_pfn(unsigned long start_pfn,
        unsigned long avoid_start, avoid_end, bootmap_size;
        int i;
 
-       bootmap_size = ((end_pfn - start_pfn) + 7) / 8;
-       bootmap_size = ALIGN(bootmap_size, sizeof(long));
+       bootmap_size = bootmem_bootmap_pages(end_pfn - start_pfn);
+       bootmap_size <<= PAGE_SHIFT;
 
        avoid_start = avoid_end = 0;
 #ifdef CONFIG_BLK_DEV_INITRD