netfilter: ctnetlink: fix error return code in init path
[deliverable/linux.git] / mm / mempolicy.c
index 1d771e4200d222eea46458bdd6089279a78ffeb5..bd92431d4c49a8e29f4b46d50d6d0e66c69098d5 100644 (file)
@@ -1602,8 +1602,14 @@ static unsigned interleave_nodes(struct mempolicy *policy)
  * task can change it's policy.  The system default policy requires no
  * such protection.
  */
-unsigned slab_node(struct mempolicy *policy)
+unsigned slab_node(void)
 {
+       struct mempolicy *policy;
+
+       if (in_interrupt())
+               return numa_node_id();
+
+       policy = current->mempolicy;
        if (!policy || policy->flags & MPOL_F_LOCAL)
                return numa_node_id();
 
This page took 0.025291 seconds and 5 git commands to generate.