diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2008-06-05 04:28:00 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-06-06 09:19:44 -0400 |
commit | e539d8fcd11af811db70707d47ea436d5621d0da (patch) | |
tree | 9bf41406ee7b635abf5a6769acd6a93cbd4df104 /kernel/sched_cpupri.h | |
parent | 709d4b0c60f990bccf3e10ba7c6da407ad65c97f (diff) |
sched: fix the cpuprio count really
Peter pointed out that the last version of the "fix" was still one off
under certain circumstances. Use BITS_TO_LONG instead to get an
accurate result.
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/sched_cpupri.h')
-rw-r--r-- | kernel/sched_cpupri.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/kernel/sched_cpupri.h b/kernel/sched_cpupri.h index 6b38355e2676..f25811b0f931 100644 --- a/kernel/sched_cpupri.h +++ b/kernel/sched_cpupri.h | |||
@@ -3,8 +3,8 @@ | |||
3 | 3 | ||
4 | #include <linux/sched.h> | 4 | #include <linux/sched.h> |
5 | 5 | ||
6 | #define CPUPRI_NR_PRIORITIES 2+MAX_RT_PRIO | 6 | #define CPUPRI_NR_PRIORITIES (MAX_RT_PRIO + 2) |
7 | #define CPUPRI_NR_PRI_WORDS (CPUPRI_NR_PRIORITIES + BITS_PER_LONG/2)/BITS_PER_LONG | 7 | #define CPUPRI_NR_PRI_WORDS BITS_TO_LONGS(CPUPRI_NR_PRIORITIES) |
8 | 8 | ||
9 | #define CPUPRI_INVALID -1 | 9 | #define CPUPRI_INVALID -1 |
10 | #define CPUPRI_IDLE 0 | 10 | #define CPUPRI_IDLE 0 |