aboutsummaryrefslogtreecommitdiffstats
path: root/arch/x86/mm/init.c
diff options
context:
space:
mode:
authorWeijie Yang <weijie.yang@samsung.com>2013-11-12 15:08:27 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2013-11-13 12:09:11 +0900
commit0ab0abcf511545d1fddbe72a36b3ca73388ac937 (patch)
tree66109020ad7d9888970f153cdd55b3b5e2491560 /arch/x86/mm/init.c
parentmm/zswap: bugfix: memory leak when invalidate and reclaim occur concurrently (diff)
downloadlinux-dev-0ab0abcf511545d1fddbe72a36b3ca73388ac937.tar.xz
linux-dev-0ab0abcf511545d1fddbe72a36b3ca73388ac937.zip
mm/zswap: refactor the get/put routines
The refcount routine was not fit the kernel get/put semantic exactly, There were too many judgement statements on refcount and it could be minus. This patch does the following: - move refcount judgement to zswap_entry_put() to hide resource free function. - add a new function zswap_entry_find_get(), so that callers can use easily in the following pattern: zswap_entry_find_get .../* do something */ zswap_entry_put - to eliminate compile error, move some functions declaration This patch is based on Minchan Kim <minchan@kernel.org> 's idea and suggestion. Signed-off-by: Weijie Yang <weijie.yang@samsung.com> Cc: Seth Jennings <sjennings@variantweb.net> Acked-by: Minchan Kim <minchan@kernel.org> Cc: Bob Liu <bob.liu@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions