]> git.karo-electronics.de Git - karo-tx-linux.git/commit
SubjectL mm: use the light version __mod_zone_page_state in mlocked_vma_newpage()
authorJianyu Zhan <nasa4836@gmail.com>
Thu, 22 May 2014 00:43:14 +0000 (10:43 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Thu, 22 May 2014 00:43:14 +0000 (10:43 +1000)
commit33c91a1c1870fac9a6305647fff7be09b0bdd809
tree84ecd4f7aa9e9e82c998ac5819b737c9b1030af1
parentdc2a783cedddaeffce6c43e195200ca6f1c8177d
SubjectL mm: use the light version __mod_zone_page_state in mlocked_vma_newpage()

mlocked_vma_newpage() is called with pte lock held(a spinlock), which
implies preemtion disabled, and the vm stat counter is not modified from
interrupt context, so we need not use an irq-safe mod_zone_page_state()
here, using a light-weight version __mod_zone_page_state() would be OK.

This patch also documents __mod_zone_page_state() and some of its
callsites.  The comment above __mod_zone_page_state() is from Hugh
Dickins, and acked by Christoph.

Most credits to Hugh and Christoph for the clarification on the usage of
the __mod_zone_page_state().

Suggested-by: Andrew Morton <akpm@linux-foundation.org>
Acked-by: Hugh Dickins <hughd@google.com>
Signed-off-by: Jianyu Zhan <nasa4836@gmail.com>
Reviewed-by: Christoph Lameter <cl@linux.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/internal.h
mm/rmap.c
mm/vmstat.c