Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 347874
b: refs/heads/master
c: bcc2b02
h: refs/heads/master
v: v3
  • Loading branch information
Marek Szyprowski authored and Linus Torvalds committed Dec 21, 2012
1 parent 9b05230 commit aeecb1b
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b66c5984017533316fd1951770302649baf1aa33
refs/heads/master: bcc2b02f4c1b36bc67272df7119b75bac78525ab
11 changes: 9 additions & 2 deletions trunk/mm/page_alloc.c
Original file line number Diff line number Diff line change
Expand Up @@ -5978,8 +5978,15 @@ int alloc_contig_range(unsigned long start, unsigned long end,

void free_contig_range(unsigned long pfn, unsigned nr_pages)
{
for (; nr_pages--; ++pfn)
__free_page(pfn_to_page(pfn));
unsigned int count = 0;

for (; nr_pages--; pfn++) {
struct page *page = pfn_to_page(pfn);

count += page_count(page) != 1;
__free_page(page);
}
WARN(count != 0, "%d pages are still in use!\n", count);
}
#endif

Expand Down

0 comments on commit aeecb1b

Please sign in to comment.