Kernel compiling problem, connected with jiffies.h
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Kernel compiling problem, connected with jiffies.h
Hello.
I'am compiling linux kernel 2.6.10 with 2.6.10-ac12 patch. I've configured it and so on. As i'm trying to compile it with make bzImage command, i get this error message:
Code:
CHK include/linux/version.h
CC arch/i386/kernel/asm-offsets.s
In file included from include/linux/sched.h:12,
from arch/i386/kernel/asm-offsets.c:7:
include/linux/jiffies.h:42:3: #error You lose.
In file included from include/linux/sched.h:12,
from arch/i386/kernel/asm-offsets.c:7:
include/linux/jiffies.h: In function `timespec_to_jiffies':
include/linux/jiffies.h:305: error: `SHIFT_HZ' undeclared (first use in this function)
include/linux/jiffies.h:305: error: (Each undeclared identifier is reported only once
include/linux/jiffies.h:305: error: for each function it appears in.)
include/linux/jiffies.h: In function `timeval_to_jiffies':
include/linux/jiffies.h:344: error: `SHIFT_HZ' undeclared (first use in this function)
include/linux/jiffies.h: In function `jiffies_to_clock_t':
include/linux/jiffies.h:367: warning: division by zero
make[1]: *** [arch/i386/kernel/asm-offsets.s] Error 1
make: *** [arch/i386/kernel/asm-offsets.s] Error 2
Andy ideas what's wrong and how to solve the problem?
I'm compiling the kernel with this patch, because i need ITE IT8212 raid driver support.
I tried a little bit of this an a little bit of that. I found out, that my problem was in undefined HZ, which had to be defined in /usr/src/linux/include/linux/asm/param.h. I took a look at the code there and changed the line with define HZ (i commented previous value in and replaced it with 100):
Code:
#ifdef __KERNEL__
# define HZ 100 /*(CONFIG_X86_HZ)*/
# define USER_HZ 100 /* .. some user interfaces are in "ticks" */
# define CLOCKS_PER_SEC (USER_HZ) /* like times() */
#endif
Does somebody know which value does CONFIG_X86_HZ take here?
When configuring your kernel, there is 'Timer frequency' option
under 'Processor type and features' where you can select
100, 250, or 1000, or as you discovered, you can edit param.h
by hand. For x86 it was 100 by default in 2.2 and 2.4 kernels,
but since recently it has been easier to change. I'm looking
at the 2.6.15.x, so it may not be exactly the same in your 2.6.10.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.