In preparation for some other work in this area, here is a patch set that cleans up some of the code around the cpu_dt_id field of struct PowerPCCPU.
It includes a bugfix for h_signal_sys_reset() because the code there uses the cpu_dt_id field and it would need to be changed by this set anyway. (Alexander Graf: I've CC'd you because you're the maintainer of the e500 code.) Thanks to David Gibson for assistance with the design. Sam Bobroff (4): spapr: Fix bug in h_signal_sys_reset() e500: Use cpu_index instead of vcpu_dt_id ppc: spapr: Rename cpu_dt_id to vcpu_id ppc: spapr: Make VCPU ID handling private to SPAPR hw/ppc/e500.c | 8 ++------ hw/ppc/ppc.c | 21 --------------------- hw/ppc/spapr.c | 36 ++++++++++++++++++++++++++++-------- hw/ppc/spapr_hcall.c | 11 +++++------ hw/ppc/spapr_rtas.c | 4 ++-- include/hw/ppc/spapr.h | 3 +++ target/ppc/cpu.h | 20 +------------------- target/ppc/kvm.c | 2 +- target/ppc/translate_init.c | 8 ++++---- 9 files changed, 46 insertions(+), 67 deletions(-) -- 2.12.1.382.gc0f9c7058