summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorMel Gorman <mgorman@techsingularity.net>2016-05-20 03:13:53 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2016-05-20 05:12:14 +0300
commit09940a4f1e816abe3248fa0d185fc0e7f54c8c12 (patch)
tree5c38f11be87449271f77b9d213f38a04d4d4999a /include
parent5bb1b169757875a72e05bfcbb76e22602cb1a760 (diff)
downloadlinux-09940a4f1e816abe3248fa0d185fc0e7f54c8c12.tar.xz
mm, page_alloc: simplify last cpupid reset
The current reset unnecessarily clears flags and makes pointless calculations. Signed-off-by: Mel Gorman <mgorman@techsingularity.net> Acked-by: Vlastimil Babka <vbabka@suse.cz> Cc: Jesper Dangaard Brouer <brouer@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mm.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 9c2852cabf01..2b97be1147ec 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -850,10 +850,7 @@ extern int page_cpupid_xchg_last(struct page *page, int cpupid);
static inline void page_cpupid_reset_last(struct page *page)
{
- int cpupid = (1 << LAST_CPUPID_SHIFT) - 1;
-
- page->flags &= ~(LAST_CPUPID_MASK << LAST_CPUPID_PGSHIFT);
- page->flags |= (cpupid & LAST_CPUPID_MASK) << LAST_CPUPID_PGSHIFT;
+ page->flags |= LAST_CPUPID_MASK << LAST_CPUPID_PGSHIFT;
}
#endif /* LAST_CPUPID_NOT_IN_PAGE_FLAGS */
#else /* !CONFIG_NUMA_BALANCING */