HV: Don't make NMI injection req when notifying vCPU

The NMI for notification should not be inject to guest. So,
this patch drops NMI injection request when we use NMI
to notify vCPUs. Meanwhile, ACRN doesn't support vNMI well
and there is no well-designed way to check if the NMI is
for notification or for guest now. So, we take all the NMIs as
notificaton NMI for hard rtvm temporarily. It means that the
hard rtvm will never receive NMI with this patch applied.

TODO: vNMI support is not ready yet. we will add it later.

Tracked-On: #3886
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
This commit is contained in:
Kaige Fu
2019-12-11 19:45:54 +00:00
committed by wenlingz
parent 72f7f69c47
commit 40ba7e8686
4 changed files with 53 additions and 3 deletions

View File

@@ -65,6 +65,7 @@
#define IRQF_PT (1U << 2U) /* 1: for passthrough dev */
struct acrn_vcpu;
struct acrn_vm;
/*
* Definition of the stack frame layout
@@ -87,6 +88,7 @@ struct smp_call_info_data {
};
void smp_call_function(uint64_t mask, smp_call_func_t func, void *data);
bool is_notification_nmi(const struct acrn_vm *vm);
void init_default_irqs(uint16_t cpu_id);