From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [67.231.154.164]) by dpdk.org (Postfix) with ESMTP id DAD933237 for ; Fri, 5 Oct 2018 18:37:02 +0200 (CEST) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (uk.solarflare.com [193.34.186.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mx1-us3.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id 6AFB79C0059; Fri, 5 Oct 2018 16:37:01 +0000 (UTC) Received: from [192.168.38.17] (91.220.146.112) by ukex01.SolarFlarecom.com (10.17.10.4) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Fri, 5 Oct 2018 17:36:56 +0100 To: Alejandro Lucero , References: <1538756211-9359-1-git-send-email-alejandro.lucero@netronome.com> From: Andrew Rybchenko Message-ID: <745d26fa-3215-4c16-15d5-31f9a6922d82@solarflare.com> Date: Fri, 5 Oct 2018 19:36:13 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.0 MIME-Version: 1.0 In-Reply-To: <1538756211-9359-1-git-send-email-alejandro.lucero@netronome.com> Content-Language: en-GB X-Originating-IP: [91.220.146.112] X-ClientProxiedBy: ocex03.SolarFlarecom.com (10.20.40.36) To ukex01.SolarFlarecom.com (10.17.10.4) X-TM-AS-Product-Ver: SMEX-12.5.0.1300-8.5.1010-24136.003 X-TM-AS-Result: No-14.190300-8.000000-10 X-TMASE-MatchedRID: 6lay9u8oTUMOwH4pD14DsPHkpkyUphL9jOOSc4z5Qmh+YesuCgkiXB3m ofUGOoJwahX4ipyY+l4jrysmQWQSIpRho78T5P9DJhFEQZiq2ZQhotH7bEpEMiz+5QCTrE/sZvo +mFW19mA0D+L1rjiNeE6nIMfjRtNU3huBcHFqgEsSDAzxRL+lMc1eA/uWJnkiE4uJ274vfHy6kJ XVPDRM6SYip5C4WUFkMgUz5yJGb04o67AovSGf5lVN8laWo90MIWrhso05H/UA6s2mIXI3kIRjb 6q99slJmLMydHVCj/vd4vhcQjqAMrmNTbjc5lPnwbRQ2BpmliqZEoWHC6Rh/R9Oluq8LbzVzdlo 26al4KH2vPhulcaXWIFoPFs7wHUtBawxeDgsyEmprpImTnz4ti2VljVYB9GN2Yajy1P9W1XdKUS BW7I322+5ieh24ZYRkZOl7WKIImrvXOvQVlExsFZ0V5tYhzdWbGVEmIfjf3uz0B76zBY7UJcFEn CW5p5JXYEVIlK8wDM6fvKRqd88mc0cY7RwoJPp0BxUYN50T/ISgf9z2HX3UVbgCzN+9u3FZZ1cQ Y0wHVo= X-TM-AS-User-Approved-Sender: Yes X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--14.190300-8.000000 X-TMASE-Version: SMEX-12.5.0.1300-8.5.1010-24136.003 X-MDID: 1538757422-arI1fil4F9Qh Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH v2] 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: Fri, 05 Oct 2018 16:37:03 -0000 On 10/5/18 7:16 PM, Alejandro Lucero wrote: > 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. > > v2: > - changing library version > - report shared library change in release notes > > Signed-off-by: Alejandro Lucero > --- > doc/guides/rel_notes/release_18_11.rst | 1 + > lib/librte_ethdev/Makefile | 2 +- > lib/librte_ethdev/meson.build | 2 +- > lib/librte_ethdev/rte_ethdev_core.h | 8 +++++++- > 4 files changed, 10 insertions(+), 3 deletions(-) > > diff --git a/doc/guides/rel_notes/release_18_11.rst b/doc/guides/rel_notes/release_18_11.rst > index c806dc6..32ab754 100644 > --- a/doc/guides/rel_notes/release_18_11.rst > +++ b/doc/guides/rel_notes/release_18_11.rst > @@ -189,6 +189,7 @@ Shared Library Versions > librte_acl.so.2 > + librte_cfgfile.so.2 > librte_cmdline.so.2 > + + librte_ethdev.so.2 It is a comment section. Actual library version is librte_ethdev.so.10 below. So, it should add + sign and change to so.11 > > This section is a comment. Do not overwrite or remove it. > ========================================================= > diff --git a/lib/librte_ethdev/Makefile b/lib/librte_ethdev/Makefile > index d720dd2..e27bcd5 100644 > --- a/lib/librte_ethdev/Makefile > +++ b/lib/librte_ethdev/Makefile > @@ -16,7 +16,7 @@ LDLIBS += -lrte_mbuf -lrte_kvargs > > EXPORT_MAP := rte_ethdev_version.map > > -LIBABIVER := 10 > +LIBABIVER := 11 > > SRCS-y += ethdev_private.c > SRCS-y += rte_ethdev.c > diff --git a/lib/librte_ethdev/meson.build b/lib/librte_ethdev/meson.build > index 172e302..6783013 100644 > --- a/lib/librte_ethdev/meson.build > +++ b/lib/librte_ethdev/meson.build > @@ -2,7 +2,7 @@ > # Copyright(c) 2017 Intel Corporation > > name = 'ethdev' > -version = 10 > +version = 11 > allow_experimental_apis = true > sources = files('ethdev_private.c', > 'ethdev_profile.c', > diff --git a/lib/librte_ethdev/rte_ethdev_core.h b/lib/librte_ethdev/rte_ethdev_core.h > index 33d12b3..0d28fd9 100644 > --- a/lib/librte_ethdev/rte_ethdev_core.h > +++ b/lib/librte_ethdev/rte_ethdev_core.h > @@ -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 > + * primary and secondary processes and *process_private is per-process > + * private. The second one is managed by PMDs if necessary. > + */ I think above is wrong from doxygen point of view. 'data' member already has documentation. I'm not sure, so it should be checked. > + struct rte_eth_dev_data *data; /**< Pointer to device data. */ > + void *process_private; /**< Pointer to per-process device data. */ > const struct eth_dev_ops *dev_ops; /**< Functions exported by PMD */ > struct rte_device *device; /**< Backing device */ > struct rte_intr_handle *intr_handle; /**< Device interrupt handle */