diff options
author | Sam Bobroff <sam.bobroff@au1.ibm.com> | 2017-08-09 15:38:56 +1000 |
---|---|---|
committer | David Gibson <david@gibson.dropbear.id.au> | 2017-09-08 09:30:55 +1000 |
commit | 2e886fb39168942ab03b91062e715946e4af8436 (patch) | |
tree | 570b2f6294fc9fe07aee21ed8f2dfc87240fcb52 /hw/ppc/spapr_rtas.c | |
parent | 81210c2009296261879af5d58a3a499815031765 (diff) |
ppc: spapr: Make VCPU ID handling private to SPAPR
The concept of a VCPU ID that differs from the CPU's index
(cpu->cpu_index) exists only within SPAPR machines so, move the
functions ppc_get_vcpu_id() and ppc_get_cpu_by_vcpu_id() into spapr.c
and rename them appropriately.
Signed-off-by: Sam Bobroff <sam.bobroff@au1.ibm.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Diffstat (limited to 'hw/ppc/spapr_rtas.c')
-rw-r--r-- | hw/ppc/spapr_rtas.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/hw/ppc/spapr_rtas.c b/hw/ppc/spapr_rtas.c index 626c06b375..cdf0b607a0 100644 --- a/hw/ppc/spapr_rtas.c +++ b/hw/ppc/spapr_rtas.c @@ -104,7 +104,7 @@ static void rtas_query_cpu_stopped_state(PowerPCCPU *cpu_, } id = rtas_ld(args, 0); - cpu = ppc_get_cpu_by_vcpu_id(id); + cpu = spapr_find_cpu(id); if (cpu != NULL) { if (CPU(cpu)->halted) { rtas_st(rets, 1, 0); @@ -158,7 +158,7 @@ static void rtas_start_cpu(PowerPCCPU *cpu_, sPAPRMachineState *spapr, start = rtas_ld(args, 1); r3 = rtas_ld(args, 2); - cpu = ppc_get_cpu_by_vcpu_id(id); + cpu = spapr_find_cpu(id); if (cpu != NULL) { CPUState *cs = CPU(cpu); CPUPPCState *env = &cpu->env; |