Alexander Graf wrote:
The current VINTR intercept setters don't look clean to me. To make
the code easier to read and enable the possibilty to trap on a VINTR
set, this uses a helper function to set the VINTR intercept.

+static void svm_set_vintr(struct vcpu_svm *svm, bool on)
+{
+       if (on) {
+               svm->vmcb->control.intercept |= 1ULL << INTERCEPT_VINTR;
+       } else {
+               svm->vmcb->control.intercept &= ~(1ULL << INTERCEPT_VINTR);
+       }
+}
+


svm_set_vintr() + svm_clear_vintr() would be even clearer IMO.

--
error compiling committee.c: too many arguments to function

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to