I am using NMI's in my tiny VMM for internal purposes (for sending commands between CPUs via IPI mechanism).
AMD System Programming Manual says about NMI handling:
"The VMM can intercept non-maskable interrupts (NMI) using a VMCB control bit (see Table 15-7).
When intercepted, NMIs cause an exit from the guest and are held pending."
And yes, after handling NMI VM exit I get subsequent VM exits due to NMIs.
Is it possible to avoid generating these NMI VM exits after handling NMI VM exit internally by VMM?
well i agree with you that, out of these two methods the first one is best and very handy tool.Thanks for mention these informative and helpful methods.