From c602a3e77fbd95286e233c7ed257762687d8ebac Mon Sep 17 00:00:00 2001
From: Kai Ye <yekai13@huawei.com>
Date: Wed, 22 Dec 2021 14:38:04 +0800
Subject: [PATCH 08/28] qm: fixup the incorrect configuration of the type

SEC should setting the sqc type is 0. it doesn't depend on
global configuration.

Signed-off-by: Kai Ye <yekai13@huawei.com>
---
 drv/hisi_sec.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drv/hisi_sec.c b/drv/hisi_sec.c
index 2fd23f3..603bdda 100644
--- a/drv/hisi_sec.c
+++ b/drv/hisi_sec.c
@@ -2306,7 +2306,8 @@ int hisi_sec_init(struct wd_ctx_config_internal *config, void *priv)
 	/* allocate qp for each context */
 	for (i = 0; i < config->ctx_num; i++) {
 		h_ctx = config->ctxs[i].ctx;
-		qm_priv.op_type = config->ctxs[i].op_type;
+		/* setting the type is 0 for sqc_type */
+		qm_priv.op_type = 0;
 		qm_priv.qp_mode = config->ctxs[i].ctx_mode;
 		qm_priv.idx = i;
 		h_qp = hisi_qm_alloc_qp(&qm_priv, h_ctx);
-- 
2.31.1

