How is the kernel version set when compiling modules

Richard Skelton <Richard.Skelton-d0qZbvYSIPpWk0Htik3J/[email protected]> Wed, 14 Jul 2004 17:49:45 +0100
Newsgroups gmane.linux.admin.managers
Organization Infineon Technologies
Message-ID <[email protected]>
Hi,
I am trying to build the bcm5700.o module and it will not install as it 
thinks the kernel version is wrong see below.
Where dose make get the kernel information from?

[root@brslcs13 src]# make
gcc -DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 
-DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT 
-DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -O6 
-I/lib/modules/2.4.20-28.7bigmem/build/include   -c -o b57um.o b57um.c
gcc -DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 
-DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT 
-DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -O6 
-I/lib/modules/2.4.20-28.7bigmem/build/include   -c -o b57proc.o b57proc.c
gcc -DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 
-DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT 
-DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -O6 
-I/lib/modules/2.4.20-28.7bigmem/build/include   -c -o tigon3.o tigon3.c
gcc -DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 
-DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT 
-DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -O6 
-I/lib/modules/2.4.20-28.7bigmem/build/include   -c -o autoneg.o autoneg.c
gcc -DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 
-DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT 
-DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -O6 
-I/lib/modules/2.4.20-28.7bigmem/build/include   -c -o 5701rls.o 5701rls.c
gcc -DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 
-DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT 
-DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -O6 
-I/lib/modules/2.4.20-28.7bigmem/build/include   -c -o tcp_seg.o tcp_seg.c
ld -i b57um.o b57proc.o tigon3.o autoneg.o 5701rls.o tcp_seg.o -o bcm5700.o
[root@brslcs13 src]# /sbin/insmod bcm5700.o
bcm5700.o: kernel-module version mismatch
        bcm5700.o was compiled for kernel version 2.4.20-28.7
        while this kernel is version 2.4.20-28.7bigmem.
[root@brslcs13 src]# uname -a
Linux brslcs13 2.4.20-28.7bigmem #1 SMP Thu Dec 18 11:04:21 EST 2003 
i686 unknown
[root@brslcs13 src]# rpm -q -a|grep kernel
kernel-enterprise-2.4.7-10
kernel-source-2.4.20-28.7
kernel-smp-2.4.20-28.7
kernel-2.4.20-28.7
kernel-bigmem-2.4.20-28.7
kernel-headers-2.4.7-10

-- 



Cheers

Richard Skelton
Richard.Skelton-d0qZbvYSIPpWk0Htik3J/[email protected]
Infineon Technologies UK Ltd
Infineon House
Great Western Court
Hunts Ground Road
Stoke Gifford
Bristol
BS32 8HP
Tel +44(0)117 9528808
_______________________________________________
LinuxManagers mailing list - http://www.linuxmanagers.org
submissions: LinuxManagers-35TzE1X9F6582KRnZfj+bdi2O/[email protected]
subscribe/unsubscribe: http://www.linuxmanagers.org/mailman/listinfo/linuxmanagers