In zip device, different operation types are corresponding to different algorithm cores. So, we need to specify the operation type of the ctx requested from zip device.
Signed-off-by: Qi Tao taoqi10@huawei.com --- uadk_tool/benchmark/zip_uadk_benchmark.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/uadk_tool/benchmark/zip_uadk_benchmark.c b/uadk_tool/benchmark/zip_uadk_benchmark.c index e2876a9..ecb688f 100644 --- a/uadk_tool/benchmark/zip_uadk_benchmark.c +++ b/uadk_tool/benchmark/zip_uadk_benchmark.c @@ -372,7 +372,7 @@ static int specified_device_request_ctx(struct acc_option *options) ret = -ENOMEM; goto free_ctx; } - g_ctx_cfg.ctxs[i].op_type = 0; + g_ctx_cfg.ctxs[i].op_type = options->optype % WD_DIR_MAX; g_ctx_cfg.ctxs[i].ctx_mode = (__u8)mode; }
@@ -414,7 +414,7 @@ static int non_specified_device_request_ctx(struct acc_option *options) if (!g_ctx_cfg.ctxs[i].ctx) break;
- g_ctx_cfg.ctxs[i].op_type = 0; + g_ctx_cfg.ctxs[i].op_type = options->optype % WD_DIR_MAX; g_ctx_cfg.ctxs[i].ctx_mode = (__u8)mode; }