can: kvaser_usb_leaf: Fix bogus restart events
[linux-block.git] / mm / memblock.c
index b5d3026979fccbb767458c2844ba1043ca47dd06..511d4783dcf1d86374c14d528cfec69c51247749 100644 (file)
@@ -2000,7 +2000,7 @@ static void __init free_unused_memmap(void)
                 * presume that there are no holes in the memory map inside
                 * a pageblock
                 */
-               start = round_down(start, pageblock_nr_pages);
+               start = pageblock_start_pfn(start);
 
                /*
                 * If we had a previous bank, and there is a space
@@ -2014,12 +2014,12 @@ static void __init free_unused_memmap(void)
                 * presume that there are no holes in the memory map inside
                 * a pageblock
                 */
-               prev_end = ALIGN(end, pageblock_nr_pages);
+               prev_end = pageblock_align(end);
        }
 
 #ifdef CONFIG_SPARSEMEM
        if (!IS_ALIGNED(prev_end, PAGES_PER_SECTION)) {
-               prev_end = ALIGN(end, pageblock_nr_pages);
+               prev_end = pageblock_align(end);
                free_memmap(prev_end, ALIGN(prev_end, PAGES_PER_SECTION));
        }
 #endif