]> git.karo-electronics.de Git - karo-tx-linux.git/commit
Remove mem_cgroup_shmem_charge_fallback(): it was only required when we
authorHugh Dickins <hughd@google.com>
Wed, 3 Aug 2011 00:52:53 +0000 (10:52 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 3 Aug 2011 04:19:26 +0000 (14:19 +1000)
commit7981df4e4b425bf3462f1ca5326c4669dd2e516e
tree2fe9f409255892f3a152be284f1c649928af6706
parenta264e4b39fb947f77ea4087ee0605e3106abf642
Remove mem_cgroup_shmem_charge_fallback(): it was only required when we
had to move swappage to filecache with GFP_NOWAIT.

Remove the GFP_NOWAIT special case from mem_cgroup_cache_charge(), by
moving its call out from shmem_add_to_page_cache() to two of thats three
callers.  But leave it doing mem_cgroup_uncharge_cache_page() on error:
although asymmetrical, it's easier for all 3 callers to handle.

These two changes would also be appropriate if anyone were to start using
shmem_read_mapping_page_gfp() with GFP_NOWAIT.

Remove mem_cgroup_get_shmem_target(): mc_handle_file_pte() can test
radix_tree_exceptional_entry() to get what it needs for itself.

Signed-off-by: Hugh Dickins <hughd@google.com>
Acked-by: Rik van Riel <riel@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
include/linux/memcontrol.h
include/linux/shmem_fs.h
mm/memcontrol.c
mm/shmem.c