Il 21/07/2014 13:37, Nadav Amit ha scritto:Yes, but it also calls it exception "type" (see table 6-1 "Protected-Mode Exceptions and Interrupts" on the SDM).
+int kvm_exception_type(unsigned int nr)
The manual calls this the exception class.
Unless I am mistaken, kvm_vcpu_check_breakpoint checks only for instruction breakpoint. Since instruction breakpoint should not cause RF to be set, this function should not be changed.+ case VE_VECTOR:
+ return EXCPT_FAULT;
+ case DB_VECTOR:
+ return EXCPT_FAULT_OR_TRAP;
It is only a fault for instruction fetch breakpoints. You can modify
kvm_vcpu_check_breakpoint to set RF, add a comment here that fault
handling is done elsewhere, and return EXCPT_TRAP.