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 DF29543BAE; Fri, 1 Mar 2024 00:03:46 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9374043372; Fri, 1 Mar 2024 00:01:13 +0100 (CET) Received: from mail-pj1-f49.google.com (mail-pj1-f49.google.com [209.85.216.49]) by mails.dpdk.org (Postfix) with ESMTP id 5F20643291 for ; Fri, 1 Mar 2024 00:00:25 +0100 (CET) Received: by mail-pj1-f49.google.com with SMTP id 98e67ed59e1d1-29a940614easo1097426a91.3 for ; Thu, 29 Feb 2024 15:00:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1709247624; x=1709852424; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=XUHvwBLFAbLslSMTmZSKyZCQSLx2BGir5+OP+Lo8mC8=; b=Hdv7Wq1Op3Gnvoqf0KP97pouPXs//3w9TM4qwHvqrcM7woTIS/lnPx8iX1QlXlwzg5 8qdnHcu9SgD4/P4LQ4mpI7d85CmGm1E0Ypvb/MU3jjP8+q4IdIpyJHDsTZRiaCSIurji ecEE5ypbIzF+CHVgYmEiBORfgPI3cczYCbn+AxOspLpJsFBwm4pcK+n00qaL3/aQ7o/F 3zbm9wauvrDEcfVSq1HX6s4JAl5cW/964pwPxS/g7Z9yN2JbqnF+qzdOZIkOH+QWp3II PXWS+xo0PD5nI3rgiRio82NRlndfzWpN/SV/ACgry4J6fI7C0bxMmi5gPfableNVi6a6 R8rw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709247624; x=1709852424; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=XUHvwBLFAbLslSMTmZSKyZCQSLx2BGir5+OP+Lo8mC8=; b=koI77cdssRQR/NwOdJdN28qW+N6rCIi4um5vIrAH3ZQhWyDdSLyR0+DPbKbBHHGKe5 xvRjUxJJs1dRouUG3riW398EU/M8qQULt4DqRgquPqJxYCu91zHHpwCZPllgSKfMekQH FGybrGhC9vYpxrnkmWGbj2OS2NXiUwAvl+FksD9PVgpvQVWkAR8qFq7ZwYMjhnvFGkLz LsdGI7SgjrvGHpOY1ma75cLOD4oY6bFZEP1D9q5V2n2HBKHe1u23I30IUg1uHsiku7VG 9s0eVu5Wvzi9KgWYWsifsYTfb6b48WpMtHJrDTI8bCMbPwh/znDpq8ganVnqMFfcXxdR 0T1A== X-Gm-Message-State: AOJu0YwezXV1TXX2BBSvMfc2/yvL3iZ7eAC7gwv3zG5W06wy6bILAFQ6 pi8D9YgYCqE7PGwFLbf+xqd3w9VH8fOzDdF4rv49jM6/2dZVkU7wH9KIjslwzWgHETcEtGNIXa/ S X-Google-Smtp-Source: AGHT+IE1PoacfrbOoeSSA6ZbBIg6a1MGrrQBjEJ3dvjdrsiJ+08iy4QZBR7lCGiibtZoxqiPG1l7hQ== X-Received: by 2002:a17:90a:e7cc:b0:29b:2179:b1df with SMTP id kb12-20020a17090ae7cc00b0029b2179b1dfmr66593pjb.0.1709247623371; Thu, 29 Feb 2024 15:00:23 -0800 (PST) Received: from hermes.local (204-195-123-141.wavecable.com. [204.195.123.141]) by smtp.gmail.com with ESMTPSA id l22-20020a17090b079600b0029a8e5355fcsm1965578pjz.53.2024.02.29.15.00.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 29 Feb 2024 15:00:22 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Jingjing Wu Subject: [PATCH 28/71] net/idpf: replace use of fixed size rte_memcpy Date: Thu, 29 Feb 2024 14:58:15 -0800 Message-ID: <20240229225936.483472-29-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240229225936.483472-1-stephen@networkplumber.org> References: <20240229225936.483472-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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 Automatically generated by devtools/cocci/rte_memcpy.cocci Signed-off-by: Stephen Hemminger --- drivers/net/idpf/idpf_ethdev.c | 7 ++++--- drivers/net/idpf/idpf_rxtx.c | 10 ++++++---- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/drivers/net/idpf/idpf_ethdev.c b/drivers/net/idpf/idpf_ethdev.c index 86151c9ec9fa..9cf33c4b7058 100644 --- a/drivers/net/idpf/idpf_ethdev.c +++ b/drivers/net/idpf/idpf_ethdev.c @@ -1088,8 +1088,8 @@ idpf_handle_virtchnl_msg(struct idpf_adapter_ext *adapter_ex) return; } - rte_memcpy(adapter->mbx_resp, ctlq_msg.ctx.indirect.payload->va, - IDPF_DFLT_MBX_BUF_SIZE); + memcpy(adapter->mbx_resp, ctlq_msg.ctx.indirect.payload->va, + IDPF_DFLT_MBX_BUF_SIZE); mbx_op = rte_le_to_cpu_16(ctlq_msg.opcode); vc_op = rte_le_to_cpu_32(ctlq_msg.cookie.mbx.chnl_opcode); @@ -1202,7 +1202,8 @@ idpf_adapter_ext_init(struct rte_pci_device *pci_dev, struct idpf_adapter_ext *a strncpy(adapter->name, pci_dev->device.name, PCI_PRI_STR_SIZE); - rte_memcpy(&base->caps, &req_caps, sizeof(struct virtchnl2_get_capabilities)); + memcpy(&base->caps, &req_caps, + sizeof(struct virtchnl2_get_capabilities)); ret = idpf_adapter_init(base); if (ret != 0) { diff --git a/drivers/net/idpf/idpf_rxtx.c b/drivers/net/idpf/idpf_rxtx.c index 64f22355804e..da659e16531c 100644 --- a/drivers/net/idpf/idpf_rxtx.c +++ b/drivers/net/idpf/idpf_rxtx.c @@ -76,7 +76,7 @@ idpf_dma_zone_reserve(struct rte_eth_dev *dev, uint16_t queue_idx, else ring_size = RTE_ALIGN(len * sizeof(struct idpf_base_tx_desc), IDPF_DMA_MEM_ALIGN); - rte_memcpy(ring_name, "idpf Tx ring", sizeof("idpf Tx ring")); + memcpy(ring_name, "idpf Tx ring", sizeof("idpf Tx ring")); break; case VIRTCHNL2_QUEUE_TYPE_RX: if (splitq) @@ -85,17 +85,19 @@ idpf_dma_zone_reserve(struct rte_eth_dev *dev, uint16_t queue_idx, else ring_size = RTE_ALIGN(len * sizeof(struct virtchnl2_singleq_rx_buf_desc), IDPF_DMA_MEM_ALIGN); - rte_memcpy(ring_name, "idpf Rx ring", sizeof("idpf Rx ring")); + memcpy(ring_name, "idpf Rx ring", sizeof("idpf Rx ring")); break; case VIRTCHNL2_QUEUE_TYPE_TX_COMPLETION: ring_size = RTE_ALIGN(len * sizeof(struct idpf_splitq_tx_compl_desc), IDPF_DMA_MEM_ALIGN); - rte_memcpy(ring_name, "idpf Tx compl ring", sizeof("idpf Tx compl ring")); + memcpy(ring_name, "idpf Tx compl ring", + sizeof("idpf Tx compl ring")); break; case VIRTCHNL2_QUEUE_TYPE_RX_BUFFER: ring_size = RTE_ALIGN(len * sizeof(struct virtchnl2_splitq_rx_buf_desc), IDPF_DMA_MEM_ALIGN); - rte_memcpy(ring_name, "idpf Rx buf ring", sizeof("idpf Rx buf ring")); + memcpy(ring_name, "idpf Rx buf ring", + sizeof("idpf Rx buf ring")); break; default: PMD_INIT_LOG(ERR, "Invalid queue type"); -- 2.43.0