From db48224bbd2364f557ad0b29adc52d7195f14411 Mon Sep 17 00:00:00 2001 From: qihao_yewu Date: Fri, 1 Aug 2025 02:17:53 -0400 Subject: [PATCH] target/ppc: Fix mtDPDES targeting SMT siblings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit cheery-pick from a0f6b02792a3332c6d108f6eef002b97e30e4ab5 A typo in the loop over SMT threads to set irq level for doorbells when storing to DPDES meant everything was aimed at the CPU executing the instruction. Cc: qemu-stable@nongnu.org Fixes: d24e80b2ae ("target/ppc: Add msgsnd/p and DPDES SMT support") Reviewed-by: Philippe Mathieu-Daudé Reviewed-by: Richard Henderson Signed-off-by: Nicholas Piggin (cherry picked from commit 0324d236d2918c18a9ad4a1081b1083965a1433b) Signed-off-by: Michael Tokarev Signed-off-by: qihao_yewu --- target/ppc/misc_helper.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/ppc/misc_helper.c b/target/ppc/misc_helper.c index a05bdf78c9..a8d0501996 100644 --- a/target/ppc/misc_helper.c +++ b/target/ppc/misc_helper.c @@ -283,7 +283,7 @@ void helper_store_dpdes(CPUPPCState *env, target_ulong val) PowerPCCPU *ccpu = POWERPC_CPU(ccs); uint32_t thread_id = ppc_cpu_tir(ccpu); - ppc_set_irq(cpu, PPC_INTERRUPT_DOORBELL, val & (0x1 << thread_id)); + ppc_set_irq(ccpu, PPC_INTERRUPT_DOORBELL, val & (0x1 << thread_id)); } qemu_mutex_unlock_iothread(); } -- Gitee