[PATCH 3/3] sched/prio: Replace hardcoding of 40 with NICE_WIDTH.

From: Dongsheng Yang
Date: Wed Mar 05 2014 - 07:38:55 EST


Signed-off-by: Dongsheng Yang <yangds.fnst@xxxxxxxxxxxxxx>
---
kernel/sched/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 5273037..7ed08ad 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -3070,7 +3070,7 @@ SYSCALL_DEFINE1(nice, int, increment)
* We don't have to worry. Conceptually one call occurs first
* and we have a single winner.
*/
- increment = clamp(increment, -40, 40);
+ increment = clamp(increment, -NICE_WIDTH, NICE_WIDTH);
nice = task_nice(current) + increment;

nice = clamp_val(nice, MIN_NICE, MAX_NICE);
--
1.8.2.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/