[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 25/59] hw/ppc/spapr_rtas: Remove local variable
From: |
Paolo Bonzini |
Subject: |
[PULL 25/59] hw/ppc/spapr_rtas: Remove local variable |
Date: |
Thu, 23 Jan 2020 14:48:28 +0100 |
From: Philippe Mathieu-Daudé <address@hidden>
We only access this variable in the RTAS_SYSPARM_SPLPAR_CHARACTERISTICS
case. Use it in place and remove the local declaration.
Suggested-by: Greg Kurz <address@hidden>
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Message-Id: <address@hidden>
Signed-off-by: Paolo Bonzini <address@hidden>
---
hw/ppc/spapr_rtas.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git a/hw/ppc/spapr_rtas.c b/hw/ppc/spapr_rtas.c
index 6f06e9d..85135e0 100644
--- a/hw/ppc/spapr_rtas.c
+++ b/hw/ppc/spapr_rtas.c
@@ -268,7 +268,6 @@ static void rtas_ibm_get_system_parameter(PowerPCCPU *cpu,
{
PowerPCCPUClass *pcc = POWERPC_CPU_GET_CLASS(cpu);
MachineState *ms = MACHINE(spapr);
- unsigned int max_cpus = ms->smp.max_cpus;
target_ulong parameter = rtas_ld(args, 0);
target_ulong buffer = rtas_ld(args, 1);
target_ulong length = rtas_ld(args, 2);
@@ -280,10 +279,10 @@ static void rtas_ibm_get_system_parameter(PowerPCCPU *cpu,
"DesMem=%" PRIu64 ","
"DesProcs=%d,"
"MaxPlatProcs=%d",
- max_cpus,
+ ms->smp.max_cpus,
ms->ram_size / MiB,
ms->smp.cpus,
- max_cpus);
+ ms->smp.max_cpus);
if (pcc->n_host_threads > 0) {
char *hostthr_val, *old = param_val;
--
1.8.3.1
- [PULL 15/59] Makefile: Remove unhelpful comment, (continued)
- [PULL 15/59] Makefile: Remove unhelpful comment, Paolo Bonzini, 2020/01/23
- [PULL 16/59] hw/core: Restrict reset handlers API to system-mode, Paolo Bonzini, 2020/01/23
- [PULL 17/59] hw/core/Makefile: Group generic objects versus system-mode objects, Paolo Bonzini, 2020/01/23
- [PULL 18/59] target/i386: kvm: initialize feature MSRs very early, Paolo Bonzini, 2020/01/23
- [PULL 20/59] target/i386: kvm: initialize microcode revision from KVM, Paolo Bonzini, 2020/01/23
- [PULL 21/59] virtio-scsi: delete vqs in unrealize to avoid memleaks, Paolo Bonzini, 2020/01/23
- [PULL 19/59] target/i386: add a ucode-rev property, Paolo Bonzini, 2020/01/23
- [PULL 22/59] virtio-scsi: convert to new virtio_delete_queue, Paolo Bonzini, 2020/01/23
- [PULL 23/59] hw/ppc/spapr_rtas: Use local MachineState variable, Paolo Bonzini, 2020/01/23
- [PULL 24/59] hw/ppc/spapr_rtas: Access MachineState via SpaprMachineState argument, Paolo Bonzini, 2020/01/23
- [PULL 25/59] hw/ppc/spapr_rtas: Remove local variable,
Paolo Bonzini <=
- [PULL 26/59] target/arm/kvm: Use CPUState::kvm_state in kvm_arm_pmu_supported(), Paolo Bonzini, 2020/01/23
- [PULL 27/59] qom/object: Display more helpful message when a parent is missing, Paolo Bonzini, 2020/01/23
- [PULL 28/59] accel: Introduce the current_accel() wrapper, Paolo Bonzini, 2020/01/23
- [PULL 30/59] accel/tcg: Sanitize include path, Paolo Bonzini, 2020/01/23
- [PULL 29/59] accel: Replace current_machine->accelerator by current_accel() wrapper, Paolo Bonzini, 2020/01/23
- [PULL 31/59] object: add extra sanity checks, Paolo Bonzini, 2020/01/23
- [PULL 32/59] qdev: remove duplicated qdev_property_add_static() doc, Paolo Bonzini, 2020/01/23
- [PULL 33/59] qdev: remove extraneous error, Paolo Bonzini, 2020/01/23
- [PULL 34/59] qdev: move helper function to monitor/misc, Paolo Bonzini, 2020/01/23
- [PULL 35/59] object: avoid extra class property key duplication, Paolo Bonzini, 2020/01/23