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 E7B1FA00C2; Fri, 31 Dec 2021 16:36:33 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 768B74069D; Fri, 31 Dec 2021 16:36:33 +0100 (CET) Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by mails.dpdk.org (Postfix) with ESMTP id E9C6E4067E for ; Fri, 31 Dec 2021 16:36:31 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1640964992; x=1672500992; h=from:to:cc:subject:date:message-id; bh=RYXpt5VHYwSZElr7a9kgPSAjfNivx9RsHojvSnzgn80=; b=fd4WXrswbyhjEWIq1rFca7ZDqUvfMft4j46wDVGQJxBHcVg7VTFlOXrt D0jEtvIDg0WDhh7o4sNfovoc9ck1oHmOF6dN0RTWgRvkvfig5PM5pXEsM sW8MCNKHbeGK19wSiXu8Y0TwN4+NHDzOMiXn5zNkrc5LtA4xuxTIJcC75 005S0K4JPndWiXdJDtZwJjEdDDmKJodAzLtK6M757J3+A7pE4xIEOsWkH 7aP57/WC1QJdmG+KfiLVrAvxyOwYOCt/FWYe8PlAPkX5rGSE8OHqHBzFt efsuOW7WUcRB2kz5dBGeKWHRYOEwtv6xIlylV8n/bPvZuyopRMGDnLx4y Q==; X-IronPort-AV: E=McAfee;i="6200,9189,10213"; a="240608934" X-IronPort-AV: E=Sophos;i="5.88,251,1635231600"; d="scan'208";a="240608934" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 31 Dec 2021 07:36:30 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,251,1635231600"; d="scan'208";a="524765490" Received: from npg-dpdk-xuan-cbdma.sh.intel.com ([10.67.110.228]) by orsmga008.jf.intel.com with ESMTP; 31 Dec 2021 07:36:27 -0800 From: xuan.ding@intel.com To: maxime.coquelin@redhat.com, chenbo.xia@intel.com Cc: dev@dpdk.org, jiayu.hu@intel.com, sunil.pai.g@intel.com, liangma@liangbit.com, yuanx.wang@intel.com, cheng1.jiang@intel.com, wenwux.ma@intel.com, Xuan Ding Subject: [RFC 0/2] vhost: support async dequeue data path Date: Sat, 1 Jan 2022 00:12:42 +0000 Message-Id: <20220101001244.90147-1-xuan.ding@intel.com> X-Mailer: git-send-email 2.17.1 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 From: Xuan Ding Hi everyone, The presence of an asynchronous path allows applications to offload memory copies to DMA engine, so as to save CPU cycles and improve the copy performance. This patch set is a draft implementation for split ring in vhost async dequeue data path. The code is based on latest enqueue changes [1]. This patch set is a new design and implementation of [2]. Since dmadev is introduced in 21.11, to simplify application logics, this patch integrates dmadev in vhost. With dmadev integrated, vhost supports M:N mapping between vrings and DMA virtual channels. Specifically, one vring can use multiple different DMA channels and one DMA channel can be shared by multiple vrings at the same time. A new asynchronous dequeue function is introduced: 1) rte_vhost_async_try_dequeue_burst(int vid, uint16_t queue_id, struct rte_mempool *mbuf_pool, struct rte_mbuf **pkts, uint16_t count, int *nr_inflight, uint16_t dma_id, uint16_t dma_vchan) Receive packets from the guest and offloads copies to DMA virtual channel. [1] https://mails.dpdk.org/archives/dev/2021-December/231889.html. [2] https://mails.dpdk.org/archives/dev/2021-September/218591.html. Your comments are welcomed and appreciated! Thanks! Xuan Xuan Ding (2): vhost: support async dequeue for split ring examples/vhost: support async dequeue data path doc/guides/sample_app_ug/vhost.rst | 9 +- examples/vhost/main.c | 305 ++++++++++++------ examples/vhost/main.h | 35 +- examples/vhost/virtio_net.c | 16 +- lib/vhost/rte_vhost_async.h | 29 ++ lib/vhost/version.map | 1 + lib/vhost/vhost.h | 1 + lib/vhost/virtio_net.c | 493 +++++++++++++++++++++++++++++ 8 files changed, 783 insertions(+), 106 deletions(-) -- 2.17.1