lkml.org 
[lkml]   [2000]   [Jul]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
Subject[PATCH] Re: Compile Errors on 2.4.0-test3 final
> I believe this is in a file that everyone has compiled in, so pardon me for not 

True, but I looked at the source (I get the same error) and for SMP
this function is empty.

I checked out the 'priority' field, and found out that it has been
renamed to 'nice'. So the fix is to rename the field in the code. Easy
as that :-) The #define 'DEF_PRIORITY' has been renamed to DEF_NICE.


My theory: Someone decided to rename the field, did so in sched.h, then
compiled their kernel to catch all uses of the field in code and rename
them.
Unfortunately, this way some places in UP-only code were overlooked!


Here's a patch:

--- kernel/timer.c.orig Tue Jul 11 09:00:31 2000
+++ kernel/timer.c Tue Jul 11 09:02:44 2000
@@ -577,7 +577,7 @@
p->counter = 0;
p->need_resched = 1;
}
- if (p->priority < DEF_PRIORITY)
+ if (p->nice < DEF_NICE)
kstat.cpu_nice += user_tick;
else
kstat.cpu_user += user_tick;


This made the kernel compile with my .config, however, you might come
across other places where p->priority is used! There is a patch from
Adam J. Richter that fixes many more places, and gives an explanation
of the change.


Note to Adam J. Richter:
I looked at the patch you posted, and I believe you left out this
instance of p->priority. :-)


--Tim



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

\
 
 \ /
  Last update: 2005-03-22 13:57    [W:0.067 / U:0.328 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site