From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Andrew Morton <akpm@osdl.org>
Cc: Linus Torvalds <torvalds@osdl.org>,
Linux Kernel list <linux-kernel@vger.kernel.org>
Subject: [PATCH] radeonfb: Fix warnings about uninitialized variables
Date: Wed, 15 Sep 2004 17:21:47 +1000 [thread overview]
Message-ID: <1095232906.4537.459.camel@gaston> (raw)
Hi !
This patch fixes a couple of warnings about possible uninitialized
variables in radeonfb, along with a small logic error in the monitor
probe code when nothing was found.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
===== drivers/video/aty/radeon_base.c 1.28 vs edited =====
--- 1.28/drivers/video/aty/radeon_base.c 2004-09-13 14:05:55 +10:00
+++ edited/drivers/video/aty/radeon_base.c 2004-09-15 17:20:16 +10:00
@@ -1868,7 +1868,7 @@
#undef SET_MC_FB_FROM_APERTURE
static void fixup_memory_mappings(struct radeonfb_info *rinfo)
{
- u32 save_crtc_gen_cntl, save_crtc2_gen_cntl;
+ u32 save_crtc_gen_cntl, save_crtc2_gen_cntl = 0;
u32 save_crtc_ext_cntl;
u32 aper_base, aper_size;
u32 agp_base;
===== drivers/video/aty/radeon_monitor.c 1.7 vs edited =====
--- 1.7/drivers/video/aty/radeon_monitor.c 2004-05-17 01:59:32 +10:00
+++ edited/drivers/video/aty/radeon_monitor.c 2004-09-15 17:19:25 +10:00
@@ -69,8 +69,10 @@
mt = MT_DFP;
else if (!strcmp(pmt, "CRT"))
mt = MT_CRT;
- else if (strcmp(pmt, "NONE")) {
- printk(KERN_WARNING "radeonfb: Unknown OF display-type: %s\n", pmt);
+ else {
+ if (strcmp(pmt, "NONE") != 0)
+ printk(KERN_WARNING "radeonfb: Unknown OF display-type: %s\n",
+ pmt);
return MT_NONE;
}
for (i = 0; propnames[i] != NULL; ++i) {
reply other threads:[~2004-09-15 7: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=1095232906.4537.459.camel@gaston \
--to=benh@kernel.crashing.org \
--cc=akpm@osdl.org \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@osdl.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