From 1ad673a9ddfb06238105504fd9634c46aa02c498 Mon Sep 17 00:00:00 2001 From: Ben Walker Date: Tue, 9 May 2017 10:46:47 -0700 Subject: [PATCH] copy: Replace rte_memcpy with regular memcpy Eliminate rte_memcpy dependency by replacing it with regular memcpy. This may impact performance, but the only use of rte_memcpy was in the malloc bdev which is for testing only. Change-Id: I3e8592cb08262272518ec3d29ea165b4e8f48a5c Signed-off-by: Ben Walker --- lib/copy/copy_engine.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/lib/copy/copy_engine.c b/lib/copy/copy_engine.c index db56c7ee2..fa24359e0 100644 --- a/lib/copy/copy_engine.c +++ b/lib/copy/copy_engine.c @@ -35,9 +35,7 @@ #include "spdk_internal/copy_engine.h" -#include -#include - +#include "spdk/env.h" #include "spdk/log.h" #include "spdk/io_channel.h" @@ -110,7 +108,8 @@ mem_copy_submit(void *cb_arg, struct spdk_io_channel *ch, void *dst, void *src, { struct spdk_copy_task *copy_req; - rte_memcpy(dst, src, (size_t)nbytes); + memcpy(dst, src, (size_t)nbytes); + copy_req = (struct spdk_copy_task *)((uintptr_t)cb_arg - offsetof(struct spdk_copy_task, offload_ctx)); cb(copy_req, 0);