mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2026-01-06 16:15:00 +00:00
HV: Enclose debug specific code with #ifdef HV_DEBUG
Thare some debug specific code which don't run on release version, such as vmexit_time, vmexit_cnt, sbuf related codes, etc... This patch encloses the codes with #ifdef HV_DEBUG. Signed-off-by: Kaige Fu <kaige.fu@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -788,6 +788,7 @@ hcall_reset_ptdev_intr_info(struct vm *vm, uint16_t vmid, uint64_t param)
|
||||
return ret;
|
||||
}
|
||||
|
||||
#ifdef HV_DEBUG
|
||||
int32_t hcall_setup_sbuf(struct vm *vm, uint64_t param)
|
||||
{
|
||||
struct sbuf_setup_param ssp;
|
||||
@@ -808,6 +809,12 @@ int32_t hcall_setup_sbuf(struct vm *vm, uint64_t param)
|
||||
|
||||
return sbuf_share_setup(ssp.pcpu_id, ssp.sbuf_id, hva);
|
||||
}
|
||||
#else
|
||||
int32_t hcall_setup_sbuf(__unused struct vm *vm, __unused uint64_t param)
|
||||
{
|
||||
return -ENODEV;
|
||||
}
|
||||
#endif
|
||||
|
||||
int32_t hcall_get_cpu_pm_state(struct vm *vm, uint64_t cmd, uint64_t param)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user