[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 07/30] ppc/bamboo: Report an error when run with KVM
From: |
Cédric Le Goater |
Subject: |
[PULL 07/30] ppc/bamboo: Report an error when run with KVM |
Date: |
Mon, 26 Jun 2023 07:56:24 +0200 |
The 'bamboo' machine was used as a KVM platform in the early days (~2008).
It clearly doesn't support it anymore.
Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
hw/ppc/ppc440_bamboo.c | 17 ++++++-----------
1 file changed, 6 insertions(+), 11 deletions(-)
diff --git a/hw/ppc/ppc440_bamboo.c b/hw/ppc/ppc440_bamboo.c
index f969fa3c29ca..f061b8cf3ba3 100644
--- a/hw/ppc/ppc440_bamboo.c
+++ b/hw/ppc/ppc440_bamboo.c
@@ -19,7 +19,6 @@
#include "hw/pci/pci.h"
#include "hw/boards.h"
#include "sysemu/kvm.h"
-#include "kvm_ppc.h"
#include "sysemu/device_tree.h"
#include "hw/loader.h"
#include "elf.h"
@@ -97,16 +96,6 @@ static int bamboo_load_device_tree(MachineState *machine,
fprintf(stderr, "couldn't set /chosen/bootargs\n");
}
- /*
- * Copy data from the host device tree into the guest. Since the guest can
- * directly access the timebase without host involvement, we must expose
- * the correct frequencies.
- */
- if (kvm_enabled()) {
- tb_freq = kvmppc_get_tbfreq();
- clock_freq = kvmppc_get_clockfreq();
- }
-
qemu_fdt_setprop_cell(fdt, "/cpus/cpu@0", "clock-frequency",
clock_freq);
qemu_fdt_setprop_cell(fdt, "/cpus/cpu@0", "timebase-frequency",
@@ -175,6 +164,12 @@ static void bamboo_init(MachineState *machine)
int success;
int i;
+ if (kvm_enabled()) {
+ error_report("machine %s does not support the KVM accelerator",
+ MACHINE_GET_CLASS(machine)->name);
+ exit(EXIT_FAILURE);
+ }
+
cpu = POWERPC_CPU(cpu_create(machine->cpu_type));
env = &cpu->env;
--
2.41.0
- [PULL 00/30] ppc queue, Cédric Le Goater, 2023/06/26
- [PULL 01/30] target/ppc: gdbstub init spr gdb_id for all CPUs, Cédric Le Goater, 2023/06/26
- [PULL 03/30] MAINTAINERS: Add reviewers for PowerNV baremetal emulation, Cédric Le Goater, 2023/06/26
- [PULL 02/30] ppc/pnv/pci: Clean up error messages, Cédric Le Goater, 2023/06/26
- [PULL 05/30] MAINTAINERS: Add reviewer for XIVE, Cédric Le Goater, 2023/06/26
- [PULL 04/30] MAINTAINERS: Add reviewer for PowerPC TCG CPUs, Cédric Le Goater, 2023/06/26
- [PULL 07/30] ppc/bamboo: Report an error when run with KVM,
Cédric Le Goater <=
- [PULL 06/30] ppc/prep: Report an error when run with KVM, Cédric Le Goater, 2023/06/26
- [PULL 08/30] ppc/pnv: Rephrase error when run with KVM, Cédric Le Goater, 2023/06/26
- [PULL 11/30] ppc/spapr: Add a nested state struct, Cédric Le Goater, 2023/06/26
- [PULL 09/30] target/ppc: Fix timer register accessors when !KVM, Cédric Le Goater, 2023/06/26
- [PULL 10/30] ppc/spapr: H_ENTER_NESTED should restore host XER ca field, Cédric Le Goater, 2023/06/26
- [PULL 13/30] ppc/spapr: Move spapr nested HV to a new file, Cédric Le Goater, 2023/06/26
- [PULL 17/30] target/ppc: Implement HEIR SPR, Cédric Le Goater, 2023/06/26