18213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/clear_enable 2cbfe56e6SLongfang LiuDate: Oct 2019 3cbfe56e6SLongfang LiuContact: linux-crypto@vger.kernel.org 4cbfe56e6SLongfang LiuDescription: Enabling/disabling of clear action after reading 5cbfe56e6SLongfang Liu the SEC debug registers. 6cbfe56e6SLongfang Liu 0: disable, 1: enable. 7cbfe56e6SLongfang Liu Only available for PF, and take no other effect on SEC. 8cbfe56e6SLongfang Liu 98213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/current_qm 10cbfe56e6SLongfang LiuDate: Oct 2019 11cbfe56e6SLongfang LiuContact: linux-crypto@vger.kernel.org 12cbfe56e6SLongfang LiuDescription: One SEC controller has one PF and multiple VFs, each function 13cbfe56e6SLongfang Liu has a QM. This file can be used to select the QM which below 14cbfe56e6SLongfang Liu qm refers to. 15cbfe56e6SLongfang Liu Only available for PF. 16cbfe56e6SLongfang Liu 1753576186SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/alg_qos 1853576186SKai YeDate: Jun 2021 1953576186SKai YeContact: linux-crypto@vger.kernel.org 2053576186SKai YeDescription: The <bdf> is related the function for PF and VF. 2153576186SKai Ye SEC driver supports to configure each function's QoS, the driver 2253576186SKai Ye supports to write <bdf> value to alg_qos in the host. Such as 2353576186SKai Ye "echo <bdf> value > alg_qos". The qos value is 1~1000, means 2453576186SKai Ye 1/1000~1000/1000 of total QoS. The driver reading alg_qos to 2553576186SKai Ye get related QoS in the host and VM, Such as "cat alg_qos". 2653576186SKai Ye 27*b44c7129SZongyu WuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/dev_usage 28*b44c7129SZongyu WuDate: Mar 2026 29*b44c7129SZongyu WuContact: linux-crypto@vger.kernel.org 30*b44c7129SZongyu WuDescription: Query the real-time bandwidth usage of device. 31*b44c7129SZongyu Wu Returns the bandwidth usage of each channel on the device. 32*b44c7129SZongyu Wu The returned number is in percentage. 33*b44c7129SZongyu Wu 348213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/qm_regs 35cbfe56e6SLongfang LiuDate: Oct 2019 36cbfe56e6SLongfang LiuContact: linux-crypto@vger.kernel.org 37cbfe56e6SLongfang LiuDescription: Dump of QM related debug registers. 38cbfe56e6SLongfang Liu Available for PF and VF in host. VF in guest currently only 39cbfe56e6SLongfang Liu has one debug register. 40cbfe56e6SLongfang Liu 418213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/current_q 42cbfe56e6SLongfang LiuDate: Oct 2019 43cbfe56e6SLongfang LiuContact: linux-crypto@vger.kernel.org 44cbfe56e6SLongfang LiuDescription: One QM of SEC may contain multiple queues. Select specific 45988453fbSShukun Tan queue to show its debug registers in above 'regs'. 46cbfe56e6SLongfang Liu Only available for PF. 47cbfe56e6SLongfang Liu 488213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/clear_enable 49cbfe56e6SLongfang LiuDate: Oct 2019 50cbfe56e6SLongfang LiuContact: linux-crypto@vger.kernel.org 51cbfe56e6SLongfang LiuDescription: Enabling/disabling of clear action after reading 52cbfe56e6SLongfang Liu the SEC's QM debug registers. 53cbfe56e6SLongfang Liu 0: disable, 1: enable. 54cbfe56e6SLongfang Liu Only available for PF, and take no other effect on SEC. 5585026525SLongfang Liu 5685026525SLongfang LiuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/err_irq 5785026525SLongfang LiuDate: Apr 2020 5885026525SLongfang LiuContact: linux-crypto@vger.kernel.org 5985026525SLongfang LiuDescription: Dump the number of invalid interrupts for 6085026525SLongfang Liu QM task completion. 6185026525SLongfang Liu Available for both PF and VF, and take no other effect on SEC. 6285026525SLongfang Liu 6385026525SLongfang LiuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/aeq_irq 6485026525SLongfang LiuDate: Apr 2020 6585026525SLongfang LiuContact: linux-crypto@vger.kernel.org 6685026525SLongfang LiuDescription: Dump the number of QM async event queue interrupts. 6785026525SLongfang Liu Available for both PF and VF, and take no other effect on SEC. 6885026525SLongfang Liu 6985026525SLongfang LiuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/abnormal_irq 7085026525SLongfang LiuDate: Apr 2020 7185026525SLongfang LiuContact: linux-crypto@vger.kernel.org 7285026525SLongfang LiuDescription: Dump the number of interrupts for QM abnormal event. 7385026525SLongfang Liu Available for both PF and VF, and take no other effect on SEC. 7485026525SLongfang Liu 7585026525SLongfang LiuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/create_qp_err 7685026525SLongfang LiuDate: Apr 2020 7785026525SLongfang LiuContact: linux-crypto@vger.kernel.org 7885026525SLongfang LiuDescription: Dump the number of queue allocation errors. 7985026525SLongfang Liu Available for both PF and VF, and take no other effect on SEC. 8085026525SLongfang Liu 8185026525SLongfang LiuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/mb_err 8285026525SLongfang LiuDate: Apr 2020 8385026525SLongfang LiuContact: linux-crypto@vger.kernel.org 8485026525SLongfang LiuDescription: Dump the number of failed QM mailbox commands. 8585026525SLongfang Liu Available for both PF and VF, and take no other effect on SEC. 860a3a3960SLongfang Liu 870a3a3960SLongfang LiuWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/status 880a3a3960SLongfang LiuDate: Apr 2020 890a3a3960SLongfang LiuContact: linux-crypto@vger.kernel.org 900a3a3960SLongfang LiuDescription: Dump the status of the QM. 91c66272a4SWeili Qian Two states: work, stop. 920a3a3960SLongfang Liu Available for both PF and VF, and take no other effect on SEC. 938213a1a6SKai Ye 9473e3b46eSKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/diff_regs 9573e3b46eSKai YeDate: Mar 2022 9673e3b46eSKai YeContact: linux-crypto@vger.kernel.org 9773e3b46eSKai YeDescription: QM debug registers(regs) read hardware register value. This 9873e3b46eSKai Ye node is used to show the change of the qm register values. This 9973e3b46eSKai Ye node can be help users to check the change of register values. 10073e3b46eSKai Ye 1018413fe3eSWeili QianWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/qm_state 1028413fe3eSWeili QianDate: Jan 2024 1038413fe3eSWeili QianContact: linux-crypto@vger.kernel.org 1048413fe3eSWeili QianDescription: Dump the state of the device. 1058413fe3eSWeili Qian 0: busy, 1: idle. 1068413fe3eSWeili Qian Only available for PF, and take no other effect on SEC. 1078413fe3eSWeili Qian 108ce133a22SWeili QianWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/dev_timeout 109ce133a22SWeili QianDate: Feb 2024 110ce133a22SWeili QianContact: linux-crypto@vger.kernel.org 111ce133a22SWeili QianDescription: Set the wait time when stop queue fails. Available for both PF 112ce133a22SWeili Qian and VF, and take no other effect on SEC. 113ce133a22SWeili Qian 0: not wait(default), others value: wait dev_timeout * 20 microsecond. 114ce133a22SWeili Qian 115ce133a22SWeili QianWhat: /sys/kernel/debug/hisi_sec2/<bdf>/qm/dev_state 116ce133a22SWeili QianDate: Feb 2024 117ce133a22SWeili QianContact: linux-crypto@vger.kernel.org 118ce133a22SWeili QianDescription: Dump the stop queue status of the QM. The default value is 0, 119ce133a22SWeili Qian if dev_timeout is set, when stop queue fails, the dev_state 120ce133a22SWeili Qian will return non-zero value. Available for both PF and VF, 121ce133a22SWeili Qian and take no other effect on SEC. 122ce133a22SWeili Qian 12373e3b46eSKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/diff_regs 12473e3b46eSKai YeDate: Mar 2022 12573e3b46eSKai YeContact: linux-crypto@vger.kernel.org 12673e3b46eSKai YeDescription: SEC debug registers(regs) read hardware register value. This 12773e3b46eSKai Ye node is used to show the change of the register values. This 12873e3b46eSKai Ye node can be help users to check the change of register values. 12973e3b46eSKai Ye 1308213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/send_cnt 1318213a1a6SKai YeDate: Apr 2020 1328213a1a6SKai YeContact: linux-crypto@vger.kernel.org 1338213a1a6SKai YeDescription: Dump the total number of sent requests. 1348213a1a6SKai Ye Available for both PF and VF, and take no other effect on SEC. 1358213a1a6SKai Ye 1368213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/recv_cnt 1378213a1a6SKai YeDate: Apr 2020 1388213a1a6SKai YeContact: linux-crypto@vger.kernel.org 1398213a1a6SKai YeDescription: Dump the total number of received requests. 1408213a1a6SKai Ye Available for both PF and VF, and take no other effect on SEC. 1418213a1a6SKai Ye 1428213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/send_busy_cnt 1438213a1a6SKai YeDate: Apr 2020 1448213a1a6SKai YeContact: linux-crypto@vger.kernel.org 1458213a1a6SKai YeDescription: Dump the total number of requests sent with returning busy. 1468213a1a6SKai Ye Available for both PF and VF, and take no other effect on SEC. 1478213a1a6SKai Ye 1488213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/err_bd_cnt 1498213a1a6SKai YeDate: Apr 2020 1508213a1a6SKai YeContact: linux-crypto@vger.kernel.org 1518213a1a6SKai YeDescription: Dump the total number of BD type error requests 1528213a1a6SKai Ye to be received. 1538213a1a6SKai Ye Available for both PF and VF, and take no other effect on SEC. 1548213a1a6SKai Ye 1558213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/invalid_req_cnt 1568213a1a6SKai YeDate: Apr 2020 1578213a1a6SKai YeContact: linux-crypto@vger.kernel.org 1588213a1a6SKai YeDescription: Dump the total number of invalid requests being received. 1598213a1a6SKai Ye Available for both PF and VF, and take no other effect on SEC. 1608213a1a6SKai Ye 1618213a1a6SKai YeWhat: /sys/kernel/debug/hisi_sec2/<bdf>/sec_dfx/done_flag_cnt 1628213a1a6SKai YeDate: Apr 2020 1638213a1a6SKai YeContact: linux-crypto@vger.kernel.org 1648213a1a6SKai YeDescription: Dump the total number of completed but marked error requests 1658213a1a6SKai Ye to be received. 1668213a1a6SKai Ye Available for both PF and VF, and take no other effect on SEC. 1672a69297eSQi Tao 1682a69297eSQi TaoWhat: /sys/kernel/debug/hisi_sec2/<bdf>/cap_regs 1692a69297eSQi TaoDate: Oct 2024 1702a69297eSQi TaoContact: linux-crypto@vger.kernel.org 1712a69297eSQi TaoDescription: Dump the values of the qm and sec capability bit registers and 1722a69297eSQi Tao support the query of device specifications to facilitate fault locating. 1732a69297eSQi Tao Available for both PF and VF, and take no other effect on SEC. 174