Thread (169 messages) flat view 169 messages, 10 authors, 10d ago
COOLING10d

Revision v1 of 2 in this series.

Revisions (2)
  1. v1 current
  2. v2 [diff vs current]

[PATCH 13/61] eal: replace rte_memcpy of cpuset

From: Stephen Hemminger <stephen@networkplumber.org>
Date: 2026-08-20 05:24:17
Subsystem: library code, the rest · Maintainers: Andrew Morton, Linus Torvalds

Simple structure assignment is better than rte_memcpy.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/eal/common/eal_common_options.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/lib/eal/common/eal_common_options.c b/lib/eal/common/eal_common_options.c
index 42cdef632f..c0e97d21ae 100644
--- a/lib/eal/common/eal_common_options.c
+++ b/lib/eal/common/eal_common_options.c
@@ -29,7 +29,6 @@
 #include <rte_tailq.h>
 #include <rte_version.h>
 #include <rte_devargs.h>
-#include <rte_memcpy.h>
 #ifndef RTE_EXEC_ENV_WINDOWS
 #include <rte_telemetry.h>
 #endif
@@ -1446,7 +1445,7 @@ eal_parse_lcores(const char *lcores)
 
 		/* without '@', by default using lcore_set as cpuset */
 		if (*lcores != '@')
-			rte_memcpy(&cpuset, &lcore_set, sizeof(cpuset));
+			cpuset = lcore_set;
 
 		set_count = CPU_COUNT(&lcore_set);
 		/* start to update lcore_set */
@@ -1469,8 +1468,7 @@ eal_parse_lcores(const char *lcores)
 
 			if (check_cpuset(&cpuset) < 0)
 				goto err;
-			rte_memcpy(&lcore_config[idx].cpuset, &cpuset,
-				   sizeof(rte_cpuset_t));
+			lcore_config[idx].cpuset = cpuset;
 		}
 
 		/* some cores from the lcore_set can't be handled by EAL */
-- 
2.53.0
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help