diff mbox series

[13/31] crypto: qat - remove writes into WQCFG

Message ID 20201012203847.340030-14-giovanni.cabiddu@intel.com
State Accepted
Commit 8b5b80db8b85a78929fb0ad50acea32eeefa7ebd
Headers show
Series crypto: qat - rework in preparation for qat_4xxx driver | expand

Commit Message

Cabiddu, Giovanni Oct. 12, 2020, 8:38 p.m. UTC
WQCFG registers contain the correct values after reset in all
generations of QAT. No need to write into them.

Signed-off-by: Giovanni Cabiddu <giovanni.cabiddu@intel.com>
Reviewed-by: Fiona Trahe <fiona.trahe@intel.com>
Reviewed-by: Wojciech Ziemba <wojciech.ziemba@intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/crypto/qat/qat_common/adf_hw_arbiter.c | 13 -------------
 1 file changed, 13 deletions(-)
diff mbox series

Patch

diff --git a/drivers/crypto/qat/qat_common/adf_hw_arbiter.c b/drivers/crypto/qat/qat_common/adf_hw_arbiter.c
index d4162783f970..cbb9f0b8ff74 100644
--- a/drivers/crypto/qat/qat_common/adf_hw_arbiter.c
+++ b/drivers/crypto/qat/qat_common/adf_hw_arbiter.c
@@ -11,7 +11,6 @@ 
 #define ADF_ARB_REG_SLOT 0x1000
 #define ADF_ARB_WTR_OFFSET 0x010
 #define ADF_ARB_RO_EN_OFFSET 0x090
-#define ADF_ARB_WQCFG_OFFSET 0x100
 #define ADF_ARB_WRK_2_SER_MAP_OFFSET 0x180
 #define ADF_ARB_RINGSRVARBEN_OFFSET 0x19C
 
@@ -28,10 +27,6 @@ 
 	ADF_ARB_WRK_2_SER_MAP_OFFSET) + \
 	(ADF_ARB_REG_SIZE * index), value)
 
-#define WRITE_CSR_ARB_WQCFG(csr_addr, index, value) \
-	ADF_CSR_WR(csr_addr, (ADF_ARB_OFFSET + \
-	ADF_ARB_WQCFG_OFFSET) + (ADF_ARB_REG_SIZE * index), value)
-
 int adf_init_arb(struct adf_accel_dev *accel_dev)
 {
 	struct adf_hw_device_data *hw_data = accel_dev->hw_device;
@@ -45,10 +40,6 @@  int adf_init_arb(struct adf_accel_dev *accel_dev)
 	for (arb = 0; arb < ADF_ARB_NUM; arb++)
 		WRITE_CSR_ARB_SARCONFIG(csr, arb, arb_cfg);
 
-	/* Setup worker queue registers */
-	for (i = 0; i < hw_data->num_engines; i++)
-		WRITE_CSR_ARB_WQCFG(csr, i, i);
-
 	/* Map worker threads to service arbiters */
 	hw_data->get_arb_mapping(accel_dev, &thd_2_arb_cfg);
 
@@ -84,10 +75,6 @@  void adf_exit_arb(struct adf_accel_dev *accel_dev)
 	for (i = 0; i < ADF_ARB_NUM; i++)
 		WRITE_CSR_ARB_SARCONFIG(csr, i, 0);
 
-	/* Shutdown work queue */
-	for (i = 0; i < hw_data->num_engines; i++)
-		WRITE_CSR_ARB_WQCFG(csr, i, 0);
-
 	/* Unmap worker threads to service arbiters */
 	for (i = 0; i < hw_data->num_engines; i++)
 		WRITE_CSR_ARB_WRK_2_SER_MAP(csr, i, 0);