diff options
author | Fernando Luis Vazquez Cao <fernando@oss.ntt.co.jp> | 2009-01-08 03:07:51 +0100 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-01-08 17:31:04 +0100 |
commit | 0753b0ef3b301895234fed02bea2c099c7ff4feb (patch) | |
tree | 35d01368e76d0e5ad21b38fc80274154f8a35d62 /mm/oom_kill.c | |
parent | memcg: simple migration handling (diff) | |
download | linux-0753b0ef3b301895234fed02bea2c099c7ff4feb.tar.xz linux-0753b0ef3b301895234fed02bea2c099c7ff4feb.zip |
memcg: do not recalculate section unnecessarily in init_section_page_cgroup
In init_section_page_cgroup() the section a given pfn belongs to is
calculated at the top of the function and, despite the fact that the
pfn/section correspondence does not change, it is recalculated further
down the same function. By computing this just once and reusing that
value we save some bytes in the object file and do not waste CPU cycles.
Signed-off-by: Fernando Luis Vazquez Cao <fernando@oss.ntt.co.jp>
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Daisuke Nishimura <nishimura@mxp.nes.nec.co.jp>
Cc: Balbir Singh <balbir@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/oom_kill.c')
0 files changed, 0 insertions, 0 deletions