On Sun, Dec 02, 2001 at 02:59:19AM +0200, Shaul Karl wrote:
> > On Thu, Nov 29, 2001 at 09:27:45PM +0200, Official Flamer/Cabal NON-Leader wrote:
> > > On Thu, Nov 29, 2001 at 12:10:17PM +0200, Shachar Shemesh wrote:
> > > > [EMAIL PROTECTED] wrote:
> > > > 
> > > > >In a box with 2 CPUs, I am using RedHat kernel 2.4.7.
> > > > >1) Is it possible to enable/disable, by software means, a specific CPU 
> > > > >(cpu 0 | cpu 1) ?
> > > > >
> > > > >2) While both CPUs are enabled, can we enforce a program to run ONLY 
> > > > >on a specific CPU ?
> > > 
> > > As far as I know, 1 is NO.
> > > 
> > > The short answer to 2 is also no. The slighty longer one is that, to the
> > > best of my knowledge, CPU affinity is not in the kernel but I remember
> > > Jseeing references to building it, somewhere.
> > > 
> > > It should be possible to bolt something very crude onto the current
> > > scheduler, but it is not a trivial effort to do it properly...
> > .
> > .
> > 
> > There is a an uncomplanied-about patch for the 2.4/2.5 series.
> > Actually there are two patches that differ only in their interface:
> > Robert Love wants is in /proc, and Rik van Riel (I think) wants it
> > as a system call. This issue alone is bound to keep the patches
> > in the center of a flamewar for the next six months or so, and 
> > therefore out of the kernel, but you can try searching the recent 
> > list archives for it and apply it in the privacy of your own 
> > /usr/src.
> > 
> 
> 
> Have you got an opinion about what is a better choice (system call or 
> /proc)?

Better? Functionally, they're exactly the same. What's the interface 
like is only a matter of taste, and personally I prefer system calls 
(more consistent with the way you modify other process properties in
Unix). I'm just saying that if you apply any of the patches, the 
interface might change under your feet -- the /proc entry name might 
be different, the system call name and arguments might not be the 
same, and so on.

=================================================================
To unsubscribe, send mail to [EMAIL PROTECTED] with
the word "unsubscribe" in the message body, e.g., run the command
echo unsubscribe | mail [EMAIL PROTECTED]

Reply via email to