summaryrefslogtreecommitdiff
path: root/components/vmm/vmm_vector.c
blob: 1620d66c7d7f69ac9ba066e6972e31a6bea2a3d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
/*
 *  VMM vector handle
 *
 * COPYRIGHT (C) 2011-2021, Real-Thread Information Technology Ltd
 * All rights reserved
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2013-06-15     Bernard      the first verion
 */
#include <rthw.h>
#include <rtthread.h>
#include <interrupt.h>
#include "vmm.h"

void vmm_guest_isr(int irqno, void* parameter)
{
    /* nothing, let GuestOS to handle it */
    rt_hw_interrupt_clear(irqno);
}

void vmm_vector_init(void)
{
    rt_hw_interrupt_install(RT_VMM_VIRQ_TRIGGER, vmm_guest_isr, RT_NULL, "virq");
    rt_hw_interrupt_umask(RT_VMM_VIRQ_TRIGGER);

    return;
}