HV: add missing @pre for some functions

Add @pre for some functions, and fix outdated @pre statements

Tracked-On: #3056
Signed-off-by: dongshen <dongsheng.x.zhang@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
dongshen
2019-05-14 16:35:13 -07:00
committed by ACRN System Integration
parent b957802164
commit 0018da4114
5 changed files with 66 additions and 4 deletions

View File

@@ -51,7 +51,8 @@ static void pci_cfg_clear_cache(struct pci_addr_info *pi)
}
/**
* @pre vm != NULL && vcpu != NULL
* @pre vm != NULL
* @pre vcpu != NULL
*/
static bool pci_cfgaddr_io_read(struct acrn_vm *vm, struct acrn_vcpu *vcpu, uint16_t addr, size_t bytes)
{
@@ -147,7 +148,7 @@ static bool pci_cfgdata_io_read(struct acrn_vm *vm, struct acrn_vcpu *vcpu, uint
/**
* @pre vm != NULL
* @pre vm->vm_id < CONFIG_MAX_VM_NUM
* @pre (get_vm_config(vm->vm_id)->type == PRE_LAUNCHED_VM) || (get_vm_config(vm->vm_id)->type == SOS_VM)
* @pre (get_vm_config(vm->vm_id)->load_order == PRE_LAUNCHED_VM) || (get_vm_config(vm->vm_id)->load_order == SOS_VM)
*/
static bool pci_cfgdata_io_write(struct acrn_vm *vm, uint16_t addr, size_t bytes, uint32_t val)
{