acrn-hypervisor/hypervisor/arch/x86/nmi.c
Ziheng Li eb8bcb06b3 Update copyright year range in code headers
Modified the copyright year range in code, and corrected "int32_tel"
into "Intel" in two "hypervisor/include/debug/profiling.h" and
"hypervisor/include/debug/profiling_internal.h".

Tracked-On: #7559
Signed-off-by: Ziheng Li <ziheng.li@intel.com>
2022-07-15 11:48:35 +08:00

24 lines
532 B
C

/*
* Copyright (C) 2018-2022 Intel Corporation.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#include <asm/irq.h>
#include <asm/vmx.h>
#include <asm/guest/vcpu.h>
#include <asm/guest/virq.h>
void handle_nmi(__unused struct intr_excp_ctx *ctx)
{
uint16_t pcpu_id = get_pcpu_id();
struct acrn_vcpu *vcpu = get_running_vcpu(pcpu_id);
/*
* If NMI occurs, inject it into current vcpu. Now just PMI is verified.
* For other kind of NMI, it may need to be checked further.
*/
vcpu_make_request(vcpu, ACRN_REQUEST_NMI);
}