[58/71] net/cpfl: replace use of fixed size rte_memcpy

Message ID 20240229225936.483472-59-stephen@networkplumber.org (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series replace use of fixed size rte_memcpy |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Stephen Hemminger Feb. 29, 2024, 10:58 p.m. UTC
Automatically generated by devtools/cocci/rte_memcpy.cocci

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/cpfl/cpfl_ethdev.c | 3 ++-
 drivers/net/cpfl/cpfl_vchnl.c  | 4 ++--
 2 files changed, 4 insertions(+), 3 deletions(-)
  

Patch

diff --git a/drivers/net/cpfl/cpfl_ethdev.c b/drivers/net/cpfl/cpfl_ethdev.c
index ef19aa1b6a96..1037aec68d2d 100644
--- a/drivers/net/cpfl/cpfl_ethdev.c
+++ b/drivers/net/cpfl/cpfl_ethdev.c
@@ -2292,7 +2292,8 @@  cpfl_adapter_ext_init(struct rte_pci_device *pci_dev, struct cpfl_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/cpfl/cpfl_vchnl.c b/drivers/net/cpfl/cpfl_vchnl.c
index 7d277a0e8e83..e914014d8a9b 100644
--- a/drivers/net/cpfl/cpfl_vchnl.c
+++ b/drivers/net/cpfl/cpfl_vchnl.c
@@ -32,7 +32,7 @@  cpfl_cc_vport_list_get(struct cpfl_adapter_ext *adapter,
 		return err;
 	}
 
-	rte_memcpy(response, args.out_buffer, IDPF_DFLT_MBX_BUF_SIZE);
+	memcpy(response, args.out_buffer, IDPF_DFLT_MBX_BUF_SIZE);
 
 	return 0;
 }
@@ -66,7 +66,7 @@  cpfl_cc_vport_info_get(struct cpfl_adapter_ext *adapter,
 		return err;
 	}
 
-	rte_memcpy(response, args.out_buffer, sizeof(*response));
+	memcpy(response, args.out_buffer, sizeof(*response));
 
 	return 0;
 }