From owner-freebsd-emulation@freebsd.org Sun Sep 20 11:03:33 2015 Return-Path: Delivered-To: freebsd-emulation@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8356EA0316B for ; Sun, 20 Sep 2015 11:03:33 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id 62B8F1937 for ; Sun, 20 Sep 2015 11:03:33 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: by mailman.ysv.freebsd.org (Postfix) id 5FD66A0316A; Sun, 20 Sep 2015 11:03:33 +0000 (UTC) Delivered-To: emulation@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5F6ACA03166 for ; Sun, 20 Sep 2015 11:03:33 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: from mail-wi0-x22c.google.com (mail-wi0-x22c.google.com [IPv6:2a00:1450:400c:c05::22c]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 07CFE1935 for ; Sun, 20 Sep 2015 11:03:32 +0000 (UTC) (envelope-from gljennjohn@gmail.com) Received: by wiclk2 with SMTP id lk2so77949491wic.1 for ; Sun, 20 Sep 2015 04:03:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:in-reply-to:references:reply-to :mime-version:content-type:content-transfer-encoding; bh=wLgyAajeoMUPMl+tgPzeB8OX7KjGMEz3dGEgzoOtYfc=; b=Bc2QLT1l3QpdbL4kOxsqpWnRQx+A8+BZRxkXofA7eYHe7h57iHAgK4zuUsP5L2OTBH TLSrlDNE0KUpZV6VucFZm2Cddh1FAwoe9afwyltkmdIfkIkyytnB8HBlEwB5/ZMO/HmK /M2DX7fEybicHaHEMQHR0u1Kze1IlXYipC/7DTUSb84/2wXyiXNd/MlZhXtBumIo+k+P gBU0GSNm7lbe8STc9/ovLT8LSTvO9RAVvT5WW356EAzrrzyoHUTBuI4vN5ga1ny1h7cE TxwXktZ0038e1izLgDlidZfeJW/bM1ejxMiZsyT6gJdR0TPE89g/2I3sit/JBBEpCZUv ip3Q== X-Received: by 10.194.235.34 with SMTP id uj2mr17174741wjc.90.1442747010903; Sun, 20 Sep 2015 04:03:30 -0700 (PDT) Received: from ernst.home (p578E1AA3.dip0.t-ipconnect.de. [87.142.26.163]) by smtp.gmail.com with ESMTPSA id gk9sm7789252wib.9.2015.09.20.04.03.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 20 Sep 2015 04:03:30 -0700 (PDT) Date: Sun, 20 Sep 2015 13:03:26 +0200 From: Gary Jennejohn To: Mario Lobo Cc: emulation@FreeBSD.org Subject: Re: Linux epoll implementation Message-ID: <20150920130326.4014e853@ernst.home> In-Reply-To: <20150919130625.4d3897f8@Papi> References: <20150919130625.4d3897f8@Papi> Reply-To: gljennjohn@gmail.com X-Mailer: Claws Mail 3.12.0 (GTK+ 2.24.28; amd64-portbld-freebsd11.0) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 20 Sep 2015 11:03:33 -0000 On Sat, 19 Sep 2015 13:06:25 -0300 Mario Lobo wrote: > Hi; > > I'm trying to compile this epoll implementation into the kernel > following > > https://wiki.freebsd.org/linux-kernel > > using the patch provided. > > The patch applies fine but when compiling the kernel, it stops at this: > > /usr/src/sys/modules/linux/../../compat/linux/linux_epoll.c:66:10: > error: implicit declaration of function 'kqueue' is invalid in C99 > [-Werror,-Wimplicit-function-declaration] > return (kqueue(td, &k_args)); > > > That is the only reference to kqueue on the > patched code at /usr/src/sys/compat/linux/ > > This kqueue call is very different from the one provided in man kqueue: > > int kqueue(void); > > so I really ran out of options on finding out what this kqueue call > really is about. > > Would anyone have any pointers on this? > NOTE: I'm referencing HEAD here. epoll() is a system call (syscall), so it will be using the kernel interfaces. The only kqueue-related syscall with the same arguments is sys_kqueue(). Try using that instead. -- Gary Jennejohn