login
Login
/
Register
Search
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2008
»
June
»
4
Re: [PATCH 2/2] sched: fix cpupri priocount
view
thread
!MAILaRCHIVE_VOTE_RePLACE
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From:
Peter Zijlstra <peterz@...>
To: Gregory Haskins <ghaskins@...>
Cc: Ingo Molnar <mingo@...>, Thomas Gleixner <tglx@...>, Steven Rostedt <rostedt@...>, Arnaldo Carvalho de Melo <acme@...>, <linux-kernel@...>, <linux-rt-users@...>
Subject:
Re: [PATCH 2/2] sched: fix cpupri priocount
Date: Wednesday, June 4, 2008 - 5:09 pm
On Wed, 2008-06-04 at 15:04 -0400, Gregory Haskins wrote:
quoted text
> A rounding error was pointed out by Peter Zijlstra which would result > in the structure holding priorities to be off by one. > > Signed-off-by: Gregory Haskins <ghaskins@novell.com> > CC: Peter Zijlstra <peterz@infradead.org> > --- > > kernel/sched_cpupri.h | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/kernel/sched_cpupri.h b/kernel/sched_cpupri.h > index 16d29b9..817c55c 100644 > --- a/kernel/sched_cpupri.h > +++ b/kernel/sched_cpupri.h > @@ -4,7 +4,7 @@ > #include <linux/sched.h> > > #define CPUPRI_NR_PRIORITIES 2+MAX_RT_PRIO > -#define CPUPRI_NR_PRI_WORDS CPUPRI_NR_PRIORITIES/BITS_PER_LONG > +#define CPUPRI_NR_PRI_WORDS (CPUPRI_NR_PRIORITIES + BITS_PER_LONG/2)/BITS_PER_LONG
(33 + 16) / 32 = 49 / 32 = 1 So its still wrong ;-) Please use DECLARE_BITMAP and or BITS_TO_LONGS to avoid these issues. --
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH 0/2] sched: hotplug and cpupri fixes (v2)
, Gregory Haskins
, (Wed Jun 4, 3:03 pm)
[PATCH 2/2] sched: fix cpupri priocount
, Gregory Haskins
, (Wed Jun 4, 3:04 pm)
Re: [PATCH 2/2] sched: fix cpupri priocount
, Peter Zijlstra
, (Wed Jun 4, 5:09 pm)
Re: [PATCH 2/2] sched: fix cpupri priocount
, Gregory Haskins
, (Wed Jun 4, 5:52 pm)
RE: [PATCH 2/2] sched: fix cpupri priocount
, Rune Torgersen
, (Wed Jun 4, 5:35 pm)
[PATCH 1/2] sched: fix cpupri hotplug support
, Gregory Haskins
, (Wed Jun 4, 3:04 pm)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Greg KH
[GIT PATCH] driver core patches against 2.6.24
debian developer
Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3
Vu Pham
Re: [Scst-devel] Integration of SCST in the mainstream Linux kernel
Adrian Bunk
Re: Linux 2.6.21
git
:
linux-netdev
:
Gerrit Renker
[PATCH 15/37] dccp: Set per-connection CCIDs via socket options
Jarek Poplawski
[PATCH] pkt_sched: Destroy gen estimators under rtnl_lock().
Radu Rendec
Endianness problem with u32 classifier hash masks
Benjamin Herrenschmidt
[PATCH 0/11] ibm_newemac: Candidate patches for 2.6.25
openbsd-misc
:
Colocation donated by:
Who's online
There are currently
2 users
and
768 guests
online.
Online users
jraval618
creativewebs279
Syndicate