qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: David Gibson <david@gibson.dropbear.id.au>
To: Greg Kurz <groug@kaod.org>
Cc: Andrea Bolognani <abologna@redhat.com>,
	clg@kaod.org, aik@ozlabs.ru, mdroth@linux.vnet.ibm.com,
	nikunj@linux.vnet.ibm.com, agraf@suse.de, armbru@redhat.com,
	qemu-devel@nongnu.org, qemu-ppc@nongnu.org
Subject: Re: [Qemu-devel] [PATCHv3 2/4] pseries: Move CPU compatibility property to machine
Date: Fri, 12 May 2017 17:08:43 +1000	[thread overview]
Message-ID: <20170512070843.GA15313@umbus.fritz.box> (raw)
In-Reply-To: <20170504205047.161b45ca@bahia>

[-- Attachment #1: Type: text/plain, Size: 2216 bytes --]

On Thu, May 04, 2017 at 08:50:47PM +0200, Greg Kurz wrote:
> On Thu, 04 May 2017 19:09:11 +0200
> Andrea Bolognani <abologna@redhat.com> wrote:
> 
> > On Thu, 2017-04-27 at 17:28 +1000, David Gibson wrote:
> > > @@ -2480,6 +2480,10 @@ static void spapr_machine_initfn(Object *obj)
> > >                                      " place of standard EPOW events when possible"
> > >                                      " (required for memory hot-unplug support)",
> > >                                      NULL);
> > > +
> > > +    object_property_add(obj, "max-cpu-compat", "str",
> > > +                        ppc_compat_prop_get, ppc_compat_prop_set,
> > > +                        NULL, &spapr->max_compat_pvr, &error_fatal);  
> > 
> > I'm not familiar with QEMU's object system, but shouldn't
> > you be using object_property_add_str() instead? It looks
> > like you're doing more than the straightforward wrapper
> > would do, so maybe that's just not possible.
> > 
> > 
> > In any case, all other string properties look like
> > 
> >   pseries-2.10.kvm-type=string
> > 
> > whereas this one ends up looking like
> > 
> >   pseries-2.10.max-cpu-compat=str
> > 
> > which I think should be fixed - object_property_add_str()
> > passes "string" instead of "str" to object_property_add().
> > 
> > You should also add a sensible description for the property,
> > preferably spelling out all the accepted values.
> > 
> > 
> > Speaking of properties...
> > 
> >   $ qemu-system-ppc64 -cpu host,compat=whatever
> >   Segmentation fault
> > 
> > You might want to look into that ;)
> > 
> 
> This happens because patch 2 is missing a change for the recently added POWER9:
> 
>          .max_threads = 8,
>      },
>      { /* POWER9, ISA3.00 */
> +        .name = "power9",
>          .pvr = CPU_POWERPC_LOGICAL_3_00,
>          .pcr = PCR_COMPAT_3_00,
>          .pcr_level = PCR_COMPAT_3_00,
> 

Right, I have that fixed in my tree so it will be in the next spin.

-- 
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2017-05-12  7:22 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-04-27  7:28 [Qemu-devel] [PATCHv3 0/4] Clean up compatibility mode handling David Gibson
2017-04-27  7:28 ` [Qemu-devel] [PATCHv3 1/4] qapi: add explicit null to string input and output visitors David Gibson
2017-05-02 11:48   ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2017-04-27  7:28 ` [Qemu-devel] [PATCHv3 2/4] pseries: Move CPU compatibility property to machine David Gibson
2017-04-27 17:23   ` Michael Roth
2017-05-01  2:33     ` David Gibson
2017-05-02 11:23       ` Greg Kurz
2017-05-02 14:24   ` Greg Kurz
2017-05-26  1:24     ` David Gibson
2017-05-04 10:06   ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2017-05-04 17:09   ` [Qemu-devel] " Andrea Bolognani
2017-05-04 18:50     ` Greg Kurz
2017-05-12  7:08       ` David Gibson [this message]
2017-05-26  2:10     ` David Gibson
2017-04-27  7:28 ` [Qemu-devel] [PATCHv3 3/4] pseries: Reset CPU compatibility mode David Gibson
2017-04-27 18:08   ` Michael Roth
2017-04-27  7:28 ` [Qemu-devel] [PATCHv3 4/4] ppc: Rework CPU compatibility testing across migration David Gibson
2017-04-27 19:51   ` Michael Roth
2017-05-01  6:48     ` David Gibson
2017-05-26  3:40     ` David Gibson
2017-05-04 10:07   ` Greg Kurz
2017-05-26  4:16     ` David Gibson
2017-05-29 10:51       ` Greg Kurz
2017-04-27  8:04 ` [Qemu-devel] [PATCHv3 0/4] Clean up compatibility mode handling no-reply
2017-04-28  9:29 ` Greg Kurz
2017-05-03 18:03 ` Greg Kurz
2017-05-04 14:32 ` Andrea Bolognani
2017-05-04 19:22   ` [Qemu-devel] [Qemu-ppc] " Greg Kurz
2017-05-12  7:33     ` David Gibson
2017-05-12  8:33       ` Andrea Bolognani

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=20170512070843.GA15313@umbus.fritz.box \
    --to=david@gibson.dropbear.id.au \
    --cc=abologna@redhat.com \
    --cc=agraf@suse.de \
    --cc=aik@ozlabs.ru \
    --cc=armbru@redhat.com \
    --cc=clg@kaod.org \
    --cc=groug@kaod.org \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=nikunj@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.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;
as well as URLs for NNTP newsgroup(s).