kvmarm.lists.cs.columbia.edu archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 0/2] target/arm: kvm: Support for KVM DABT with no valid ISS
@ 2020-03-23 11:32 Beata Michalska
  2020-03-23 11:32 ` [PATCH v4 1/2] target/arm: kvm: Handle " Beata Michalska
  2020-03-23 11:32 ` [PATCH v4 2/2] target/arm: kvm: Handle potential issue with dabt injection Beata Michalska
  0 siblings, 2 replies; 18+ messages in thread
From: Beata Michalska @ 2020-03-23 11:32 UTC (permalink / raw)
  To: qemu-devel; +Cc: qemu-arm, pbonzini, kvmarm

Some of the ARMv7 & ARMv8 load/store instructions might trigger a data abort
exception with no valid ISS info to be decoded. The lack of decode info
makes it at least tricky to emulate the instruction which is one of the
(many) reasons why KVM will not even try to do so.

So far, if a guest made an attempt to access memory outside the memory slot,
KVM reported vague ENOSYS. As a result QEMU exited with no useful information
being provided or even a clue on what has just happened.

ARM KVM introduced support for notifying of an attempt to execute
an instruction that resulted in dabt with no valid ISS decoding info.
This still leaves QEMU to handle the case, but at least now it gives more
control and a start point for more meaningful handling of such cases.

This patchset relies on KVM to insert the external data abort into the guest.

v4:
 - Removing one of the patches as it is being picked-up separately
     target/arm: kvm: Inject events at the last stage of sync
 - Moving handling KVM issue to a separate patch
 - Minor changes wrt the review comments

v3:
 - Fix setting KVM cap per vm not per vcpu
 - Simplifying the handler to bare minimum with no default logging to address
   the potential risk of overflooding the host (adding support for rate
   limiting the logs turned out to be bit too invasive to justify the little
   add-on value from logs in this particular case)
 - Adding handling KVM bug (for small range of affected kernels):
   little bit of trade-off between what's reasonable and what's effective:
   aborting qemu when running on buggy host kernel

v2:
- Improving/re-phrasing messaging
- Dropping messing around with forced sync (@see [PATCH v2 1/2])
  and PC alignment

Beata Michalska (2):
  target/arm: kvm: Handle DABT with no valid ISS
  target/arm: kvm: Handle potential issue with dabt injection

 target/arm/cpu.h     |  3 ++
 target/arm/kvm.c     | 82 ++++++++++++++++++++++++++++++++++++++++++++++++++++
 target/arm/kvm32.c   | 25 ++++++++++++++++
 target/arm/kvm64.c   | 34 ++++++++++++++++++++++
 target/arm/kvm_arm.h | 21 ++++++++++++++
 5 files changed, 165 insertions(+)

-- 
2.7.4

_______________________________________________
kvmarm mailing list
kvmarm@lists.cs.columbia.edu
https://lists.cs.columbia.edu/mailman/listinfo/kvmarm

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2020-04-27  6:18 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-03-23 11:32 [PATCH v4 0/2] target/arm: kvm: Support for KVM DABT with no valid ISS Beata Michalska
2020-03-23 11:32 ` [PATCH v4 1/2] target/arm: kvm: Handle " Beata Michalska
2020-03-23 12:44   ` Andrew Jones
2020-03-25 15:15     ` Beata Michalska
2020-04-17 10:39   ` Peter Maydell
2020-04-17 13:10     ` Andrew Jones
2020-04-18 22:56       ` Beata Michalska
2020-04-24 12:16       ` Dr. David Alan Gilbert
2020-04-24 12:51         ` Peter Maydell
2020-04-25  9:24         ` Paolo Bonzini
2020-04-27  6:18           ` Andrew Jones
2020-03-23 11:32 ` [PATCH v4 2/2] target/arm: kvm: Handle potential issue with dabt injection Beata Michalska
2020-03-23 18:44   ` Richard Henderson
2020-03-25 15:16     ` Beata Michalska
2020-04-03  8:44   ` Andrew Jones
2020-04-07 11:24     ` Peter Maydell
2020-04-07 11:32       ` Beata Michalska
2020-04-07 11:31     ` Beata Michalska

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).