From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1FE85A0C48; Tue, 20 Jul 2021 14:06:06 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 963A940689; Tue, 20 Jul 2021 14:06:05 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mails.dpdk.org (Postfix) with ESMTP id A788940140 for ; Tue, 20 Jul 2021 14:06:04 +0200 (CEST) X-IronPort-AV: E=McAfee;i="6200,9189,10050"; a="198424229" X-IronPort-AV: E=Sophos;i="5.84,254,1620716400"; d="scan'208";a="198424229" Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 20 Jul 2021 05:06:00 -0700 X-IronPort-AV: E=Sophos;i="5.84,254,1620716400"; d="scan'208";a="657513432" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.7.183]) by fmsmga006-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 20 Jul 2021 05:05:57 -0700 Date: Tue, 20 Jul 2021 13:05:54 +0100 From: Bruce Richardson To: Chengwen Feng Cc: thomas@monjalon.net, ferruh.yigit@intel.com, jerinj@marvell.com, jerinjacobk@gmail.com, andrew.rybchenko@oktetlabs.ru, dev@dpdk.org, mb@smartsharesystems.com, nipun.gupta@nxp.com, hemant.agrawal@nxp.com, maxime.coquelin@redhat.com, honnappa.nagarahalli@arm.com, david.marchand@redhat.com, sburla@marvell.com, pkapoor@marvell.com, konstantin.ananyev@intel.com Message-ID: References: <1625231891-2963-1-git-send-email-fengchengwen@huawei.com> <1626779572-31328-1-git-send-email-fengchengwen@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1626779572-31328-1-git-send-email-fengchengwen@huawei.com> Subject: Re: [dpdk-dev] [PATCH v9] dmadev: introduce DMA device library X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Tue, Jul 20, 2021 at 07:12:52PM +0800, Chengwen Feng wrote: > This patch introduce 'dmadevice' which is a generic type of DMA > device. > > The APIs of dmadev library exposes some generic operations which can > enable configuration and I/O with the DMA devices. > > Signed-off-by: Chengwen Feng Apologies for late feedback. Just reporting issues as I find them working with the code. /Bruce > --- > + > +/** > + * @warning > + * @b EXPERIMENTAL: this API may change without prior notice. > + * > + * Returns the number of operations that have been completed, and the > + * operations result may succeed or fail. > + * > + * @param dev_id > + * The identifier of the device. > + * @param vchan > + * The identifier of virtual DMA channel. > + * @param nb_cpls > + * Indicates the size of status array. > + * @param[out] last_idx > + * The last completed operation's index. > + * If not required, NULL can be passed in. > + * @param[out] status > + * The error code of operations that completed. > + * @see enum rte_dma_status_code The documentation should make it clear that this is an array with "nb_cpls" entries. > + * > + * @return > + * The number of operations that completed. This return value must be less > + * than or equal to the value of nb_cpls. also update this to report that the appropriate number of "status" entries have been filled out. > + */ > +__rte_experimental > +static inline uint16_t > +rte_dmadev_completed_status(uint16_t dev_id, uint16_t vchan, > + const uint16_t nb_cpls, uint16_t *last_idx, > + enum rte_dma_status_code *status)