From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-io1-f67.google.com (mail-io1-f67.google.com [209.85.166.67]) by dpdk.org (Postfix) with ESMTP id 66D881B120 for ; Mon, 14 Jan 2019 19:30:01 +0100 (CET) Received: by mail-io1-f67.google.com with SMTP id x6so18420580ioa.9 for ; Mon, 14 Jan 2019 10:30:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netronome-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Rt/ezmC/9AbC+cTAA5iZzQ+7FyDY8CREAqtF9VBBDbQ=; b=C0V4hnataXgxfffkdJg/9LoHVA0of4wnXdBN6YpKZGM31eY53pDLutPzhrciMyW5uy 2qc19FLSDc4oTL4FWUuUKhARhcGhUwFVUWZKlwlNCOnbk2mEVp4TGQQYdrZX0gobjHOQ N+C9zd9dhCD1aKKaei11dD41v7ps6D39dMQrlqaQlBYtdc0RkuCUB2lfHSwDcq0x7R+R 1Yx5I5Za6RL+s0LiHT/HGEawRIRxJqeaj4ADeGn5ClKJrGUDmY5tdeBQkl0uohcwj50V CBbHQtD8nCHI3UT/7v/Ca+rEMXX3tZzZ2E+spp2ot5FjP/HPRQfnAMzzwH36uvZRG2bd uvuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Rt/ezmC/9AbC+cTAA5iZzQ+7FyDY8CREAqtF9VBBDbQ=; b=hycJdZnyioLXED+men4rMduSNdKPWajJb6f+eKz63kDNKX49VY5Jsu351+k8FP6ReK XNs6wfBePdLRSibNMcagWBLOdYPBuQ8dUNeVMMjVvm9vf6V/99a2qQvqWA9GeKkIv8Db N0J1z9l1mZL6u7vmnWS9ROnanAkFOJ9uCHUeKEVRHzG006v8v0pfVcF9ViC6cOFFReLr ZI9YQG3Eh4cVXJoN1aNUBOFSP+8UvOFCza+Uuv5l8GREmHEqKflBj7wP/k3fpd4alYeF M+ZztS15yfgn1AkKnjulw4sJ1Pyr86ZXbmwG/wwiXaXYW0fSz6SK25eNDc0du783biKR CabQ== X-Gm-Message-State: AJcUukfK+/tpyx6VXxAINXGi7aX/8PYkkxEgNoP28KnGTaPRkFly7oVM vJ5bhH5tBAyhCsCNHtzEl6TvWncOAXEMR/Jl8ThmcQ== X-Google-Smtp-Source: ALg8bN5UEbP501i0gPqFNjsULybMRaLmMnGNbdXkSJhqd8OvHc7z6nISvyVU4mrCmsDp/Ruty5SxMj11jOz3NICZL6Q= X-Received: by 2002:a5d:844d:: with SMTP id w13mr15819696ior.17.1547490599609; Mon, 14 Jan 2019 10:29:59 -0800 (PST) MIME-Version: 1.0 References: <20190111132553.10683-1-alejandro.lucero@netronome.com> <1051920a-7b6b-f68e-7556-be74c160a477@intel.com> <1753333.lH3haCoHOP@xps> <9a8fff63-7a8b-a100-a725-98e8c0e9cf2b@intel.com> <2981184f-f2ef-b475-53af-e530a9551e60@intel.com> In-Reply-To: <2981184f-f2ef-b475-53af-e530a9551e60@intel.com> From: Alejandro Lucero Date: Mon, 14 Jan 2019 18:29:49 +0000 Message-ID: To: Ferruh Yigit Cc: Thomas Monjalon , dev Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH] net/nfp: add CPP bridge as service 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: Mon, 14 Jan 2019 18:30:01 -0000 On Mon, Jan 14, 2019 at 6:22 PM Ferruh Yigit wrote= : > On 1/14/2019 6:00 PM, Alejandro Lucero wrote: > > > > > > On Mon, Jan 14, 2019 at 10:40 AM Ferruh Yigit > > wrote: > > > > On 1/13/2019 9:41 PM, Thomas Monjalon wrote: > > > 11/01/2019 17:42, Ferruh Yigit: > > >> On 1/11/2019 1:25 PM, Alejandro Lucero wrote: > > >>> The Netronome's Network Flow Processor chip is highly > programmable > > >>> with the goal of processing packets at high speed. Processing > units > > >>> and other chip components are available from the host through t= he > > >>> PCIe CPP(Command Push Pull bus) interface. The NFP PF PMD > configures > > >>> a CPP handler for setting up and working with vNICs, perform > actions > > >>> like link up or down, or accessing extended stats from the MAC > component. > > >>> > > >>> There exist NFP host tools which access the NFP components for > > >>> programming and debugging but they require the CPP interface. > When the > > >>> PMD is bound to the PF, the DPDK app owns the CPP interface, so > these > > >>> host tools can not access the NFP through other means like NFP > kernel > > >>> drivers. > > >>> > > >>> This patch adds a CPP bridge using the rte_service API which ca= n > be > > >>> enabled by a DPDK app. Interestingly, DPDK clients like OVS wil= l > not > > >>> enable specific service cores, but this can be performed with a > > >>> secondary process specifically enabling this CPP bridge service > and > > >>> therefore giving access to the NFP to those host tools. > > >>> > > >>> v2: > > >>> - Avoid printfs for debugging > > >>> - fix compilation problems for powerpc > > >>> > > >>> Signed-off-by: Alejandro Lucero > > > > >> > > >> Applied to dpdk-next-net/master, thanks. > > > > > > It does not compile with 32-bit toolchain. > > > > > > Please check the occurences of %lu, thanks. > > > > Hi Thomas, > > > > We aware the build error, but let it because nfp doesn't support > 32-bit. > > > > But I just recognized that it is enabled by default on 32-bit > default configs, > > we should disable them. > > > > > > Hi Alejandro, > > > > Can you please disable nfp driver explicitly on > > 'defconfig_i686-native-linuxapp-*' config files, perhaps also on > > 'defconfig_x86_x32-native-linuxapp-gcc' too? > > > > I will drop the existing patch from next-net. > > > > > > Ok. I'll do asap. > > > > > > And if it is possible to fix the build error, specially if it is > just for %lu of > > the logging, I prefer the fix against the config update, but it is > up to you. > > > > > > I did not see any logging error/warning when compiling nor any when usi= ng > > checkpatch. I have used a gcc 7.3.1 (Ubuntu) and a 8.2.1 (RH). What are > you > > using for triggering such error? > > Using 'i686-native-linuxapp-gcc' config, which is for 32-bit, gives > following > build error [1] with this patch. > > OK. But after the patch I have just sent for removing NFP PMD from 32 bits builds, nothing is really needed then. Right? If so, should I send the patch again about the CPP bridge or you can redo it? > This is mainly just because logging and can be fixed by using %z for > size_t and > use PRIx64 similar macros for fixed size variables. > > For "cpp_id =3D (offset >> 40) << 8;" build error you need to use fixed s= ize > version of the variable, like "uint64_t offset" > > [1] > .../drivers/net/nfp/nfp_net.c: In function =E2=80=98nfp_cpp_bridge_serve_= write=E2=80=99: > .../drivers/net/nfp/nfp_net.c:2979:32: error: format =E2=80=98%lu=E2=80= =99 expects > argument of > type =E2=80=98long unsigned int=E2=80=99, but argument 6 has type =E2=80= =98unsigned int=E2=80=99 > [-Werror=3Dformat=3D] > sizeof(off_t), sizeof(size_t)); > ^ > .../build/include/rte_log.h:324:25: note: in definition of macro =E2=80= =98RTE_LOG=E2=80=99 > RTE_LOGTYPE_ ## t, # t ": " __VA_ARGS__) > ^ > .../drivers/net/nfp/nfp_net.c:2978:2: note: in expansion of macro > =E2=80=98PMD_CPP_LOG=E2=80=99 > PMD_CPP_LOG(DEBUG, "%s: offset size %lu, count_size: %lu\n", __func__, > ^~~~~~~~~~~ > > > > > > Thanks, > > ferruh > > > >