qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Andreas Färber" <afaerber@suse.de>
To: Alexey Kardashevskiy <aik@ozlabs.ru>,
	Alexander Graf <agraf@suse.de>,
	qemu-devel@nongnu.org
Cc: qemu-ppc@nongnu.org
Subject: Re: [Qemu-devel] [RFC PATCH] target-ppc: Register CPU class per family only when needed
Date: Mon, 16 Mar 2015 11:40:29 +0100	[thread overview]
Message-ID: <5506B31D.1060504@suse.de> (raw)
In-Reply-To: <55066306.9060906@ozlabs.ru>

Am 16.03.2015 um 05:58 schrieb Alexey Kardashevskiy:
> On 03/06/2015 12:17 AM, Alexander Graf wrote:
>> On 05.03.15 02:56, Alexey Kardashevskiy wrote:
>>> At the moment when running in KVM mode, QEMU registers "host" class to
>>> match the current CPU PVR value. It also registers another CPU class
>>> with a CPU family name os if we run QEMU on POWER7 machine, "host" and
>>> "POWER7" classes are created, this way we can always use "-cpu POWER7"
>>> on the actual POWER7 machine.
>>>
>>> The existing code uses DeviceClass::desc field of the CPU class as
>>> a source for the class name; it was pointed out that it is wrong to use
>>> user-visible string as a type name.
>>>
>>> This adds a common CPU class name into PowerPCCPUClass struct.
>>> This makes registration of a CPU named after the family conditional -
>>> PowerPCCPUClass::common_cpu_name has to be non-zero. Only POWER7/POWER8
>>> families have this field initialized by now.
>>>
>>> Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
>>
>> LGTM. Andreas, do you agree?
> 
> 
> Ping?

No, I don't agree. Inventing a new class field just to distinguish
POWER7/POWER8 here seems like a weird idea, and the code placement is
not fixed either.

I gathered that you want -cpu POWER7 and -cpu POWER8 to work on POWER8
hardware and -cpu POWER7 on POWER7, for migration purposes, correct?

What exact PVRs have you tested on and why does it not work without
those types despite the PVR masking? To investigate I need a test case.

Is this just a question of the generic family type being abstract and
needing an updated PVR value? Which other fields are actually used?

Regards,
Andreas

-- 
SUSE Linux GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Felix Imendörffer, Jane Smithard, Jennifer Guild, Dilip Upmanyu,
Graham Norton; HRB 21284 (AG Nürnberg)

  reply	other threads:[~2015-03-16 10:40 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-05  1:56 [Qemu-devel] [RFC PATCH] target-ppc: Register CPU class per family only when needed Alexey Kardashevskiy
2015-03-05 13:17 ` Alexander Graf
2015-03-16  4:58   ` Alexey Kardashevskiy
2015-03-16 10:40     ` Andreas Färber [this message]
2015-03-16 22:47       ` Alexey Kardashevskiy
2015-07-08  6:37         ` Alexey Kardashevskiy
2015-07-08  6:41           ` Alexey Kardashevskiy

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=5506B31D.1060504@suse.de \
    --to=afaerber@suse.de \
    --cc=agraf@suse.de \
    --cc=aik@ozlabs.ru \
    --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).