aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/drivers/crypto/hisilicon/hpre/hpre.h
diff options
context:
space:
mode:
authorZhiqi Song <songzhiqi1@huawei.com>2022-09-09 17:47:00 +0800
committerHerbert Xu <herbert@gondor.apana.org.au>2022-09-16 18:29:45 +0800
commitf214d59a0603543cfa7c6c1cf2eb130ac77480c3 (patch)
tree1b13f81cab1bec6e2b0bf56ca3328b092867302b /drivers/crypto/hisilicon/hpre/hpre.h
parentcrypto: hisilicon/qm - support get device irq information from hardware registers (diff)
downloadwireguard-linux-f214d59a0603543cfa7c6c1cf2eb130ac77480c3.tar.xz
wireguard-linux-f214d59a0603543cfa7c6c1cf2eb130ac77480c3.zip
crypto: hisilicon/hpre - support hpre capability
Read some hpre device configuration info from capability register, instead of fixed macros. Signed-off-by: Zhiqi Song <songzhiqi1@huawei.com> Signed-off-by: Weili Qian <qianweili@huawei.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/hisilicon/hpre/hpre.h')
-rw-r--r--drivers/crypto/hisilicon/hpre/hpre.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/crypto/hisilicon/hpre/hpre.h b/drivers/crypto/hisilicon/hpre/hpre.h
index 9a0558ed82f9..9f0b94c8e03d 100644
--- a/drivers/crypto/hisilicon/hpre/hpre.h
+++ b/drivers/crypto/hisilicon/hpre/hpre.h
@@ -22,7 +22,8 @@ enum {
HPRE_CLUSTER0,
HPRE_CLUSTER1,
HPRE_CLUSTER2,
- HPRE_CLUSTER3
+ HPRE_CLUSTER3,
+ HPRE_CLUSTERS_NUM_MAX
};
enum hpre_ctrl_dbgfs_file {
@@ -42,9 +43,6 @@ enum hpre_dfx_dbgfs_file {
HPRE_DFX_FILE_NUM
};
-#define HPRE_CLUSTERS_NUM_V2 (HPRE_CLUSTER3 + 1)
-#define HPRE_CLUSTERS_NUM_V3 1
-#define HPRE_CLUSTERS_NUM_MAX HPRE_CLUSTERS_NUM_V2
#define HPRE_DEBUGFS_FILE_NUM (HPRE_DEBUG_FILE_NUM + HPRE_CLUSTERS_NUM_MAX - 1)
struct hpre_debugfs_file {
@@ -105,5 +103,5 @@ struct hpre_sqe {
struct hisi_qp *hpre_create_qp(u8 type);
int hpre_algs_register(struct hisi_qm *qm);
void hpre_algs_unregister(struct hisi_qm *qm);
-
+bool hpre_check_alg_support(struct hisi_qm *qm, u32 alg);
#endif