From: Johannes Weiner <hnazfoo@googlemail.com>
To: linux-kernel@vger.kernel.org
Subject: [PATCH] Prevent usage of uninitialized variable in transmeta cpu driver
Date: Sun, 23 Jul 2006 23:48:34 +0200 [thread overview]
Message-ID: <20060723214834.GA1484@leiferikson.gentoo> (raw)
[-- Attachment #1: Type: text/plain, Size: 142 bytes --]
This patch fixes a gcc-`uninitialized' warning in
arch/i386/kernel/cpu/transmeta.c.
Signed-off-by: Johannes Weiner <hnazfoo@gmail.com>
---
[-- Attachment #2: transmeta-suppress-warning.patch --]
[-- Type: text/plain, Size: 1023 bytes --]
diff --git a/arch/i386/kernel/cpu/transmeta.c b/arch/i386/kernel/cpu/transmeta.c
index 7214c9b..5b71071 100644
--- a/arch/i386/kernel/cpu/transmeta.c
+++ b/arch/i386/kernel/cpu/transmeta.c
@@ -17,9 +17,9 @@ static void __init init_transmeta(struct
/* Print CMS and CPU revision */
max = cpuid_eax(0x80860000);
- cpu_rev = 0;
+ cpu_rev = cpu_freq = 0;
if ( max >= 0x80860001 ) {
- cpuid(0x80860001, &dummy, &cpu_rev, &cpu_freq, &cpu_flags);
+ cpuid(0x80860001, &dummy, &cpu_rev, &cpu_freq, &cpu_flags);
if (cpu_rev != 0x02000000) {
printk(KERN_INFO "CPU: Processor revision %u.%u.%u.%u, %u MHz\n",
(cpu_rev >> 24) & 0xff,
@@ -72,7 +72,7 @@ static void __init init_transmeta(struct
wrmsr(0x80860004, ~0, uk);
c->x86_capability[0] = cpuid_edx(0x00000001);
wrmsr(0x80860004, cap_mask, uk);
-
+
/* If we can run i686 user-space code, call us an i686 */
#define USER686 (X86_FEATURE_TSC|X86_FEATURE_CX8|X86_FEATURE_CMOV)
if ( c->x86 == 5 && (c->x86_capability[0] & USER686) == USER686 )
next reply other threads:[~2006-07-23 21:49 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-23 21:48 Johannes Weiner [this message]
2006-07-23 23:57 ` Jiri Slaby
2006-07-24 5:46 ` Johannes Weiner
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=20060723214834.GA1484@leiferikson.gentoo \
--to=hnazfoo@googlemail.com \
--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
all inboxes | Powered by JetHome®