Re: [PATCH 3/4] kvm, emulator: Rename VendorSpecific flag

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Jun 25, 2013 at 02:10:20PM +0300, Gleb Natapov wrote:
> > -	if (!(ctxt->d & VendorSpecific) && ctxt->only_vendor_specific_insn)
> > +	if (!(ctxt->d & EmulateOnUD) && ctxt->only_vendor_specific_insn)
> Lets rename only_vendor_specific_insn to something like ->ud too.

So this thing is set only when either svm or vmx encounter an #UD and go
and emulate the instruction.

I guess this is for the case where we actually do want to inject the #UD
into the guest and not emulate the instruction.

Btw, it is only checked in x86_decode_insn so we could just as well hand
down the emulation_type from the caller x86_emulate_instruction and kill
->only_vendor_specific_insn completely like so:

	if (!(ctxt->d & EmulateOnUD) && (emul_type & EMULTYPE_TRAP_UD))

-- 
Regards/Gruss,
    Boris.

Sent from a fat crate under my desk. Formatting is fine.
--
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux