summaryrefslogtreecommitdiff
path: root/include/linux/hisi_acc_qm.h
diff options
context:
space:
mode:
authorWeili Qian <qianweili@huawei.com>2024-02-07 12:51:00 +0300
committerHerbert Xu <herbert@gondor.apana.org.au>2024-02-17 04:09:16 +0300
commitce133a22123055f5f988499cd9ac7953d2bf0677 (patch)
tree1214f390104a6304f509bba329149a28bad997f7 /include/linux/hisi_acc_qm.h
parent12b8ae68f50de200c038246c2496822f38b18fe2 (diff)
downloadlinux-ce133a22123055f5f988499cd9ac7953d2bf0677.tar.xz
crypto: hisilicon/qm - obtain stop queue status
The debugfs files 'dev_state' and 'dev_timeout' are added. Users can query the current queue stop status through these two files. And set the waiting timeout when the queue is released. dev_state: if dev_timeout is set, dev_state indicates the status of stopping the queue. 0 indicates that the queue is stopped successfully. Other values indicate that the queue stops fail. If dev_timeout is not set, the value of dev_state is 0; dev_timeout: if the queue fails to stop, the queue is released after waiting dev_timeout * 20ms. Signed-off-by: Weili Qian <qianweili@huawei.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'include/linux/hisi_acc_qm.h')
-rw-r--r--include/linux/hisi_acc_qm.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/hisi_acc_qm.h b/include/linux/hisi_acc_qm.h
index 720f10874a66..2d14742ad729 100644
--- a/include/linux/hisi_acc_qm.h
+++ b/include/linux/hisi_acc_qm.h
@@ -163,6 +163,11 @@ struct qm_dev_alg {
const char *alg;
};
+struct qm_dev_dfx {
+ u32 dev_state;
+ u32 dev_timeout;
+};
+
struct dfx_diff_registers {
u32 *regs;
u32 reg_offset;
@@ -191,6 +196,7 @@ struct qm_debug {
struct dentry *debug_root;
struct dentry *qm_d;
struct debugfs_file files[DEBUG_FILE_NUM];
+ struct qm_dev_dfx dev_dfx;
unsigned int *qm_last_words;
/* ACC engines recoreding last regs */
unsigned int *last_words;