Alexander Graf wrote:
On 18.10.2008, at 12:51, Avi Kivity wrote:
Alexander Graf wrote:
So if I don't select kvm in the kernel (either as module or compiled
in) I can't build an external module providing kvm's functionality?
That doesn't seem really useful to me...
The external module hackball should detect that you don't have
CONFIG_MMU_NOTIFIERS set and supply some compatibility glue. What
error are you seeing?
Basically struct mmu_notifier is not found, but requested by the code:
rm -f include/asm include-compat/asm
ln -sf asm-x86 include/asm
ln -sf asm-x86 include-compat/asm
make -C /usr/src/linux-obj/i586/default M=`pwd` \
LINUXINCLUDE="-I`pwd`/include -Iinclude \
-Iinclude2 -I/lib/modules/2.6.27.1-2-default/source/include \
-Iarch/x86/include -I`pwd`/include-compat \
-include include/linux/autoconf.h \
-include `pwd`/x86/external-module-compat.h "
make[1]: Entering directory `/usr/src/linux-2.6.27.1-2-obj/i386/default'
make -C ../../../linux-2.6.27.1-2
O=/usr/src/linux-2.6.27.1-2-obj/i386/default/.
LD
/usr/src/packages/BUILD/kvm-77/suse-kernel/default/x86/built-in.o
CC [M] /usr/src/packages/BUILD/kvm-77/suse-kernel/default/x86/svm.o
In file included from
/usr/src/packages/BUILD/kvm-77/suse-kernel/default/x86/svm.c:16:
/usr/src/packages/BUILD/kvm-77/suse-kernel/default/include/linux/kvm_host.h:128:
error: field 'mmu_notifier' has incomplete type
make[5]: ***
[/usr/src/packages/BUILD/kvm-77/suse-kernel/default/x86/svm.o] Error 1
make[4]: *** [/usr/src/packages/BUILD/kvm-77/suse-kernel/default/x86]
Error 2
make[3]: ***
[_module_/usr/src/packages/BUILD/kvm-77/suse-kernel/default] Error 2
make[2]: *** [sub-make] Error 2
make[1]: *** [all] Error 2
make[1]: Leaving directory `/usr/src/linux-2.6.27.1-2-obj/i386/default'
make: *** [all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.20019 (%build)
When I remove the struct references it breaks later on due to
missing(?) inline functions.
Yes, there is an alternate definition in
kernel/include-compat/linux/mmu_notifier.h, but it doesn't get included
since the host's mmu_notifier.h has priority; and the host doesn't
define the structure if !CONFIG_MMU_NOTIFIERS.
I recommend configuring the host with KVM and throwing the modules away
if you want the external module. You'll get better functionality so
it's worth the minor hassle.
--
error compiling committee.c: too many arguments to function
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html