mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-27 00:51:35 +00:00
mlock: count attempts to free mlocked page
Allow free of mlock()ed pages. This shouldn't happen, but during developement, it occasionally did. This patch allows us to survive that condition, while keeping the statistics and events correct for debug. Signed-off-by: Lee Schermerhorn <lee.schermerhorn@hp.com> Signed-off-by: Rik van Riel <riel@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
af936a1606
commit
985737cf2e
4 changed files with 20 additions and 0 deletions
|
@ -454,6 +454,7 @@ static inline void __free_one_page(struct page *page,
|
|||
|
||||
static inline int free_pages_check(struct page *page)
|
||||
{
|
||||
free_page_mlock(page);
|
||||
if (unlikely(page_mapcount(page) |
|
||||
(page->mapping != NULL) |
|
||||
(page_get_page_cgroup(page) != NULL) |
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue