• Home
  • Raw
  • Download

Lines Matching refs:nr_pages

1521 static unsigned long preallocate_image_pages(unsigned long nr_pages, gfp_t mask)  in preallocate_image_pages()  argument
1525 while (nr_pages > 0) { in preallocate_image_pages()
1536 nr_pages--; in preallocate_image_pages()
1543 static unsigned long preallocate_image_memory(unsigned long nr_pages, in preallocate_image_memory() argument
1552 if (nr_pages < alloc) in preallocate_image_memory()
1553 alloc = nr_pages; in preallocate_image_memory()
1559 static unsigned long preallocate_image_highmem(unsigned long nr_pages) in preallocate_image_highmem() argument
1561 return preallocate_image_pages(nr_pages, GFP_IMAGE | __GFP_HIGHMEM); in preallocate_image_highmem()
1574 static unsigned long preallocate_highmem_fraction(unsigned long nr_pages, in preallocate_highmem_fraction() argument
1578 unsigned long alloc = __fraction(nr_pages, highmem, total); in preallocate_highmem_fraction()
1583 static inline unsigned long preallocate_image_highmem(unsigned long nr_pages) in preallocate_image_highmem() argument
1588 static inline unsigned long preallocate_highmem_fraction(unsigned long nr_pages, in preallocate_highmem_fraction() argument
1875 static int enough_free_mem(unsigned int nr_pages, unsigned int nr_highmem) in enough_free_mem() argument
1884 nr_pages += count_pages_for_highmem(nr_highmem); in enough_free_mem()
1886 nr_pages, PAGES_FOR_IO, free); in enough_free_mem()
1888 return free > nr_pages + PAGES_FOR_IO; in enough_free_mem()
1946 unsigned int nr_pages, unsigned int nr_highmem) in swsusp_alloc() argument
1953 nr_pages += alloc_highmem_pages(copy_bm, nr_highmem); in swsusp_alloc()
1956 if (nr_pages > alloc_normal) { in swsusp_alloc()
1957 nr_pages -= alloc_normal; in swsusp_alloc()
1958 while (nr_pages-- > 0) { in swsusp_alloc()
1977 unsigned int nr_pages, nr_highmem; in swsusp_save() local
1982 nr_pages = count_data_pages(); in swsusp_save()
1984 pr_info("Need to copy %u pages\n", nr_pages + nr_highmem); in swsusp_save()
1986 if (!enough_free_mem(nr_pages, nr_highmem)) { in swsusp_save()
1991 if (swsusp_alloc(&copy_bm, nr_pages, nr_highmem)) { in swsusp_save()
2009 nr_pages += nr_highmem; in swsusp_save()
2010 nr_copy_pages = nr_pages; in swsusp_save()
2011 nr_meta_pages = DIV_ROUND_UP(nr_pages * sizeof(long), PAGE_SIZE); in swsusp_save()
2013 pr_info("Hibernation image created (%d pages copied)\n", nr_pages); in swsusp_save()
2464 unsigned int nr_pages, nr_highmem; in prepare_image() local
2495 nr_pages = nr_copy_pages - nr_highmem - allocated_unsafe_pages; in prepare_image()
2496 nr_pages = DIV_ROUND_UP(nr_pages, PBES_PER_LINKED_PAGE); in prepare_image()
2497 while (nr_pages > 0) { in prepare_image()
2505 nr_pages--; in prepare_image()
2508 nr_pages = nr_copy_pages - nr_highmem - allocated_unsafe_pages; in prepare_image()
2509 while (nr_pages > 0) { in prepare_image()
2523 nr_pages--; in prepare_image()