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 C8AE8A0C41; Wed, 23 Jun 2021 12:10:05 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 445124003F; Wed, 23 Jun 2021 12:10:05 +0200 (CEST) Received: from smartserver.smartsharesystems.com (smartserver.smartsharesystems.com [77.243.40.215]) by mails.dpdk.org (Postfix) with ESMTP id 458494003E for ; Wed, 23 Jun 2021 12:10:03 +0200 (CEST) Content-class: urn:content-classes:message MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Date: Wed, 23 Jun 2021 12:10:02 +0200 Message-ID: <98CBD80474FA8B44BF855DF32C47DC35C61883@smartserver.smartshare.dk> In-Reply-To: X-MS-Has-Attach: X-MS-TNEF-Correlator: Thread-Topic: [dpdk-dev] [RFC PATCH] dmadev: introduce DMA device library X-MimeOLE: Produced By Microsoft Exchange V6.5 Thread-Index: AddoE/QS9eevz3zkQk6C08jGxs/CiQAAEbFA References: <1623763327-30987-1-git-send-email-fengchengwen@huawei.com> <98CBD80474FA8B44BF855DF32C47DC35C61860@smartserver.smartshare.dk> <3cb0bd01-2b0d-cf96-d173-920947466041@huawei.com> From: =?iso-8859-1?Q?Morten_Br=F8rup?= To: "Bruce Richardson" , "Jerin Jacob" Cc: "fengchengwen" , "Thomas Monjalon" , "Ferruh Yigit" , "dpdk-dev" , "Nipun Gupta" , "Hemant Agrawal" , "Maxime Coquelin" , "Honnappa Nagarahalli" , "Jerin Jacob" , "David Marchand" , "Satananda Burla" , "Prasun Kapoor" Subject: Re: [dpdk-dev] [RFC PATCH] 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" > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Bruce Richardson > Sent: Wednesday, 23 June 2021 11.41 >=20 > [Also, you are not likely to want to offload a small > copy, are you?] Maybe. I would consider it for two reasons: 1. To avoid CPU cache pollution. E.g. copy packet data (or part of it) = to memory that is not going to be used any time soon, such as a packet = capture buffer. When a packet has been DPI analyzed at ingress and put in a QoS queue = for holding, the packet data will be cold at the time of egress. If such = a packet is to be captured at egress, the CPU is not going to touch the = data in the original packet anymore (only the TX NIC will). And if the = copy of the packet is queued to be processed by a "capture storage = readout" pipeline stage, the CPU core that copied the packet will not = touch the copy either (only the CPU core in the "capture storage = readout" pipeline stage will; but that may be minutes or hours later). 2. To simplify code by using the same method, regardless of size. Although it might be more efficient copying 64 B packets using CPU = instructions and 1518 B packets using DMA, writing code that only uses = one of the methods might simplify things. -Morten