* [PATCH -next] habanalabs: remove unused but set variable 'ctx_asid'
@ 2020-07-29 15:59 ` Wei Yongjun
0 siblings, 0 replies; 2+ messages in thread
From: Wei Yongjun @ 2020-07-29 15:59 UTC (permalink / raw)
To: Hulk Robot, Oded Gabbay, Arnd Bergmann, Greg Kroah-Hartman,
Sumit Semwal, Christian König, Omer Shpigelman, Tomer Tayar,
Ofir Bitton
Cc: Wei Yongjun, linux-media, dri-devel, linaro-mm-sig
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 <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
.../misc/habanalabs/common/command_submission.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/misc/habanalabs/common/command_submission.c b/drivers/misc/habanalabs/common/command_submission.c
index e096532c0e48..b9840e368eb5 100644
--- a/drivers/misc/habanalabs/common/command_submission.c
+++ b/drivers/misc/habanalabs/common/command_submission.c
@@ -370,7 +370,7 @@ static void cs_do_release(struct kref *ref)
static void cs_timedout(struct work_struct *work)
{
struct hl_device *hdev;
- int ctx_asid, rc;
+ int rc;
struct hl_cs *cs = container_of(work, struct hl_cs,
work_tdr.work);
rc = cs_get_unless_zero(cs);
@@ -386,7 +386,6 @@ static void cs_timedout(struct work_struct *work)
cs->timedout = true;
hdev = cs->ctx->hdev;
- ctx_asid = cs->ctx->asid;
dev_err(hdev->dev,
"Command submission %llu has not finished in time!\n",
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH -next] habanalabs: remove unused but set variable 'ctx_asid'
@ 2020-07-29 15:59 ` Wei Yongjun
0 siblings, 0 replies; 2+ messages in thread
From: Wei Yongjun @ 2020-07-29 15:59 UTC (permalink / raw)
To: Hulk Robot, Oded Gabbay, Arnd Bergmann, Greg Kroah-Hartman,
Sumit Semwal, Christian König, Omer Shpigelman, Tomer Tayar,
Ofir Bitton
Cc: linaro-mm-sig, Wei Yongjun, dri-devel, linux-media
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 <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
.../misc/habanalabs/common/command_submission.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/misc/habanalabs/common/command_submission.c b/drivers/misc/habanalabs/common/command_submission.c
index e096532c0e48..b9840e368eb5 100644
--- a/drivers/misc/habanalabs/common/command_submission.c
+++ b/drivers/misc/habanalabs/common/command_submission.c
@@ -370,7 +370,7 @@ static void cs_do_release(struct kref *ref)
static void cs_timedout(struct work_struct *work)
{
struct hl_device *hdev;
- int ctx_asid, rc;
+ int rc;
struct hl_cs *cs = container_of(work, struct hl_cs,
work_tdr.work);
rc = cs_get_unless_zero(cs);
@@ -386,7 +386,6 @@ static void cs_timedout(struct work_struct *work)
cs->timedout = true;
hdev = cs->ctx->hdev;
- ctx_asid = cs->ctx->asid;
dev_err(hdev->dev,
"Command submission %llu has not finished in time!\n",
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-07-30 7:16 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-29 15:59 [PATCH -next] habanalabs: remove unused but set variable 'ctx_asid' Wei Yongjun
2020-07-29 15:59 ` Wei Yongjun
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.