Common hibernation code looks at num_physpages during suspend and restore.
Restore is able to be called from initcall, which is before initmem freeing.
This case leads to restore fail.
Signed-off-by: Kirill Tkhai <tkhai@yandex.ru>
CC: David Miller <davem@davemloft.net>
CC: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
ClearPageReserved(p);
init_page_count(p);
__free_page(p);
- num_physpages++;
totalram_pages++;
}
}
ClearPageReserved(p);
init_page_count(p);
__free_page(p);
- num_physpages++;
totalram_pages++;
}
}