mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-28 12:05:59 +00:00
There are still some misra-c violations when CONFIG_PARTITION_MODE is defined. arch/x86/configs: - remove the unused macro: PRE_LAUNCH_VM_NUM - pt_dev.c: VMx_CONFIG_PCI_PTDEV_NUM has been defined in partition_config.h, should not hard code them again in pt_dev.c. - ve820.c: use "UL" suffix instead of "U" for 64 bits variables. vmid is uint16_t in ACRN, so vuart_vmid should be uint16_t as well. Fix another few other miscellaneous misra-c violations. Tracked-On: #861 Signed-off-by: Zide Chen <zide.chen@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
35 lines
887 B
C
35 lines
887 B
C
/*
|
|
* Copyright (C) 2019 Intel Corporation. All rights reserved.
|
|
*
|
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
*/
|
|
|
|
#include <vm.h>
|
|
#include <partition_config.h>
|
|
|
|
struct acrn_vm_pci_ptdev_config vm0_pci_ptdevs[VM0_CONFIG_PCI_PTDEV_NUM] = {
|
|
{
|
|
.vbdf.bits = {.b = 0x00U, .d = 0x00U, .f = 0x00U},
|
|
.pbdf.bits = {.b = 0x00U, .d = 0x00U, .f = 0x00U},
|
|
},
|
|
{
|
|
.vbdf.bits = {.b = 0x00U, .d = 0x01U, .f = 0x00U},
|
|
.pbdf.bits = {.b = 0x00U, .d = 0x12U, .f = 0x00U},
|
|
},
|
|
};
|
|
|
|
struct acrn_vm_pci_ptdev_config vm1_pci_ptdevs[VM1_CONFIG_PCI_PTDEV_NUM] = {
|
|
{
|
|
.vbdf.bits = {.b = 0x00U, .d = 0x00U, .f = 0x00U},
|
|
.pbdf.bits = {.b = 0x00U, .d = 0x00U, .f = 0x00U},
|
|
},
|
|
{
|
|
.vbdf.bits = {.b = 0x00U, .d = 0x01U, .f = 0x00U},
|
|
.pbdf.bits = {.b = 0x00U, .d = 0x15U, .f = 0x00U},
|
|
},
|
|
{
|
|
.vbdf.bits = {.b = 0x00U, .d = 0x02U, .f = 0x00U},
|
|
.pbdf.bits = {.b = 0x02U, .d = 0x00U, .f = 0x00U},
|
|
},
|
|
};
|