]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
mm/mempolicy.c: use enum value MPOL_REBIND_ONCE in mpol_rebind_policy()
authorWang Sheng-Hui <shhuiw@gmail.com>
Wed, 25 Apr 2012 01:03:29 +0000 (11:03 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Mon, 30 Apr 2012 05:17:17 +0000 (15:17 +1000)
We have enum definition in mempolicy.h: MPOL_REBIND_ONCE.  It should
replace the magic number 0 for step comparison in function
mpol_rebind_policy.

Signed-off-by: Wang Sheng-Hui <shhuiw@gmail.com>
Acked-by: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/mempolicy.c

index b19569137529221163e6b51bd96e3a161805a97f..c5f3ed165c93d6ae42da948736a577fe76e1de24 100644 (file)
@@ -390,7 +390,7 @@ static void mpol_rebind_policy(struct mempolicy *pol, const nodemask_t *newmask,
 {
        if (!pol)
                return;
-       if (!mpol_store_user_nodemask(pol) && step == 0 &&
+       if (!mpol_store_user_nodemask(pol) && step == MPOL_REBIND_ONCE &&
            nodes_equal(pol->w.cpuset_mems_allowed, *newmask))
                return;