]> err.no Git - linux-2.6/blobdiff - kernel/cpuset.c
rcupreempt: remove export of rcu_batches_completed_bh
[linux-2.6] / kernel / cpuset.c
index 039baa4cd90c1109a4c7e2bd382207242ab39f8f..66103a119bfea2924ff638a81ba07a321e9787e8 100644 (file)
@@ -1037,8 +1037,8 @@ int current_cpuset_is_being_rebound(void)
 
 static int update_relax_domain_level(struct cpuset *cs, s64 val)
 {
-       if ((int)val < 0)
-               val = -1;
+       if (val < -1 || val >= SD_LV_MAX)
+               return -EINVAL;
 
        if (val != cs->relax_domain_level) {
                cs->relax_domain_level = val;