From: "Justin P. Mattock" <justinmattock@gmail.com>
To: dri-devel@lists.freedesktop.org
Cc: airlied@redhat.com, linux-kernel@vger.kernel.org,
"Justin P. Mattock" <justinmattock@gmail.com>
Subject: [PATCH 5/8 v2]drm:drm_gem Fix warning: variable 'dev' set but not used
Date: Mon, 21 Jun 2010 15:27:29 -0700 [thread overview]
Message-ID: <1277159249-22007-1-git-send-email-justinmattock@gmail.com> (raw)
This is a redu due to the original being completly wrong
(better to leave a warning than shut it off).
I've removed the "dev =" variable but then receive a
drm_gem.c:207:2: warning: statement with no effect
telling me this thing is not doing anything according to gcc
so the below patch fixes a warning from gcc:
CC [M] drivers/gpu/drm/drm_gem.o
drivers/gpu/drm/drm_gem.c: In function 'drm_gem_handle_delete':
drivers/gpu/drm/drm_gem.c:188:21: warning: variable 'dev' set but not used
have a look if you have the time, and if theres something else
to do then let me know(i'll test it out!!)
Signed-off-by: Justin P. Mattock <justinmattock@gmail.com>
---
drivers/gpu/drm/drm_gem.c | 2 --
1 files changed, 0 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/drm_gem.c b/drivers/gpu/drm/drm_gem.c
index 33dad3f..d1648bf 100644
--- a/drivers/gpu/drm/drm_gem.c
+++ b/drivers/gpu/drm/drm_gem.c
@@ -185,7 +185,6 @@ EXPORT_SYMBOL(drm_gem_object_alloc);
static int
drm_gem_handle_delete(struct drm_file *filp, u32 handle)
{
- struct drm_device *dev;
struct drm_gem_object *obj;
/* This is gross. The idr system doesn't let us try a delete and
@@ -205,7 +204,6 @@ drm_gem_handle_delete(struct drm_file *filp, u32 handle)
spin_unlock(&filp->table_lock);
return -EINVAL;
}
- dev = obj->dev;
/* Release reference and decrement refcount. */
idr_remove(&filp->object_idr, handle);
--
1.7.1.rc1.21.gf3bd6
reply other threads:[~2010-06-21 22:27 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1277159249-22007-1-git-send-email-justinmattock@gmail.com \
--to=justinmattock@gmail.com \
--cc=airlied@redhat.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=linux-kernel@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).