When I include CONFIG_HW_RANDOM in my kernel configuration the kernel fails to compile: make[3]: Entering directory `/usr/src/linux-2.4.22-gentoo-r2/drivers/char' gcc -D__KERNEL__ -I/usr/src/linux-2.4.22-gentoo-r2/include -Wall -Wstrict-prototypes -Wno-trigraphs -O2 -fno-strict-aliasing -fno-common -finline-limit=2000 -fomit-frame-pointer -pipe -mpreferred-stack-boundary=2 -march=athlon-xp -nostdinc -iwithprefix include -DKBUILD_BASENAME=hw_random -c -o hw_random.o hw_random.c hw_random.c: In function `via_init': hw_random.c:433: `MSR_VIA_RNG' undeclared (first use in this function) hw_random.c:433: (Each undeclared identifier is reported only once hw_random.c:433: for each function it appears in.) hw_random.c: In function `via_cleanup': hw_random.c:459: `MSR_VIA_RNG' undeclared (first use in this function) hw_random.c: In function `rng_init': hw_random.c:592: `cpu_has_xstore' undeclared (first use in this function) make[3]: *** [hw_random.o] Error 1 make[3]: Leaving directory `/usr/src/linux-2.4.22-gentoo-r2/drivers/char' make[2]: *** [first_rule] Error 2 make[2]: Leaving directory `/usr/src/linux-2.4.22-gentoo-r2/drivers/char' make[1]: *** [_subdir_char] Error 2 make[1]: Leaving directory `/usr/src/linux-2.4.22-gentoo-r2/drivers' make: *** [_dir_drivers] Error 2 It makes no diference whether the feature is compiled into the kernel or as a module. With CONFIG_HW_RANDOM=n the kernel compiles as usual. Reproducible: Always Steps to Reproduce: 1. Include CONFIG_HW_RANDOM in the kernel configuration (it's in the 'Character devices' section) 2. make dep && make bzImage && make modules Actual Results: see the Deatils section Expected Results: Well, the kernel should have compiled, obviously.
Created attachment 22542 [details] my kernel configuration
try picking only one of of the hardware random drivers
# CONFIG_AMD_RNG is not set # CONFIG_INTEL_RNG is not set CONFIG_HW_RANDOM=y - still fails with the same error. I have actually tried that before, now I tried it once again to be sure. It does not make a difference.
I can confirm this same thing. The gentoo-sources patchset for 2.4.22-r1 included a patch to include/asm-i386/msr.h that defined MSR_VIA_RNG. This patch to msr.h is no longer present in the gentoo-sources patchset for 2.4.22-r2.
Hmm, that may have been backed out when I dropped the patch that was causing the apic not to work. It'll be fixed in the next release.
*** Bug 36730 has been marked as a duplicate of this bug. ***
should be fixed in -r4