lkml.org 
[lkml]   [2001]   [Apr]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] Process pinning
Date
In message <20010409170823.C2316@engr.sgi.com> you write:
> Changes to array.c expose cpus_allowed in proc/pid/stat.

Call me old fashioned, but I prefer my bitmasks in hex.

Please also consider changing:

still_running:
c = goodness(prev, this_cpu, prev->active_mm);
next = prev;

to:

still_running:
if (prev & (1 << this_cpu)) {
c = goodness(prev, this_cpu, prev->active_mm);
next = prev;
}
Otherwise, you will keep scheduling a RT process forever on a
disallowed CPU on which it is already running. And even a non-RT
process will stick on its disallowed CPU as long as nothing else runs
there.

Learnt this the hard way from the hotplug CPU patch...
Rusty.
--
Premature optmztion is rt of all evl. --DK
-
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/

\
 
 \ /
  Last update: 2005-03-22 13:25    [from the cache]
©2003-2011 Jasper Spaans