From: David Gibson <david@gibson.dropbear.id.au>
To: Bharata B Rao <bharata@linux.vnet.ibm.com>
Cc: qemu-devel@nongnu.org, qemu-ppc@nongnu.org, imammedo@redhat.com,
groug@kaod.org, nikunj@linux.vnet.ibm.com, pbonzini@redhat.com
Subject: Re: [Qemu-devel] [RFC PATCH v0 3/5] spapr: Implement CPUClass.get_arch_id() for PowerPC CPUs
Date: Tue, 5 Jul 2016 14:58:08 +1000 [thread overview]
Message-ID: <20160705045808.GG2251@voom.fritz.box> (raw)
In-Reply-To: <1467693772-7391-4-git-send-email-bharata@linux.vnet.ibm.com>
[-- Attachment #1: Type: text/plain, Size: 1466 bytes --]
On Tue, Jul 05, 2016 at 10:12:50AM +0530, Bharata B Rao wrote:
> Signed-off-by: Bharata B Rao <bharata@linux.vnet.ibm.com>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Longer term we should probably change the field name to arch_id. In
theory we could have something like this on a platform that didn't do
device trees.
> ---
> target-ppc/translate_init.c | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c
> index 8f257fb..b810624 100644
> --- a/target-ppc/translate_init.c
> +++ b/target-ppc/translate_init.c
> @@ -10357,6 +10357,13 @@ static gchar *ppc_gdb_arch_name(CPUState *cs)
> #endif
> }
>
> +static int64_t ppc_cpu_get_arch_id(CPUState *cs)
> +{
> + PowerPCCPU *cpu = POWERPC_CPU(cs);
> +
> + return cpu->cpu_dt_id;
> +}
> +
> static void ppc_cpu_class_init(ObjectClass *oc, void *data)
> {
> PowerPCCPUClass *pcc = POWERPC_CPU_CLASS(oc);
> @@ -10409,6 +10416,7 @@ static void ppc_cpu_class_init(ObjectClass *oc, void *data)
> #ifndef CONFIG_USER_ONLY
> cc->virtio_is_big_endian = ppc_cpu_is_big_endian;
> #endif
> + cc->get_arch_id = ppc_cpu_get_arch_id;
>
> dc->fw_name = "PowerPC,UNKNOWN";
> }
--
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 --]
next prev parent reply other threads:[~2016-07-05 4:57 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-05 4:42 [Qemu-devel] [RFC PATCH v0 0/5] sPAPR: Fix migration when CPUs are removed in random order Bharata B Rao
2016-07-05 4:42 ` [Qemu-devel] [RFC PATCH v0 1/5] cpu: Factor out cpu vmstate_[un]register into separate routines Bharata B Rao
2016-07-05 4:56 ` David Gibson
2016-07-05 5:16 ` Bharata B Rao
2016-07-05 5:49 ` Igor Mammedov
2016-07-05 6:35 ` Bharata B Rao
2016-07-05 7:22 ` Igor Mammedov
2016-07-05 7:38 ` Bharata B Rao
2016-07-05 8:01 ` Igor Mammedov
2016-07-05 7:29 ` Greg Kurz
2016-07-05 4:42 ` [Qemu-devel] [RFC PATCH v0 2/5] cpu: Optionally use arch_id instead of cpu_index in cpu vmstate_register() Bharata B Rao
2016-07-05 4:56 ` David Gibson
2016-07-05 5:22 ` Bharata B Rao
2016-07-05 6:59 ` Igor Mammedov
2016-07-05 7:15 ` Igor Mammedov
2016-07-05 12:43 ` Bharata B Rao
2016-07-06 5:25 ` Igor Mammedov
2016-07-06 8:25 ` Bharata B Rao
2016-07-07 2:08 ` David Gibson
2016-07-07 17:19 ` Greg Kurz
2016-07-05 7:20 ` Greg Kurz
2016-07-05 4:42 ` [Qemu-devel] [RFC PATCH v0 3/5] spapr: Implement CPUClass.get_arch_id() for PowerPC CPUs Bharata B Rao
2016-07-05 4:58 ` David Gibson [this message]
2016-07-05 4:42 ` [Qemu-devel] [RFC PATCH v0 4/5] xics: Use arch_id instead of cpu_index in XICS code Bharata B Rao
2016-07-05 4:59 ` David Gibson
2016-07-05 7:03 ` Igor Mammedov
2016-07-05 4:42 ` [Qemu-devel] [RFC PATCH v0 5/5] spapr: Prefer arch_id over cpu_index Bharata B Rao
2016-07-05 7:10 ` [Qemu-devel] [RFC PATCH v0 0/5] sPAPR: Fix migration when CPUs are removed in random order Greg Kurz
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=20160705045808.GG2251@voom.fritz.box \
--to=david@gibson.dropbear.id.au \
--cc=bharata@linux.vnet.ibm.com \
--cc=groug@kaod.org \
--cc=imammedo@redhat.com \
--cc=nikunj@linux.vnet.ibm.com \
--cc=pbonzini@redhat.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).