Skip to content

Commit

Permalink
mem-controller gfp-mask fix
Browse files Browse the repository at this point in the history
Need to strip __GFP_HIGHMEM flag while passing to mem_container_cache_charge().

Signed-off-by: Badari Pulavarty <pbadari@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Badari Pulavarty authored and Linus Torvalds committed Feb 7, 2008
1 parent 35c754d commit 4c6bc8d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion mm/filemap.c
Original file line number Diff line number Diff line change
Expand Up @@ -460,7 +460,8 @@ int filemap_write_and_wait_range(struct address_space *mapping,
int add_to_page_cache(struct page *page, struct address_space *mapping,
pgoff_t offset, gfp_t gfp_mask)
{
int error = mem_cgroup_cache_charge(page, current->mm, gfp_mask);
int error = mem_cgroup_cache_charge(page, current->mm,
gfp_mask & ~__GFP_HIGHMEM);
if (error)
goto out;

Expand Down

0 comments on commit 4c6bc8d

Please sign in to comment.