Kernel KVM virtualization development
 help / color / mirror / Atom feed
From: hollis_blanchard-nmGgyN9QBj3QT0dZR+AlfA@public.gmane.org
To: avi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org
Cc: kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	kvm-ppc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	agraf-l3A5Bk7waGM@public.gmane.org
Subject: [PATCH 3 of 3] KVM: PPC: allow ppc440gp to pass the compatibility check
Date: Sat, 07 Aug 2010 10:33:58 -0700	[thread overview]
Message-ID: <30a34703c8ab806a405d.1281202438@localhost6.localdomain6> (raw)
In-Reply-To: <patchbomb.1281202435-bi+AKbBUZKagILUCTcTcHdKyNwTtLsGr@public.gmane.org>

Match only the first part of cur_cpu_spec->platform.

440GP (the first 440 processor) is identified by the string "ppc440gp", while
all later 440 processors use simply "ppc440".

Signed-off-by: Hollis Blanchard <hollis_blanchard-nmGgyN9QBj3QT0dZR+AlfA@public.gmane.org>


---
 arch/powerpc/kvm/44x.c |  3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)


diff --git a/arch/powerpc/kvm/44x.c b/arch/powerpc/kvm/44x.c
--- a/arch/powerpc/kvm/44x.c
+++ b/arch/powerpc/kvm/44x.c
@@ -43,7 +43,7 @@ int kvmppc_core_check_processor_compat(v
 {
 	int r;
 
-	if (strcmp(cur_cpu_spec->platform, "ppc440") == 0)
+	if (strncmp(cur_cpu_spec->platform, "ppc440", 6) == 0)
 		r = 0;
 	else
 		r = -ENOTSUPP;
@@ -72,6 +72,7 @@ int kvmppc_core_vcpu_setup(struct kvm_vc
 	/* Since the guest can directly access the timebase, it must know the
 	 * real timebase frequency. Accordingly, it must see the state of
 	 * CCR1[TCS]. */
+	/* XXX CCR1 doesn't exist on all 440 SoCs. */
 	vcpu->arch.ccr1 = mfspr(SPRN_CCR1);
 
 	for (i = 0; i < ARRAY_SIZE(vcpu_44x->shadow_refs); i++)

  parent reply	other threads:[~2010-08-07 17:33 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-07 17:33 [PATCH 0 of 3] Fix KVM on PowerPC 440GP hollis_blanchard
2010-08-07 17:33 ` [PATCH 1 of 3] KVM: PPC: initialize IVORs in addition to IVPR hollis_blanchard
2010-08-16 13:19 ` [PATCH 0 of 3] Fix KVM on PowerPC 440GP Alexander Graf
     [not found] ` <patchbomb.1281202435-bi+AKbBUZKagILUCTcTcHdKyNwTtLsGr@public.gmane.org>
2010-08-07 17:33   ` [PATCH 2 of 3] KVM: PPC: fix compilation of "dump tlbs" debug function hollis_blanchard-nmGgyN9QBj3QT0dZR+AlfA
2010-08-07 17:33   ` hollis_blanchard-nmGgyN9QBj3QT0dZR+AlfA [this message]
2010-08-17  9:27   ` [PATCH 0 of 3] Fix KVM on PowerPC 440GP Avi Kivity
     [not found]     ` <4C6A561B.9080903-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2010-08-17  9:35       ` Alexander Graf

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=30a34703c8ab806a405d.1281202438@localhost6.localdomain6 \
    --to=hollis_blanchard-nmggyn9qbj3qt0dzr+alfa@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 \
    /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