From mboxrd@z Thu Jan 1 00:00:00 1970 From: Remy Horton Subject: Re: [PATCH v2 1/3] eal: fix keep alive header for C++ Date: Tue, 16 Feb 2016 10:16:35 +0000 Message-ID: <56C2F703.2020801@intel.com> References: <1454691969-25734-1-git-send-email-thomas.monjalon@6wind.com> <1455606865-22680-1-git-send-email-thomas.monjalon@6wind.com> <1455606865-22680-2-git-send-email-thomas.monjalon@6wind.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable Cc: dev@dpdk.org To: Thomas Monjalon , pablo.de.lara.guarch@intel.com, declan.doherty@intel.com Return-path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id A2D4C9A8A for ; Tue, 16 Feb 2016 11:17:32 +0100 (CET) In-Reply-To: <1455606865-22680-2-git-send-email-thomas.monjalon@6wind.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Suspect this will introduce an extra indirection and call/return into=20 the generated code, but can't think of any alternative that doesn't=20 potentially break source compatibility.. On 16/02/2016 07:14, Thomas Monjalon wrote: > When built in a C++ application, the keepalive include fails: > > rte_keepalive.h:142:41: error: =E2=80=98ALIVE=E2=80=99 was not declared= in this scope > keepcfg->state_flags[rte_lcore_id()] =3D ALIVE; > ^ > C++ requires to use a scope operator to access an enum inside a struct. > There was also a namespace issue for the values (no RTE prefix). > The solution is to move the struct and related code out of the header f= ile. > > Fixes: 75583b0d1efd ("eal: add keep alive monitoring") > > Signed-off-by: Thomas Monjalon Acked-by: Remy Horton