Skip to content

MCE & IO exit fixes, prepare for VCPU loop reuse

Jan Kiszka kvm qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest18 patches 11 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/18Revert "kvm: Drop return value of kvm_cpu_exec"kvm-all.c kvm-stub.c kvm.h+7 -50 replies
2/18kvm: Drop redundant kvm_enabled from kvm_cpu_thread_fncpus.c+2 -20 replies
3/18kvm: Provide sigbus services arch-independentlycpus.c kvm-all.c kvm-stub.c +4 more+46 -102 replies
4/18Refactor signal setup functions in cpus.ccpus.c+82 -800 replies
5/18kvm: Set up signal mask also for !CONFIG_IOTHREADcpus.c+14 -30 replies
6/18kvm: Refactor qemu_kvm_eat_signalscpus.c+7 -161 reply
7/18kvm: Add MCE signal support for !CONFIG_IOTHREADcpus.c+124 -765 replies
8/18kvm: Handle kvm_init_vcpu errorscpus.c+12 -20 replies
9/18Refactor kvm&tcg function names in cpus.ccpus.c+8 -80 replies
10/18Fix a few coding style violations in cpus.ccpus.c+58 -380 replies
11/18Introduce VCPU self-signaling servicecpus.c qemu-common.h+19 -12 replies
12/18kvm: Move irqchip event processing out of inner loopkvm-all.c+6 -50 replies
13/18kvm: Unconditionally reenter kernel after IO exitskvm-all.c+11 -90 replies
14/18kvm: Remove static return code of kvm_handle_iokvm-all.c+8 -90 replies
15/18kvm: Leave kvm_cpu_exec directly after KVM_EXIT_SHUTDOWNkvm-all.c+0 -10 replies
16/18kvm: Separate TCG from KVM cpu executioncpu-exec.c cpus.c kvm-all.c +1 more+23 -310 replies
17/18kvm: x86: Prepare VCPU loop for in-kernel irqchiptarget-i386/kvm.c+41 -370 replies
18/18kvm: Drop return values from kvm_arch_pre/post_runkvm.h target-i386/kvm.c target-ppc/kvm.c +1 more+8 -170 replies

Reviews trailers per patch

1 of 18 patches has a Reviewed-by or Acked-by.

PatchPaolo Bonzini
1/18
2/18
3/18
4/18
5/18
6/18R-b
7/18
8/18
9/18
10/18
11/18
12/18
13/18
14/18
15/18
16/18
17/18
18/18

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 00/18] [uq/master] MCE & IO exit fixes, prepare for VCPU loop reuse

This series has three major topics:
- add required kernel reentry after IO exits
- provide MCE forwarding under !CONFIG_IOTHREAD
- prepare kvm_cpu_exec for qemu-kvm reuse

Along these lines, several cleanups and simplifcations are applied to cpus.c and the KVM VCPU execution bits. The first patch should of course be dropped if uq/master is applied without "kvm: Drop return value of kvm_cpu_exec".

Note that I did not yet to test the MCE support. Is there an easy way to trigger valid MCE events at kernel level? Or do I need to fake SIGBUS at qemu level?

Jan Kiszka (18):
Revert "kvm: Drop return value of kvm_cpu_exec"
kvm: Drop redundant kvm_enabled from kvm_cpu_thread_fn
kvm: Provide sigbus services arch-independently Refactor signal setup functions in cpus.c
kvm: Set up signal mask also for !CONFIG_IOTHREAD
kvm: Refactor qemu_kvm_eat_signals
kvm: Add MCE signal support for !CONFIG_IOTHREAD
kvm: Handle kvm_init_vcpu errors
Refactor kvm&tcg function names in cpus.c
Fix a few coding style violations in cpus.c Introduce VCPU self-signaling service
kvm: Move irqchip event processing out of inner loop
kvm: Unconditionally reenter kernel after IO exits
kvm: Remove static return code of kvm_handle_io
kvm: Leave kvm_cpu_exec directly after KVM_EXIT_SHUTDOWN
kvm: Separate TCG from KVM cpu execution
kvm: x86: Prepare VCPU loop for in-kernel irqchip
kvm: Drop return values from kvm_arch_pre/post_run

 cpu-exec.c         |   19 +--
 cpus.c             |  521 +++++++++++++++++++++++++++++++---------------------
 kvm-all.c          |   76 +++++----
 kvm-stub.c         |    9 +-
 kvm.h              |   14 +-
 qemu-common.h      |    1 +
 target-i386/kvm.c  |   90 +++++-----
 target-ppc/kvm.c   |   16 ++-
 target-s390x/kvm.c |   16 ++-
 9 files changed, 444 insertions(+), 318 deletions(-)