Skip to content

accel: Only include qdev-realized vCPUs in global &cpus_queue

Igor Mammedov kvm qemu-devel 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest10 patches 15 repliesIn review
  2. v16 patches 3 repliesSuperseded

Changelog from the cover letter

* drop wire/unwire hooks patches
* drop unrealize related patches
* include fixed up patches from
[PATCH 0/6] tcg: fix qemu crash when add assert_cpu_is_self() is enabled
and cleanups related to cpu->created check
https://patchew.org/QEMU/[email protected]/
as it's related to the topic (well, modulo bsd cleanup)
* CI mostly green modulo rust failure on Ubuntu

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/10bsd-user: drop not longer used target_reset_cpu()bsd-user/aarch64/target_arch_cpu.h bsd-user/arm/target_arch_cpu.h bsd-user/i386/target_arch_cpu.h +2 more+0 -232 replies
2/10loongarch: reset vcpu after it's createdtarget/loongarch/cpu.c+1 -12 replies
3/10m68k: reset vcpu after it's createdtarget/m68k/cpu.c+1 -12 replies
4/10tcg:tlb: use tcg_debug_assert() in assert_cpu_is_self()accel/tcg/cputlb.c+2 -51 reply
5/10Revert "tcg/cputlb: remove other-cpu capability from TLB flushing"accel/tcg/cputlb.c+33 -93 replies
6/10tcg: drop cpu->created checkaccel/tcg/cputlb.c+2 -20 replies
7/10accel/tcg: Simplify use of &first_cpu in rr_cpu_thread_fn()accel/tcg/tcg-accel-ops-rr.c+8 -51 reply
8/10cpus: expose only realized vCPUs to global &cpus_queuecpu-common.c cpu-target.c hw/core/cpu-common.c +1 more+23 -103 replies
9/10accel/kvm: Assert vCPU is created when calling kvm_dirty_ring_reap*()accel/kvm/kvm-all.c+3 -50 replies
10/10accel/kvm: Remove unreachable assertion in kvm_dirty_ring_reap*()accel/kvm/kvm-all.c+0 -70 replies

Reviews trailers per patch

7 of 10 patches have a Reviewed-by or Acked-by.

PatchRichard HendersonBibo MaoAlex BennéePhilippe Mathieu-DaudéWarner Losh
1/10R-b R-b
2/10R-b R-b
3/10R-b R-b
4/10R-b
5/10
6/10
7/10A-b
8/10
9/10R-b
10/10R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 5 reviewers.

Read the v2 thread

Cover letter [PATCH v2 00/10] accel: Only include qdev-realized vCPUs in global &cpus_queue

Changelog:
* drop wire/unwire hooks patches
* drop unrealize related patches
* include fixed up patches from
[PATCH 0/6] tcg: fix qemu crash when add assert_cpu_is_self() is enabled
and cleanups related to cpu->created check
https://patchew.org/QEMU/[email protected]/
as it's related to the topic (well, modulo bsd cleanup)
* CI mostly green modulo rust failure on Ubuntu

     https://gitlab.com/imammedo/qemu/-/pipelines/1660855467

The goal of this series is to expose vCPUs in a stable state to the accelerators, in particular the QDev 'REALIZED' step.

To do this we split out cpu_index assignment into a separate step, and move call cpu_list_add() to the end of CPU realize stage.

I expect these changes to allow CPUState::cpu_index clarifications and simplifications, but this will be addressed (and commented) in a separate series.

As result, the series also
* fix regression intoroduced by
30933c4fb4f3d ("tcg/cputlb: remove other-cpu capability from TLB flushing")
for deatials see 'tcg:tlb: use tcg_debug_assert() in assert_cpu_is_self()'
* drops no longer needed workaround 'cpu->check' due to vCPU being exposed too early in cpus_queue.

CC Paolo Bonzini <[email protected]>
CC Richard Henderson <[email protected]>
CC "Philippe Mathieu-Daudé" <[email protected]>
CC Alex Bennée <[email protected]>

Igor Mammedov (7):
bsd-user: drop not longer used target_reset_cpu()
loongarch: reset vcpu after it's created
m68k: reset vcpu after it's created
tcg:tlb: use tcg_debug_assert() in assert_cpu_is_self() Revert "tcg/cputlb: remove other-cpu capability from TLB flushing"
tcg: drop cpu->created check
cpus: expose only realized vCPUs to global &cpus_queue

Philippe Mathieu-Daudé (3):
accel/tcg: Simplify use of &first_cpu in rr_cpu_thread_fn() accel/kvm: Assert vCPU is created when calling kvm_dirty_ring_reap*() accel/kvm: Remove unreachable assertion in kvm_dirty_ring_reap*()

 bsd-user/aarch64/target_arch_cpu.h |  5 ---
 bsd-user/arm/target_arch_cpu.h     |  4 ---
 bsd-user/i386/target_arch_cpu.h    |  5 ---
 bsd-user/riscv/target_arch_cpu.h   |  4 ---
 bsd-user/x86_64/target_arch_cpu.h  |  5 ---
 include/hw/core/cpu.h              |  6 ++++
 accel/kvm/kvm-all.c                |  9 ------
 accel/tcg/cputlb.c                 | 49 +++++++++++++++++++++---------
 accel/tcg/tcg-accel-ops-rr.c       | 13 +++++---
 cpu-common.c                       | 23 ++++++++------
 cpu-target.c                       |  2 +-
 hw/core/cpu-common.c               |  2 ++
 target/loongarch/cpu.c             |  2 +-
 target/m68k/cpu.c                  |  2 +-
 14 files changed, 68 insertions(+), 63 deletions(-)
Signature · 1 line
2.43.0