From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jonas Pfoh Subject: Re: compiling with kvm-kmod Date: Fri, 24 Jan 2014 13:39:23 +0100 Message-ID: <52E25EFB.2000505@sec.in.tum.de> References: <52E14495.50501@sec.in.tum.de> <52E15D28.3060101@siemens.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: QUOTED-PRINTABLE To: Jan Kiszka , "kvm@vger.kernel.org" Return-path: Received: from mail-out1.informatik.tu-muenchen.de ([131.159.0.8]:47161 "EHLO smtp1.informatik.tu-muenchen.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752210AbaAXMjb (ORCPT ); Fri, 24 Jan 2014 07:39:31 -0500 In-Reply-To: <52E15D28.3060101@siemens.com> Sender: kvm-owner@vger.kernel.org List-ID: Thanks for the quick fix, I found that the modules build, but I still h= ave a problem loading the module due to the fact that kvm_vfio_ops rema= ins undefined in the kvm module. Below is the patch that I used to fix= the issue if it is helpful. -Jonas ---- diff --git a/x86/Kbuild b/x86/Kbuild index d75b756..637b3b1 100644 --- a/x86/Kbuild +++ b/x86/Kbuild @@ -1,7 +1,7 @@ obj-m :=3D kvm.o kvm-intel.o kvm-amd.o kvm-objs :=3D kvm_main.o x86.o mmu.o emulate.o irq.o i8259.o pmu.o \ lapic.o ioapic.o preempt.o i8254.o coalesced_mmio.o irq_comm.o= \ - eventfd.o compat-x86.o async_pf.o cpuid.o irqchip.o \ + eventfd.o compat-x86.o async_pf.o cpuid.o irqchip.o vfio.o\ ../external-module-compat.o ifeq ($(CONFIG_IOMMU_API)$(CONFIG_PCI),yy) kvm-objs +=3D assigned-dev.o iommu.o On 23.01.2014 19:19, Jan Kiszka wrote: > On 2014-01-23 17:34, Jonas Pfoh wrote: >> Hello, >> >> I am currently working on a project involving KVM and have been maki= ng use Jan's kvm-kmod repository. I receive the below error when I att= empt to compile with the most recent version. My question is simply if= this is something anyone is aware of or has any suggestions for before= I go poking around? =20 >> >> I am compiling against a 3.13.0 mainline vanilla kernel and am using= the master branch (3d923a3) of Jan's kvm-kmod repo which seems to be s= yncing from kvm commit 7650b68. >> >> Thanks and regards, >> Jonas Pfoh >> >> make -C /lib/modules/3.13.0/build M=3D`pwd` \ >> LINUXINCLUDE=3D"-I`pwd`/include -I`pwd`/include/uapi= -Iinclude \ >> -Iinclude/uapi -Iarch/x86/include -Iarch/x8= 6/include/uapi \ >> -Iinclude/generated/uapi -Iarch/x86/include/= generated \ >> -Iarch/x86/include/generated/uapi \ >> -I`pwd`/include-compat -I`pwd`/x86 \ >> -include include/generated/autoconf.h \ >> -include `pwd`/x86/external-module-compat.h"= \ >> "$@" >> make[1]: Entering directory `/usr/src/linux-3.13' >> CC [M] /local/repos/kvm-kmod/x86/svm.o >> In file included from include/linux/device.h:29:0, >> from include/linux/node.h:17, >> from include/linux/cpu.h:16, >> from /local/repos/kvm-kmod/x86/../external-module-c= ompat-comm.h:15, >> from /local/repos/kvm-kmod/x86/external-module-comp= at.h:45, >> from :0: >> include/linux/gfp.h: In function =91gfp_zonelist=92: >> include/linux/gfp.h:272:2: error: implicit declaration of function =91= IS_ENABLED=92 [-Werror=3Dimplicit-function-declaration] >> if (IS_ENABLED(CONFIG_NUMA) && unlikely(flags & __GFP_THISNODE)) >> ^ >> cc1: some warnings being treated as errors >> make[3]: *** [/local/repos/kvm-kmod/x86/svm.o] Error 1 >> make[2]: *** [/local/repos/kvm-kmod/x86] Error 2 >> make[1]: *** [_module_/local/repos/kvm-kmod] Error 2 >> make[1]: Leaving directory `/usr/src/linux-3.13' >> make: *** [all] Error 2 >=20 > That's likely a kernel issue: not all required headers are pulled by = gfp.h. >=20 > It's worked around now with 2b06046. >=20 > Thanks, > Jan >=20