From mboxrd@z Thu Jan 1 00:00:00 1970 From: Avi Kivity Subject: Re: [ANNOUNCE] kvm-56 release Date: Thu, 13 Dec 2007 17:29:15 +0200 Message-ID: <47614FCB.6060705@qumranet.com> References: <4761347E.9090806@qumranet.com> <47613F6B.5030508@quicknet.nl> <4761480C.6020204@qumranet.com> <47614E53.2070809@quicknet.nl> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------080400070808060004070002" Cc: kvm-devel To: Pelle Return-path: In-Reply-To: <47614E53.2070809-5JapdU7xTciEVqv0pETR8A@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: kvm-devel-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: kvm.vger.kernel.org This is a multi-part message in MIME format. --------------080400070808060004070002 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Pelle wrote: > Patch applied, rebuild (twice) but still the same error. > Sorry, there was a type in the patch. Please change cpmxchg64 to cmpxchg64 in kernel/external-module-compat.h, or apply the attached corrected patch on a clean kvm-56. > Avi Kivity wrote: >> Pelle wrote: >>> I get the following error when modprobing the new module: >>> >>> WARNING: Error inserting kvm >>> (/lib/modules/2.6.22-14-generic/extra/kvm.ko): Unknown symbol in >>> module, or unknown parameter (see dmesg) >>> kvm: Unknown symbol cmpxchg64 >>> >>> Ubuntu 7.10 32-bits, C2D E6300 >>> >>> >> >> Please try the attached patch. >> >> >> ------------------------------------------------------------------------ >> >> ------------------------------------------------------------------------- >> >> SF.Net email is sponsored by: >> Check out the new SourceForge.net Marketplace. >> It's the best place to buy or sell services >> for just about anything Open Source. >> http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace >> >> ------------------------------------------------------------------------ >> >> _______________________________________________ >> kvm-devel mailing list >> kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org >> https://lists.sourceforge.net/lists/listinfo/kvm-devel -- error compiling committee.c: too many arguments to function --------------080400070808060004070002 Content-Type: text/x-patch; name="cmpxchg64.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="cmpxchg64.patch" diff --git a/kernel/external-module-compat.h b/kernel/external-module-compat.h index ea94f30..1dc5a96 100644 --- a/kernel/external-module-compat.h +++ b/kernel/external-module-compat.h @@ -322,6 +322,28 @@ static inline void __kvm_set_64bit(u64 *ptr, u64 val) #undef set_64bit #define set_64bit __kvm_set_64bit +static inline unsigned long long __kvm_cmpxchg64(volatile void *ptr, + unsigned long long old, + unsigned long long new) +{ + unsigned long long prev; + __asm__ __volatile__(LOCK_PREFIX "cmpxchg8b %3" + : "=A"(prev) + : "b"((unsigned long)new), + "c"((unsigned long)(new >> 32)), + "m"(*__xg(ptr)), + "0"(old) + : "memory"); + return prev; +} + +#define kvm_cmpxchg64(ptr,o,n)\ + ((__typeof__(*(ptr)))__kvm_cmpxchg64((ptr),(unsigned long long)(o),\ + (unsigned long long)(n))) + +#undef cmpxchg64 +#define cmpxchg64(ptr, o, n) kvm_cmpxchg64(ptr, o, n) + #endif #ifndef CONFIG_PREEMPT_NOTIFIERS --------------080400070808060004070002 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ------------------------------------------------------------------------- SF.Net email is sponsored by: Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace --------------080400070808060004070002 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ kvm-devel mailing list kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org https://lists.sourceforge.net/lists/listinfo/kvm-devel --------------080400070808060004070002--