Skip to contentSkip to conversation

kvm-74 release

ANNOUNCE Avi Kivity 5 participants 7 messages Aug 28, 2008 – Sep 2, 2008

Subsystems (2)
lore
Share & tools
lore

Avi Kivity

author
#0 lore raw

The big changes in this release come from upstream qemu: much improved usb support. You can now have qemu automatically assign usb devices to the guest, and performance and reliability should both be improved.

For ia64 users, this is the first release that supports building the kvm external module. 2.6.26 hosts with preempt notifiers enabled are supported.

Changes from kvm-73:
- make real-mode startup state conform to spec
- fix scheduling error in experimental big real mode support
- fix reboot fault handler exception table entry (Eduardo Habkost)
- x86 emulator code cleanup (Roel Kluin)
- fix 'neg r/m' instruction emulation forced to byte size
- fix shadow ptes corruption on i386 hosts running smp guests
- fix kvmtrace ABI breakage (Adrian Bunk)
- enable virtio for ia64
- add generic shadow page table walker
- allocate internal guest memory as MAP_PRIVATE
- don't call get_user_pages(.force=1)
- paves the way for get_user_pages_fast()
- add mov r, imm instructions to the emulator (Mohammed Gamal)
- realmode emulator testsuite
- ia64 external module support (Xiantao Zhang)
- support tap IFF_VNET_HDR (Mark McLoughlin)
- merge qemu-svn
- improved usb support
- usb auto connect/disconnect
- protect against possible corruption during qemu fork() on older hosts (Marcelo Tosatti)

Notes:
If you use the modules bundled with kvm-74, you can use any version
of Linux from 2.6.16 upwards. You may also use kvm-74 userspace with the kvm modules provided by Linux 2.6.22 or above. Some features may only be available in newer releases.

http://kvm.qumranet.com

Signature · 1 line
error compiling committee.c: too many arguments to function
#1 lore raw

Hi,

Given a kernel tree originally built using the O= method, what's the suggested way to build the external modules ?

I've tried giving configure a --kerneldir of both the original tree and the O= tree, along with passing the O= option to make and/or configure. So far without success.

qemu parts all seem to build fine, errors start with:

make -C /home/ilp/kernels/v2.6/linux-2.6.26-org M=`pwd` \
                LINUXINCLUDE="-I`pwd`/include -Iinclude -Iarch/x86/include -I`pwd`/include-compat \
                -include include/linux/autoconf.h \
                -include `pwd`/x86/external-module-compat.h"

make[2]: Entering directory `/home/ilp/kernels/v2.6/linux-2.6.26-org'
LD /home/ilp/kvm/kvm-74/kernel/x86/built-in.o
CC [M] /home/ilp/kvm/kvm-74/kernel/x86/svm.o
In file included from <command-line>:0:
/home/ilp/kvm/kvm-74/kernel/x86/external-module-compat.h:6:28: error: linux/compiler.h: No such file or directory In file included from /home/ilp/kvm/kvm-74/kernel/x86/external-module-compat.h:9,

                 from <command-line>:0:

/home/ilp/kvm/kvm-74/kernel/x86/../external-module-compat-comm.h:12:26: error: linux/string.h: No such file or directory

quickly followed by several screenfuls of stuff due to not being able to find some of the kernel include files.

I don't have enough understanding of kernel makefile magic to see what I'm missing, so any help would be appreciated.

Thanks,
Iain

author
#2 lore raw
Quoted 5 lines · Iain Paton

Hi,

Given a kernel tree originally built using the O= method, what's the suggested way to build the external modules ?

If the kernel was built, installed, and is now running, ./configure; make should suffice. I've never tested this though. Have you tried this?

Quoted 3 lines

I don't have enough understanding of kernel makefile magic to see what I'm missing, so any help would be appreciated.

Me neither.

Signature · 1 line
error compiling committee.c: too many arguments to function
#3 lore raw
Quoted 1 line · Avi Kivity

If the kernel was built, installed, and is now running,

it's not. change control, downtime windows and such like nonsense prevent me from doing things that way. The target systems don't have any development tools installed and the build system will never run the kernel being built. catch 22.

Quoted 2 lines
                                                        ./configure; 

make should suffice. I've never tested this though. Have you tried this?

yes this does work, just not in the environment I'm in.

Quoted 5 lines
Quoted 2 lines

I don't have enough understanding of kernel makefile magic to see what I'm missing, so any help would be appreciated.

Me neither.

Ok, so after some digging it appears that to support building with O= you need some modifications to LINUXINCLUDE within the makefile. Looking at what's done in the toplevel kernel makefile they do the following

# Use LINUXINCLUDE when you must reference the include/ directory. # Needed to be compatible with the O= option

LINUXINCLUDE    := -Iinclude \
                   $(if $(KBUILD_SRC),-Iinclude2 -I$(srctree)/include) \
                   -include include/linux/autoconf.h

KBUILD_SRC is calculated from what's passed in to make by O=

So something like the following change to the KVM makefile works happily. I'm quite sure this isn't the correct way to do it, but perhaps it can point someone with more of a clue than me in the right direction :)

Makefile 2008-09-01 18:51:14.629935513 +0100 renamed from Makefile.org 2008-09-01 18:46:15.272561974 +0100 +3 -1
@@ -36,7 +36,9 @@
 all:: header-link prerequisite
 #      include header priority 1) $LINUX 2) $KERNELDIR 3) include-compat
        $(MAKE) -C $(KERNELDIR) M=`pwd` \
-               LINUXINCLUDE="-I`pwd`/include -Iinclude -Iarch/${ARCH_DIR}/include -I`pwd`/include-compat \
+               LINUXINCLUDE="-I`pwd`/include -Iinclude \
+               $(if $(O),-Iinclude2 -I$(KERNELDIR)/include) \
+               -Iarch/${ARCH_DIR}/include -I`pwd`/include-compat \
                -include include/linux/autoconf.h \
                -include `pwd`/$(ARCH_DIR)/external-module-compat.h"
                "$$@"

With the above patch I can get some working modules using the following:

./configure --kerneldir=/home/ilp/kernels/v2.6/linux-2.6.26-org make O=/home/ilp/kernels/v2.6/linux-2.6.26-dv

#4 lore raw
In reply to Avi Kivity

A few quick notes:

- The extboot.bin regression from kvm-71 (SCSI drives being
unavailable after reboot) is still outstanding.

- kvm (and presumably qemu) doesn't check for fd= parameters pointing
to file descriptor numbers which are not, in fact, open; this results in select() spinning on -EBADF, and associated Bad Things Happening.

author
#5 lore raw
Quoted 5 lines · Charles Duffy

A few quick notes:

- The extboot.bin regression from kvm-71 (SCSI drives being
unavailable after reboot) is still outstanding.

Now fixed.

Quoted 2 lines

- kvm (and presumably qemu) doesn't check for fd= parameters pointing
to file descriptor numbers which are not, in fact, open; this results in select() spinning on -EBADF, and associated Bad Things Happening.

Seems a minor issue; but worth reporting to qemu-devel.

Signature · 1 line
error compiling committee.c: too many arguments to function
#6 lore raw

mån 2008-09-01 klockan 13:36 +0300 skrev Avi Kivity:

Quoted 9 lines
Quoted 5 lines · Charles Duffy

A few quick notes:

- The extboot.bin regression from kvm-71 (SCSI drives being
unavailable after reboot) is still outstanding.

Now fixed.

For what it is worth, I can now confirm the fix. You have no idea the happiness that this is giving me :)

Now if only scsi would work for guest with more than 4GB ram or on BSD ;)

Regards, Henrik Holst
Witsbits AB