Page 1 of 1

[SOLVED] vboxnetflt won't compile on kernel 2.6.30-rc4

Posted: 7. May 2009, 07:17
by nalf38
I run OpenSuse 11.1 and use a custom vanilla kernel, 2.6.30-rc4. Vboxdrv compiles just fine but vboxnetflt will not compile.

Here is the error message:
linux-pdjn:/home/nlarson # /etc/init.d/vboxdrv setup
Stopping VirtualBox kernel module done
Removing old VirtualBox kernel module done
Recompiling VirtualBox kernel module failed
(Look at /var/log/vbox-install.log to find out what went wrong)

And the output of vbox-install.log (after the successful build of 'vboxdrv'):

make KBUILD_VERBOSE=1 -C /lib/modules/2.6.30-rc4-nick/build SUBDIRS=/tmp/vbox.2 SRCROOT=/tmp/vbox.2 modules
test -e include/linux/autoconf.h -a -e include/config/auto.conf || ( \
echo; \
echo " ERROR: Kernel configuration is invalid."; \
echo " include/linux/autoconf.h or include/config/auto.conf are missing."; \
echo " Run 'make oldconfig && make prepare' on kernel src to fix it."; \
echo; \
/bin/false)
mkdir -p /tmp/vbox.2/.tmp_versions ; rm -f /tmp/vbox.2/.tmp_versions/*
make -f scripts/Makefile.build obj=/tmp/vbox.2
gcc -Wp,-MD,/tmp/vbox.2/linux/.VBoxNetFlt-linux.o.d -nostdinc -isystem /usr/lib/gcc/i586-suse-linux/4.3/include -Iinclude -I/usr/src/linux-2.6.30-rc4-nick/arch/x86/include -include include/linux/autoconf.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Os -m32 -msoft-float -mregparm=3 -freg-struct-return -mpreferred-stack-boundary=2 -march=i686 -mtune=core2 -Wa,-mtune=generic32 -ffreestanding -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -pipe -Wno-sign-compare -fno-asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -fno-stack-protector -fomit-frame-pointer -Wdeclaration-after-statement -Wno-pointer-sign -fwrapv -I/lib/modules/2.6.30-rc4-nick/build/include -I/tmp/vbox.2/ -I/tmp/vbox.2/include -I/tmp/vbox.2/r0drv/linux -D__KERNEL__ -DMODULE -DRT_OS_LINUX -DIN_RING0 -DIN_RT_R0 -DIN_SUP_R0 -DVBOX -DRT_WITH_VBOX -DVBOX_WITH_HARDENING -DRT_ARCH_X86 -DVBOX_WITH_64_BITS_GUESTS -DMODULE -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(VBoxNetFlt_linux)" -D"KBUILD_MODNAME=KBUILD_STR(vboxnetflt)" -c -o /tmp/vbox.2/linux/.tmp_VBoxNetFlt-linux.o /tmp/vbox.2/linux/VBoxNetFlt-linux.c
/tmp/vbox.2/linux/VBoxNetFlt-linux.c: In function 'vboxNetAdpNetDevInit':
/tmp/vbox.2/linux/VBoxNetFlt-linux.c:225: error: 'struct net_device' has no member named 'open'
/tmp/vbox.2/linux/VBoxNetFlt-linux.c:226: error: 'struct net_device' has no member named 'stop'
/tmp/vbox.2/linux/VBoxNetFlt-linux.c:227: error: 'struct net_device' has no member named 'hard_start_xmit'
/tmp/vbox.2/linux/VBoxNetFlt-linux.c:228: error: 'struct net_device' has no member named 'get_stats'
make[2]: *** [/tmp/vbox.2/linux/VBoxNetFlt-linux.o] Error 1
make[1]: *** [_module_/tmp/vbox.2] Error 2
make: *** [vboxnetflt] Error 2
Has anyone experienced this yet? Is there something in my kernel config that I should change? I can post that, too, if anyone thinks that would be helpful.

Any help is appreciated.

Re: vboxnetflt won't compile on kernel 2.6.30-rc4

Posted: 7. May 2009, 07:37
by nalf38
I successfully compiled vboxnetflt. In this particular kernel, I unchecked a lot of "provide legacy /proc/foo" and other so-called legacy stuff. I recompiled them back in, and vboxnetflt compiled fine.

However, I would like to know which particular kernel setting is the key, out of the 5 or 6 things I compiled back in.

Here's what I took out in my original 2.6.30-rc4 recently compiled back in:

* Deprecated /proc/acpi files
* Deprecated power /proc/acpi directories
* Deprecated /proc/acpi/event
* Enable Deprecated pci_find_* API
* legacy proc/ide support
* legacy /proc/scsi support
* Enable unused/obsolete exported symbols

It would be nice if I could leave out including the legacy /proc/ide and /scsi stuff. Maybe it's my imagination, but I find my system to be more responsive without them.

Re: vboxnetflt won't compile on kernel 2.6.30-rc4

Posted: 7. May 2009, 20:54
by Sasquatch
I don't know about OpenSuSE, but Ubuntu also provides the latest vanilla kernel through their own PPA and I had no issues with it for VB 2.2.2. I do however have issues with my video card module, nVidia, but that is for somewhere else. Because of that, I can't run the 2.6.30-rc4 kernel, else I would on my PC. Haven't run VB on my laptop now though, which does boot 2.6.30-rc4 without issues.
So, take a look at the VB build log and switches. You can find it on http://kernel.ubuntu.com/~kernel-ppa/mainline/.

Re: vboxnetflt won't compile on kernel 2.6.30-rc4

Posted: 8. May 2009, 08:01
by nalf38
Thanks for the links. I don't get my kernels from any OpenSuse repository; I download them from kernel.org and compile them myself with my own custom .config. My worry was that I took something important out of the config that would cause 'vboxnetflt' to not compile. I'm going to ahead and call this solved, though.