[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Stable-8.2.8 42/49] target/riscv/kvm: clarify how 'riscv-aia' default w
From: |
Michael Tokarev |
Subject: |
[Stable-8.2.8 42/49] target/riscv/kvm: clarify how 'riscv-aia' default works |
Date: |
Sat, 9 Nov 2024 13:14:33 +0300 |
From: Daniel Henrique Barboza <dbarboza@ventanamicro.com>
We do not have control in the default 'riscv-aia' default value. We can
try to set it to a specific value, in this case 'auto', but there's no
guarantee that the host will accept it.
Couple with this we're always doing a 'qemu_log' to inform whether we're
ended up using the host default or if we managed to set the AIA mode to
the QEMU default we wanted to set.
Change the 'riscv-aia' description to better reflect how the option
works, and remove the two informative 'qemu_log' that are now unneeded:
if no message shows, riscv-aia was set to the default or uset-set value.
Signed-off-by: Daniel Henrique Barboza <dbarboza@ventanamicro.com>
Acked-by: Alistair Francis <alistair.francis@wdc.com>
Message-ID: <20241028182037.290171-3-dbarboza@ventanamicro.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
(cherry picked from commit fd16cfb2995e9196b579d8885145c4247dfa6058)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
diff --git a/target/riscv/kvm/kvm-cpu.c b/target/riscv/kvm/kvm-cpu.c
index daff517896..852e0cede4 100644
--- a/target/riscv/kvm/kvm-cpu.c
+++ b/target/riscv/kvm/kvm-cpu.c
@@ -1335,9 +1335,9 @@ void kvm_arch_accel_class_init(ObjectClass *oc)
object_class_property_add_str(oc, "riscv-aia", riscv_get_kvm_aia,
riscv_set_kvm_aia);
object_class_property_set_description(oc, "riscv-aia",
- "Set KVM AIA mode. Valid values are "
- "emul, hwaccel, and auto. Default "
- "is auto.");
+ "Set KVM AIA mode. Valid values are 'emul', 'hwaccel' and 'auto'. "
+ "Changing KVM AIA modes relies on host support. Defaults to 'auto' "
+ "if the host supports it");
object_property_set_default_str(object_class_property_find(oc,
"riscv-aia"),
"auto");
}
@@ -1370,10 +1370,7 @@ void kvm_riscv_aia_create(MachineState *machine,
uint64_t group_shift,
exit(1);
}
- if (default_aia_mode == aia_mode) {
- qemu_log("KVM AIA: using default host mode '%s'\n",
- kvm_aia_mode_str(default_aia_mode));
- } else {
+ if (default_aia_mode != aia_mode) {
ret = kvm_device_access(aia_fd, KVM_DEV_RISCV_AIA_GRP_CONFIG,
KVM_DEV_RISCV_AIA_CONFIG_MODE,
&aia_mode, true, NULL);
@@ -1385,9 +1382,6 @@ void kvm_riscv_aia_create(MachineState *machine, uint64_t
group_shift,
/* failed to change AIA mode, use default */
aia_mode = default_aia_mode;
- } else {
- qemu_log("KVM AIA: setting current mode to %s\n",
- kvm_aia_mode_str(aia_mode));
}
}
--
2.39.5
- [Stable-8.2.8 23/49] target/i386: Walk NPT in guest real mode, (continued)
- [Stable-8.2.8 23/49] target/i386: Walk NPT in guest real mode, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 30/49] Fix calculation of minimum in colo_compare_tcp, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 34/49] target/arm: Fix arithmetic underflow in SETM instruction, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 31/49] net: fix build when libbpf is disabled, but libxdp is enabled, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 36/49] target/riscv: Correct SXL return value for RV32 in RV64 QEMU, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 40/49] hw/intc/riscv_aplic: Check and update pending when write sourcecfg, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 39/49] hw/intc/riscv_aplic: Fix in_clrip[x] read emulation, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 37/49] hw/intc: Don't clear pending bits on IRQ lowering, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 47/49] migration: Ensure vmstate_save() sets errp, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 29/49] dockerfiles: fix default targets for debian-loongarch-cross, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 42/49] target/riscv/kvm: clarify how 'riscv-aia' default works,
Michael Tokarev <=
- [Stable-8.2.8 46/49] target/arm: Fix SVE SDOT/UDOT/USDOT (4-way, indexed), Michael Tokarev, 2024/11/09
- [Stable-8.2.8 48/49] hw/nvme: fix handling of over-committed queues, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 49/49] 9pfs: fix crash on 'Treaddir' request, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 41/49] target/riscv/kvm: set 'aia_mode' to default in error path, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 44/49] target/ppc: Set ctx->opcode for decode_insn32(), Michael Tokarev, 2024/11/09
- [Stable-8.2.8 43/49] target/riscv: Fix vcompress with rvv_ta_all_1s, Michael Tokarev, 2024/11/09
- [Stable-8.2.8 45/49] target/ppc: Fix mtDPDES targeting SMT siblings, Michael Tokarev, 2024/11/09