From: Daniel Vetter <daniel@ffwll.ch>
To: YueHaibing <yuehaibing@huawei.com>
Cc: Dave Airlie <airlied@redhat.com>, David Airlie <airlied@linux.ie>,
Sam Bobroff <sbobroff@linux.ibm.com>,
Daniel Vetter <daniel.vetter@ffwll.ch>,
dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
kernel-janitors@vger.kernel.org
Subject: Re: [PATCH -next] drm/ast: Remove set but not used variable 'bo'
Date: Mon, 10 Dec 2018 10:27:01 +0000 [thread overview]
Message-ID: <20181210102701.GP21184@phenom.ffwll.local> (raw)
In-Reply-To: <1544258185-50430-1-git-send-email-yuehaibing@huawei.com>
On Sat, Dec 08, 2018 at 08:36:25AM +0000, YueHaibing wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/gpu/drm/ast/ast_fb.c: In function 'astfb_create':
> drivers/gpu/drm/ast/ast_fb.c:194:17: warning:
> variable 'bo' set but not used [-Wunused-but-set-variable]
>
> It never used since introduction in commit 312fec1405dd ("drm: Initial KMS
> driver for AST (ASpeed Technologies) 2000 series (v2)")
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Applied, thanks.
-Daniel
> ---
> drivers/gpu/drm/ast/ast_fb.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/ast/ast_fb.c b/drivers/gpu/drm/ast/ast_fb.c
> index de26df0..c2e4136 100644
> --- a/drivers/gpu/drm/ast/ast_fb.c
> +++ b/drivers/gpu/drm/ast/ast_fb.c
> @@ -191,7 +191,6 @@ static int astfb_create(struct drm_fb_helper *helper,
> int size, ret;
> void *sysram;
> struct drm_gem_object *gobj = NULL;
> - struct ast_bo *bo = NULL;
> mode_cmd.width = sizes->surface_width;
> mode_cmd.height = sizes->surface_height;
> mode_cmd.pitches[0] = mode_cmd.width * ((sizes->surface_bpp + 7)/8);
> @@ -206,7 +205,6 @@ static int astfb_create(struct drm_fb_helper *helper,
> DRM_ERROR("failed to create fbcon backing object %d\n", ret);
> return ret;
> }
> - bo = gem_to_ast_bo(gobj);
>
> sysram = vmalloc(size);
> if (!sysram)
>
>
>
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
WARNING: multiple messages have this Message-ID (diff)
From: Daniel Vetter <daniel@ffwll.ch>
To: YueHaibing <yuehaibing@huawei.com>
Cc: Dave Airlie <airlied@redhat.com>, David Airlie <airlied@linux.ie>,
Sam Bobroff <sbobroff@linux.ibm.com>,
Daniel Vetter <daniel.vetter@ffwll.ch>,
dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
kernel-janitors@vger.kernel.org
Subject: Re: [PATCH -next] drm/ast: Remove set but not used variable 'bo'
Date: Mon, 10 Dec 2018 11:27:01 +0100 [thread overview]
Message-ID: <20181210102701.GP21184@phenom.ffwll.local> (raw)
In-Reply-To: <1544258185-50430-1-git-send-email-yuehaibing@huawei.com>
On Sat, Dec 08, 2018 at 08:36:25AM +0000, YueHaibing wrote:
> Fixes gcc '-Wunused-but-set-variable' warning:
>
> drivers/gpu/drm/ast/ast_fb.c: In function 'astfb_create':
> drivers/gpu/drm/ast/ast_fb.c:194:17: warning:
> variable 'bo' set but not used [-Wunused-but-set-variable]
>
> It never used since introduction in commit 312fec1405dd ("drm: Initial KMS
> driver for AST (ASpeed Technologies) 2000 series (v2)")
>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Applied, thanks.
-Daniel
> ---
> drivers/gpu/drm/ast/ast_fb.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/ast/ast_fb.c b/drivers/gpu/drm/ast/ast_fb.c
> index de26df0..c2e4136 100644
> --- a/drivers/gpu/drm/ast/ast_fb.c
> +++ b/drivers/gpu/drm/ast/ast_fb.c
> @@ -191,7 +191,6 @@ static int astfb_create(struct drm_fb_helper *helper,
> int size, ret;
> void *sysram;
> struct drm_gem_object *gobj = NULL;
> - struct ast_bo *bo = NULL;
> mode_cmd.width = sizes->surface_width;
> mode_cmd.height = sizes->surface_height;
> mode_cmd.pitches[0] = mode_cmd.width * ((sizes->surface_bpp + 7)/8);
> @@ -206,7 +205,6 @@ static int astfb_create(struct drm_fb_helper *helper,
> DRM_ERROR("failed to create fbcon backing object %d\n", ret);
> return ret;
> }
> - bo = gem_to_ast_bo(gobj);
>
> sysram = vmalloc(size);
> if (!sysram)
>
>
>
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
next prev parent reply other threads:[~2018-12-10 10:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-08 8:36 [PATCH -next] drm/ast: Remove set but not used variable 'bo' YueHaibing
2018-12-08 8:36 ` YueHaibing
2018-12-08 8:36 ` YueHaibing
2018-12-10 10:27 ` Daniel Vetter [this message]
2018-12-10 10:27 ` Daniel Vetter
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20181210102701.GP21184@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=airlied@linux.ie \
--cc=airlied@redhat.com \
--cc=daniel.vetter@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sbobroff@linux.ibm.com \
--cc=yuehaibing@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.