From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by dpdk.org (Postfix) with ESMTP id BAB63101B for ; Tue, 21 Mar 2017 08:12:24 +0100 (CET) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C407E7E9E2; Tue, 21 Mar 2017 07:12:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com C407E7E9E2 Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=pagupta@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com C407E7E9E2 Received: from colo-mx.corp.redhat.com (unknown [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B71B483807; Tue, 21 Mar 2017 07:12:24 +0000 (UTC) Received: from zmail21.collab.prod.int.phx2.redhat.com (zmail21.collab.prod.int.phx2.redhat.com [10.5.83.24]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 95C994E9BC; Tue, 21 Mar 2017 07:12:24 +0000 (UTC) Date: Tue, 21 Mar 2017 03:12:23 -0400 (EDT) From: Pankaj Gupta To: Ferruh Yigit Cc: Jerin Jacob , dev@dpdk.org Message-ID: <1329679947.4861299.1490080343155.JavaMail.zimbra@redhat.com> In-Reply-To: <20170320112208.7941-1-ferruh.yigit@intel.com> References: <20170320112208.7941-1-ferruh.yigit@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Originating-IP: [10.65.193.72] Thread-Topic: fix build with kernel 4.11 Thread-Index: 2B09PZ8CvzMwTlpZI1hKHzb9RyziPA== X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Tue, 21 Mar 2017 07:12:24 +0000 (UTC) Subject: Re: [dpdk-dev] [PATCH] kni: fix build with kernel 4.11 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 21 Mar 2017 07:12:25 -0000 Hello, >=20 > compile error: > .../build/build/lib/librte_eal/linuxapp/kni/kni_net.c:124:6: > error: implicit declaration of function =E2=80=98signal_pending=E2=80=99 > [-Werror=3Dimplicit-function-declaration] > if (signal_pending(current) || ret_val <=3D 0) { > ^~~~~~~~~~~~~~ >=20 > Linux 4.11 moves signal function declarations to its own header file: > Linux: 174cd4b1e5fb ("sched/headers: Prepare to move signal wakeup & > sigpending methods from into ") >=20 > User new header file "linux/sched/signal.h" to fix build error. >=20 > Reported-by: Jerin Jacob > Signed-off-by: Ferruh Yigit > --- > lib/librte_eal/linuxapp/kni/compat.h | 6 ++++++ > lib/librte_eal/linuxapp/kni/kni_dev.h | 6 ++++++ > 2 files changed, 12 insertions(+) >=20 > diff --git a/lib/librte_eal/linuxapp/kni/compat.h > b/lib/librte_eal/linuxapp/kni/compat.h > index 78da08e..d96275a 100644 > --- a/lib/librte_eal/linuxapp/kni/compat.h > +++ b/lib/librte_eal/linuxapp/kni/compat.h > @@ -2,6 +2,8 @@ > * Minimal wrappers to allow compiling kni on older kernels. > */ > =20 > +#include > + > #ifndef RHEL_RELEASE_VERSION > #define RHEL_RELEASE_VERSION(a, b) (((a) << 8) + (b)) > #endif > @@ -67,3 +69,7 @@ > =09(LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 34))) > #undef NET_NAME_UNKNOWN > #endif > + > +#if LINUX_VERSION_CODE >=3D KERNEL_VERSION(4, 11, 0) > +#define HAVE_SIGNAL_FUNCTIONS_OWN_HEADER > +#endif > diff --git a/lib/librte_eal/linuxapp/kni/kni_dev.h > b/lib/librte_eal/linuxapp/kni/kni_dev.h > index 002e5fa..72385ab 100644 > --- a/lib/librte_eal/linuxapp/kni/kni_dev.h > +++ b/lib/librte_eal/linuxapp/kni/kni_dev.h > @@ -30,9 +30,15 @@ > #endif > #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt > =20 > +#include "compat.h" > + > #include > #include > +#ifdef HAVE_SIGNAL_FUNCTIONS_OWN_HEADER > +#include > +#else > #include > +#endif > #include > #include > #include > -- > 2.9.3 This patch fixes build error of DPDK with linux kernel version 4.11.0-rc2 f= or me. Tested-by:pagupta@redhat.com >=20 >=20