Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 361667
b: refs/heads/master
c: d002858
h: refs/heads/master
i:
  361665: 730f669
  361663: 5d919a9
v: v3
  • Loading branch information
Wanpeng Li authored and Linus Torvalds committed Mar 22, 2013
1 parent 12aa3b2 commit cbf01eb
Show file tree
Hide file tree
Showing 2 changed files with 7 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: dc72c32e1fd872a9a4fdfe645283c9dcd68e556d
refs/heads/master: d00285884c0892bb1310df96bce6056e9ce9b9d9
8 changes: 6 additions & 2 deletions trunk/mm/hugetlb.c
Original file line number Diff line number Diff line change
Expand Up @@ -2124,8 +2124,12 @@ int hugetlb_report_node_meminfo(int nid, char *buf)
/* Return the number pages of memory we physically have, in PAGE_SIZE units. */
unsigned long hugetlb_total_pages(void)
{
struct hstate *h = &default_hstate;
return h->nr_huge_pages * pages_per_huge_page(h);
struct hstate *h;
unsigned long nr_total_pages = 0;

for_each_hstate(h)
nr_total_pages += h->nr_huge_pages * pages_per_huge_page(h);
return nr_total_pages;
}

static int hugetlb_acct_memory(struct hstate *h, long delta)
Expand Down

0 comments on commit cbf01eb

Please sign in to comment.