Here is the problem: make KBUILD_VERBOSE= SUBDIRS=/var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv SRCROOT=/var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv CONFIG_MODULE_SIG= -C /usr/src/linux modules make[2]: Entering directory `/usr/src/wireless-testing' CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/linux/SUPDrv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/SUPDrv.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/SUPDrvSem.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/SUPDrvTracer.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/alloc-r0drv.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/initterm-r0drv.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/memobj-r0drv.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/mpnotification-r0drv.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/powernotification-r0drv.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/assert-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/alloc-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/initterm-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/memobj-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/memuserkernel-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/mp-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/mpnotification-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/process-r0drv-linux.o CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/semevent-r0drv-linux.o /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/memobj-r0drv-linux.c: In function ‘rtR0MemObjNativeMapUser’: /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/memobj-r0drv-linux.c:1460:38: error: ‘VM_RESERVED’ undeclared (first use in this function) /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/memobj-r0drv-linux.c:1460:38: note: each undeclared identifier is reported only once for each function it appears in CC [M] /var/tmp/portage/app-emulation/virtualbox-modules-4.2.0-r1/work/vboxdrv/r0drv/linux/semeventmulti-r0drv-linux.o The problem is related to the recent kernel commit http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=314e51b9851b4f4e8ab302243ff5a6fc6147f379
Please report this issue upstream and let us know about the upstram bug report once it was filed.
Created attachment 326932 [details, diff] virtualbox-modules-kernel-3.7-vmreserved.patch I have created a simple patch to solve the problem, tested and working.
I suspect this is a duplicate of: https://bugs.gentoo.org/show_bug.cgi?id=432884
Oh, and there already seems to be a fix for it: https://www.virtualbox.org/changeset/43637/vbox