Skip to content

Commit 22362aa

Browse files
Wei Yongjungregkh
authored andcommitted
habanalabs: remove unused but set variable 'ctx_asid'
Gcc report warning as follows: drivers/misc/habanalabs/common/command_submission.c:373:6: warning: variable 'ctx_asid' set but not used [-Wunused-but-set-variable] 373 | int ctx_asid, rc; | ^~~~~~~~ This variable is not used in function cs_timedout(), this commit remove it to fix the warning. Reported-by: Hulk Robot <[email protected]> Signed-off-by: Wei Yongjun <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 8f04219 commit 22362aa

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/misc/habanalabs/common/command_submission.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ static void cs_do_release(struct kref *ref)
370370
static void cs_timedout(struct work_struct *work)
371371
{
372372
struct hl_device *hdev;
373-
int ctx_asid, rc;
373+
int rc;
374374
struct hl_cs *cs = container_of(work, struct hl_cs,
375375
work_tdr.work);
376376
rc = cs_get_unless_zero(cs);
@@ -386,7 +386,6 @@ static void cs_timedout(struct work_struct *work)
386386
cs->timedout = true;
387387

388388
hdev = cs->ctx->hdev;
389-
ctx_asid = cs->ctx->asid;
390389

391390
dev_err(hdev->dev,
392391
"Command submission %llu has not finished in time!\n",

0 commit comments

Comments
 (0)