mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-24 02:08:04 +00:00
hv: add function to check if using posted interrupt is possible for vm
Add platform_caps.c to maintain platform related information Set platform_caps.pi to true if all iommus are posted interrupt capable, false otherwise If lapic passthru is not configured and platform_caps.pi is true, the vm may be able to use posted interrupt for a ptdev, if the ptdev's IRQ is single-destination Tracked-On: #4506 Signed-off-by: dongshen <dongsheng.x.zhang@intel.com> Reviewed-by: Eddie Dong <eddie.dong@Intel.com>
This commit is contained in:
@@ -263,6 +263,7 @@ void vrtc_init(struct acrn_vm *vm);
|
||||
|
||||
bool is_lapic_pt_configured(const struct acrn_vm *vm);
|
||||
bool is_rt_vm(const struct acrn_vm *vm);
|
||||
bool is_pi_capable(const struct acrn_vm *vm);
|
||||
bool has_rt_vm(void);
|
||||
bool is_highest_severity_vm(const struct acrn_vm *vm);
|
||||
bool vm_hide_mtrr(const struct acrn_vm *vm);
|
||||
|
17
hypervisor/include/arch/x86/platform_caps.h
Normal file
17
hypervisor/include/arch/x86/platform_caps.h
Normal file
@@ -0,0 +1,17 @@
|
||||
/*
|
||||
* Copyright (C) 2020 Intel Corporation. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
||||
#ifndef PLATFORM_CAPS_H
|
||||
#define PLATFORM_CAPS_H
|
||||
|
||||
struct platform_caps_x86 {
|
||||
/* true if posted interrupt is supported by all IOMMUs */
|
||||
bool pi;
|
||||
};
|
||||
|
||||
extern struct platform_caps_x86 platform_caps;
|
||||
|
||||
#endif /* PLATFORM_CAPS_H */
|
Reference in New Issue
Block a user