lkml.org 
[lkml]   [2019]   [Sep]   [29]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH -next] habanalabs: remove set but not used variable 'ctx'
On Sat, Sep 28, 2019 at 7:18 AM YueHaibing <yuehaibing@huawei.com> wrote:
>
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/misc/habanalabs/device.c: In function hpriv_release:
> drivers/misc/habanalabs/device.c:45:17: warning: variable ctx set but not used [-Wunused-but-set-variable]
>
> It is never used since commit eb7caf84b029 ("habanalabs:
> maintain a list of file private data objects")
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
> ---
> drivers/misc/habanalabs/device.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/misc/habanalabs/device.c b/drivers/misc/habanalabs/device.c
> index 459fee7..2f5a4da 100644
> --- a/drivers/misc/habanalabs/device.c
> +++ b/drivers/misc/habanalabs/device.c
> @@ -42,12 +42,10 @@ static void hpriv_release(struct kref *ref)
> {
> struct hl_fpriv *hpriv;
> struct hl_device *hdev;
> - struct hl_ctx *ctx;
>
> hpriv = container_of(ref, struct hl_fpriv, refcount);
>
> hdev = hpriv->hdev;
> - ctx = hpriv->ctx;
>
> put_pid(hpriv->taskpid);
>
> --
> 2.7.4
>
>

This patch is:
Reviewed-by: Oded Gabbay <oded.gabbay@gmail.com>
Applied to -next.
Thanks,
Oded

\
 
 \ /
  Last update: 2019-09-29 11:38    [W:0.468 / U:0.020 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site