public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Bruce Majia <bruce.majia-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: Alexander Graf <agraf-l3A5Bk7waGM@public.gmane.org>
Cc: Avi Kivity <avi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
	kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	kvm-ppc <kvm-ppc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
	Liu Yu <yu.liu-KZfg59tc24xl57MIdRCFDg@public.gmane.org>
Subject: Re: [PATCH] KVM: PPC: E500 compile fix
Date: Fri, 26 Mar 2010 18:40:59 +0800	[thread overview]
Message-ID: <20100326104059.GA26690@localhost> (raw)
In-Reply-To: <A306CC20-B0E4-4C6B-BAE4-A4F955E6663E-l3A5Bk7waGM@public.gmane.org>

On Fri, Mar 26, 2010 at 10:10:19AM +0100, Alexander Graf wrote:
> 
> On 26.03.2010, at 08:15, Bruce Majia wrote:
> 
> > On Sun, Jan 17, 2010 at 03:06:11PM +0200, Avi Kivity wrote:
> >> On 01/10/2010 07:01 PM, Alexander Graf wrote:
> >>> While trying to compile an E500 vmlinux, I stumbled across a compilation bug
> >>> that was obviously there before I touched any of the code. A trace point
> >>> doesn't get the correct arguments.
> >>> 
> >>> Since that shouldn't be any critical to the functionality of the code, my quick
> >>> workaround is to #if 0 it out. I would very much appreciate someone fixing it
> >>> properly though.
> >>> 
> >>> Liu, it would be nice if you could be the one doing that.
> >>> 
> >> 
> >> Applied, thanks.
> > 
> > Hi Avi,
> > 
> > Seems the problem still exists in the mainline kernel. Are you guys miss
> > something in the past few months? Does it means even if I passed compile
> > phase with the '#if 0' workaround, it's functions are not completed yet.
> > So its impossible to try kvm on ppc e500 target?
> 
> If #if 0 only affects you if you want to trace that specific function. It's probably safe to say you don't care, so just #if 0 it out and be good :-).
> 
> Alex

I'd like to say I am okay with #if 0 stuff. :) But fail to have the
source code compiled is bad. Based on latest linus tree, I have to
apply following stuff to make KVM + mpc85xx_defconfig pass build phase:

---
 arch/powerpc/kvm/booke.c    |    2 +-
 arch/powerpc/kvm/e500_tlb.c |    2 ++
 arch/powerpc/kvm/powerpc.c  |    2 +-
 3 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/arch/powerpc/kvm/booke.c b/arch/powerpc/kvm/booke.c
index 4d686cc..0cde83b 100644
--- a/arch/powerpc/kvm/booke.c
+++ b/arch/powerpc/kvm/booke.c
@@ -137,7 +137,7 @@ static int kvmppc_booke_irqprio_deliver(struct kvm_vcpu *vcpu,
                                         unsigned int priority)
 {
 	int allowed = 0;
-	ulong msr_mask;
+	ulong msr_mask = 0;
 	bool update_esr = false, update_dear = false;
 
 	switch (priority) {
diff --git a/arch/powerpc/kvm/e500_tlb.c b/arch/powerpc/kvm/e500_tlb.c
index 0d772e6..c52e8c2 100644
--- a/arch/powerpc/kvm/e500_tlb.c
+++ b/arch/powerpc/kvm/e500_tlb.c
@@ -225,8 +225,10 @@ static void kvmppc_e500_stlbe_invalidate(struct kvmppc_vcpu_e500 *vcpu_e500,
 
 	kvmppc_e500_shadow_release(vcpu_e500, tlbsel, esel);
 	stlbe->mas1 = 0;
+#if 0
 	trace_kvm_stlb_inval(index_of(tlbsel, esel), stlbe->mas1, stlbe->mas2,
 			     stlbe->mas3, stlbe->mas7);
+#endif
 }
 
 static void kvmppc_e500_tlb1_invalidate(struct kvmppc_vcpu_e500 *vcpu_e500,
diff --git a/arch/powerpc/kvm/powerpc.c b/arch/powerpc/kvm/powerpc.c
index 51aedd7..372b678 100644
--- a/arch/powerpc/kvm/powerpc.c
+++ b/arch/powerpc/kvm/powerpc.c
@@ -277,7 +277,7 @@ static void kvmppc_complete_dcr_load(struct kvm_vcpu *vcpu,
 static void kvmppc_complete_mmio_load(struct kvm_vcpu *vcpu,
                                       struct kvm_run *run)
 {
-	ulong gpr;
+	ulong gpr = 0;
 
 	if (run->mmio.len > sizeof(gpr)) {
 		printk(KERN_ERR "bad MMIO length: %d\n", run->mmio.len);
-- 

Do we need a *temporary* patch for the situation?

Regards,
-bm

  parent reply	other threads:[~2010-03-26 10:40 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-01-10 17:01 [PATCH] KVM: PPC: E500 compile fix Alexander Graf
2010-01-11  7:05 ` Liu Yu-B13201
     [not found]   ` <0A1FE637C2C7E148B9573BB60CC630E56C3F14-bKEhWGtIRUJ4Lp7cDGe+DVjVikpgYyvb5NbjCUgZEJk@public.gmane.org>
2010-01-12  0:09     ` Alexander Graf
2010-01-17 13:06 ` Avi Kivity
2010-03-26  7:15   ` Bruce Majia
2010-03-26  9:10     ` Alexander Graf
     [not found]       ` <A306CC20-B0E4-4C6B-BAE4-A4F955E6663E-l3A5Bk7waGM@public.gmane.org>
2010-03-26  9:14         ` Liu Yu-B13201
2010-03-26 10:40         ` Bruce Majia [this message]
2010-03-26 10:50           ` Alexander Graf
     [not found]             ` <272B4229-9AC7-4D29-820F-5F958D4CC71C-l3A5Bk7waGM@public.gmane.org>
2010-03-26 11:20               ` Bruce Majia

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=20100326104059.GA26690@localhost \
    --to=bruce.majia-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=agraf-l3A5Bk7waGM@public.gmane.org \
    --cc=avi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org \
    --cc=kvm-ppc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=yu.liu-KZfg59tc24xl57MIdRCFDg@public.gmane.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