From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out3-smtp.messagingengine.com (out3-smtp.messagingengine.com [66.111.4.27]) by dpdk.org (Postfix) with ESMTP id 035061B441 for ; Wed, 3 Oct 2018 22:44:15 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 860ED21E78; Wed, 3 Oct 2018 16:44:15 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute1.internal (MEProxy); Wed, 03 Oct 2018 16:44:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding:content-type; s=mesmtp; bh=JndNN+bEpn2kC0+Nyvpwnfle2ozvi9gfvOxVV568Wr0=; b=g8my1+6MNBwY OJrmhjsuQKmQfOfFRixbcextK0gnGjpiMjSf8ZdWYrOffvL2kXn95jQcRCSGLz5r fhQVn0+oufxWbw//0B3Pc/Y3U7GG4SOKxrLNhjM2TbItSiyqBZO+Nr2x8Glo6P35 raqd/k9UH4AhJiSbXyJEB+CrYste+wc= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm3; bh=JndNN+bEpn2kC0+Nyvpwnfle2ozvi9gfvOxVV568W r0=; b=uHQgr4uCur8lDIdYrme/qvCHlBg+S6SWA5IHCYfRVo3BShtoLHFFMWKF3 k4DN1KJ1a1SU/+tBwYo0fYsUdh9gxtxOAUrE/rxondrtWEKPJ+dwyjTAfFLI9ta9 bjqAvLiP6jacqicmHHDmi4uaF1Gt0ZqnYwi/DOWtC85vtWci7pUVJGOJ2JTJMvJe BxvnfCEOWlDT+6BKzs2tM6/Cv1N2aq8Cxkh5jddrzW+qJJRSuIKP27nnGtjC/uzn Fq1DW8rSs8S48hFOKrVOeHDxb85jClUFf8uf5i3fjgKPo2HltOkd8cBtu9QXadB6 r5UXac7E1yB/1d3oQQI7XPyLe9DIQ== X-ME-Sender: X-ME-Proxy: Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 3C7AF102DE; Wed, 3 Oct 2018 16:44:14 -0400 (EDT) From: Thomas Monjalon To: Alejandro Lucero , ferruh.yigit@intel.com, arybchenko@solarflare.com Cc: dev@dpdk.org, rasland@mellanox.com Date: Wed, 03 Oct 2018 22:44:13 +0200 Message-ID: <256449070.EJcjglVyyx@xps> In-Reply-To: <1538047596-23954-1-git-send-email-alejandro.lucero@netronome.com> References: <1538047596-23954-1-git-send-email-alejandro.lucero@netronome.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-dev] [PATCH] ethdev: add field for device data per process 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: Wed, 03 Oct 2018 20:44:16 -0000 + Cc more people 27/09/2018 13:26, Alejandro Lucero: > Primary and secondary processes share a per-device private data. With > current design it is not possible to have data per-device per-process. > This is required for handling properly the CPP interface inside the NFP > PMD with multiprocess support. > > There is also at least another PMD driver, tap, with similar > requirements for per-process device data. Yes, it is required to fix tap PMD for multi-process usage. I am in favor of accepting this change in 18.11. [...] > @@ -539,7 +539,13 @@ struct rte_eth_dev { > eth_rx_burst_t rx_pkt_burst; /**< Pointer to PMD receive function. */ > eth_tx_burst_t tx_pkt_burst; /**< Pointer to PMD transmit function. */ > eth_tx_prep_t tx_pkt_prepare; /**< Pointer to PMD transmit prepare function. */ > - struct rte_eth_dev_data *data; /**< Pointer to device data */ > + /** > + * Next two fields are per-device data but *data is shared between All fields in rte_eth_dev are per-device. > + * primary and secondary processes and *process_private is per-process > + * private. > + */ > + struct rte_eth_dev_data *data; /**< Pointer to device data. */ > + void *process_private; /**< Pointer to per-process device data. */ We could explain here that this memory is allocated by the PMD.