From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bernhard Held Subject: Re: [PATCH 04/13] qemu-kvm: Remove eventfd compat header Date: Sun, 03 Jul 2011 11:46:51 +0200 Message-ID: <4E103A8B.70602@mgpi.de> References: <20110628110908.GB5661@redhat.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------050001020105040308080206" Cc: Jan Kiszka , Avi Kivity , Marcelo Tosatti , kvm@vger.kernel.org, Alex Williamson To: kvm@vger.kernel.org Return-path: Received: from lo.gmane.org ([80.91.229.12]:48705 "EHLO lo.gmane.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755273Ab1GCJrI (ORCPT ); Sun, 3 Jul 2011 05:47:08 -0400 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1QdJGZ-0001Ja-IG for kvm@vger.kernel.org; Sun, 03 Jul 2011 11:47:03 +0200 Received: from ppp-188-174-93-241.dynamic.mnet-online.de ([188.174.93.241]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 03 Jul 2011 11:47:03 +0200 Received: from bheld by ppp-188-174-93-241.dynamic.mnet-online.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sun, 03 Jul 2011 11:47:03 +0200 In-Reply-To: <20110628110908.GB5661@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: This is a multi-part message in MIME format. --------------050001020105040308080206 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Am 28.06.2011 13:09, schrieb Michael S. Tsirkin: > On Mon, Jun 27, 2011 at 08:19:47PM +0200, Jan Kiszka wrote: >> From: Jan Kiszka >> >> No longer used. >> >> Signed-off-by: Jan Kiszka > > I think it's actually handy to build on old systems which have > a recent enough kernel but not the header. Yep, I'm running recent qemu-kvm and kernels on CentOS 5.6. The current eventfd.h was handy in the beginning, but some day I had big troubles with crashing qemu-kvm. It turned out that I had to switch from eventfd to eventfd2. IIRC the old eventfd doesn't care about the flags. My version of eventfd.h is attached. Bernhard >> --- >> compat/sys/eventfd.h | 13 ------------- >> 1 files changed, 0 insertions(+), 13 deletions(-) >> delete mode 100644 compat/sys/eventfd.h >> >> diff --git a/compat/sys/eventfd.h b/compat/sys/eventfd.h >> deleted file mode 100644 >> index f55d96a..0000000 >> --- a/compat/sys/eventfd.h >> +++ /dev/null >> @@ -1,13 +0,0 @@ >> -#ifndef _COMPAT_SYS_EVENTFD >> -#define _COMPAT_SYS_EVENTFD >> - >> -#include >> -#include >> - >> - >> -static inline int eventfd (int count, int flags) >> -{ >> - return syscall(SYS_eventfd, count, flags); >> -} >> - >> -#endif >> -- >> 1.7.1 > -- > To unsubscribe from this list: send the line "unsubscribe kvm" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > --------------050001020105040308080206 Content-Type: text/x-chdr; name="eventfd.h" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="eventfd.h" #ifndef _COMPAT_SYS_EVENTFD #define _COMPAT_SYS_EVENTFD #include #include /* Flags for signalfd. */ enum { EFD_SEMAPHORE = 1, #define EFD_SEMAPHORE EFD_SEMAPHORE EFD_CLOEXEC = 02000000, #define EFD_CLOEXEC EFD_CLOEXEC EFD_NONBLOCK = 04000 #define EFD_NONBLOCK EFD_NONBLOCK }; #ifndef __NR_eventfd2 #if defined(__x86_64__) #define __NR_eventfd2 290 #elif defined(__i386__) #define __NR_eventfd2 328 #else #error Cannot detect your architecture! #endif #endif static inline int eventfd (int count, int flags) { return syscall(__NR_eventfd2, count, flags); } #endif --------------050001020105040308080206--