summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorOded Gabbay <ogabbay@kernel.org>2022-06-30 11:07:59 +0300
committerOded Gabbay <ogabbay@kernel.org>2022-07-12 09:09:29 +0300
commitc979cb5d8bf955e0303b951f066a9a525fda015f (patch)
tree071896ae21915d472bc2822670fdcdcab7536fc9 /drivers/misc
parent18913d68701918d784809e4b9462f51a7270e840 (diff)
downloadlinux-c979cb5d8bf955e0303b951f066a9a525fda015f.tar.bz2
habanalabs/gaudi2: remove unused variable
glbl_sts_clr_val was set but never used Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/habanalabs/gaudi2/gaudi2.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/drivers/misc/habanalabs/gaudi2/gaudi2.c b/drivers/misc/habanalabs/gaudi2/gaudi2.c
index 83da4247e71b..ed41673f2f23 100644
--- a/drivers/misc/habanalabs/gaudi2/gaudi2.c
+++ b/drivers/misc/habanalabs/gaudi2/gaudi2.c
@@ -6802,7 +6802,7 @@ static void print_qman_data_on_err(struct hl_device *hdev, u32 qid_base, u32 str
static void gaudi2_handle_qman_err_generic(struct hl_device *hdev, const char *qm_name,
u64 qman_base, u32 qid_base)
{
- u32 i, j, glbl_sts_val, arb_err_val, glbl_sts_clr_val, num_error_causes;
+ u32 i, j, glbl_sts_val, arb_err_val, num_error_causes;
u64 glbl_sts_addr, arb_err_addr;
char reg_desc[32];
@@ -6811,7 +6811,6 @@ static void gaudi2_handle_qman_err_generic(struct hl_device *hdev, const char *q
/* Iterate through all stream GLBL_ERR_STS registers + Lower CP */
for (i = 0 ; i < QMAN_STREAMS + 1 ; i++) {
- glbl_sts_clr_val = 0;
glbl_sts_val = RREG32(glbl_sts_addr + 4 * i);
if (!glbl_sts_val)
@@ -6825,16 +6824,13 @@ static void gaudi2_handle_qman_err_generic(struct hl_device *hdev, const char *q
num_error_causes = GAUDI2_NUM_OF_QM_ERR_CAUSE;
}
- for (j = 0 ; j < num_error_causes ; j++) {
- if (glbl_sts_val & BIT(j)) {
+ for (j = 0 ; j < num_error_causes ; j++)
+ if (glbl_sts_val & BIT(j))
dev_err_ratelimited(hdev->dev, "%s %s. err cause: %s\n",
qm_name, reg_desc,
i == QMAN_STREAMS ?
gaudi2_qman_lower_cp_error_cause[j] :
gaudi2_qman_error_cause[j]);
- glbl_sts_clr_val |= BIT(j);
- }
- }
print_qman_data_on_err(hdev, qid_base, i, qman_base);
}