All of lore.kernel.org
 help / color / mirror / Atom feed
From: Borislav Petkov <bp@alien8.de>
To: Takuya Yoshikawa <yoshikawa.takuya@oss.ntt.co.jp>
Cc: kvm@vger.kernel.org, linux-kernel@vger.kernel.org,
	takuya.yoshikawa@gmail.com
Subject: Re: KVM build warnings
Date: Mon, 30 May 2011 14:46:00 +0200	[thread overview]
Message-ID: <20110530124600.GB494@eferding.osrc.amd.com> (raw)
In-Reply-To: <20110530191426.336d23f4.yoshikawa.takuya@oss.ntt.co.jp>

On Mon, May 30, 2011 at 07:14:26PM +0900, Takuya Yoshikawa wrote:
> On Mon, 30 May 2011 11:46:04 +0200
> Borislav Petkov <bp@alien8.de> wrote:
> 
> > I get the following
> > 
> > In file included from arch/x86/kvm/mmu.c:2856:
> > arch/x86/kvm/paging_tmpl.h: In function ‘paging32_walk_addr_generic’:
> > arch/x86/kvm/paging_tmpl.h:124: warning: ‘ptep_user’ may be used uninitialized in this function
> > In file included from arch/x86/kvm/mmu.c:2852:
> > arch/x86/kvm/paging_tmpl.h: In function ‘paging64_walk_addr_generic’:
> > arch/x86/kvm/paging_tmpl.h:124: warning: ‘ptep_user’ may be used uninitialized in this function
> > 
> > when building -rc1. It looks like it is caused by
> > 6e2ca7d1802bf8ed9908435e34daa116662e7790 and sticking uninitialized_var() around
> > the ptep_user declaration looks like the easiest solution. But the code should
> > still be audited by someone who's familiar with it whether shutting up the
> > compiler doesn't cause an actual bug.
> 
> Sorry, it is my commit.
> 
> I think the logic guarantees that ptep_user won't be used until it is
> assigned some value.
> 
> It seems to be safe, IIUC.

Ok, thanks for confirming. I'll send a fix soon if no one beats me to
it.

-- 
Regards/Gruss,
Boris.

  reply	other threads:[~2011-05-30 13:11 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-30  9:46 KVM build warnings Borislav Petkov
2011-05-30 10:14 ` Takuya Yoshikawa
2011-05-30 12:46   ` Borislav Petkov [this message]
2011-05-30 20:11     ` [PATCH] kvm: Fix " Borislav Petkov
2011-05-31  7:38       ` Ingo Molnar
2011-05-31  8:19         ` Takuya Yoshikawa
2011-05-31  8:20         ` Avi Kivity
2011-05-31  9:02           ` Borislav Petkov
2011-05-31 10:26           ` Ingo Molnar
2011-06-07  7:28             ` Borislav Petkov
2011-06-07  7:58               ` Avi Kivity
2011-06-07  7:58                 ` Avi Kivity

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=20110530124600.GB494@eferding.osrc.amd.com \
    --to=bp@alien8.de \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=takuya.yoshikawa@gmail.com \
    --cc=yoshikawa.takuya@oss.ntt.co.jp \
    /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.