• Andy Whitcroft's avatar
    [PATCH] use page_to_nid · 12bf4a56
    Andy Whitcroft authored
    There are a couple of places where we seem to go round the houses to get
    the numa node id from a page.  We have a macro for this so it seems
    sensible to use that.
    
    Both lookup_node and enqueue_huge_page use page_zone() to locate the zone,
    that to locate node pgdat_t and that to get the node_id.  Its more
    efficient to use page_to_nid() which gets the nid from the page flags,
    especially if we are not using the zone for anything else it.  Change these
    to use page_to_nid().
    Signed-off-by: default avatarAndy Whitcroft <apw@shadowen.org>
    Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
    Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
    12bf4a56
mempolicy.c 26 KB