mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-24 10:17:28 +00:00
acrn-config: parse KATA VM count number with vm_type 'KATA_VM'
Parse KATA VM count number from scenario config with vm_type 'KATA_VM' and Remove MAX_KATA_VM_NUM from scenario config xmls. Tracked-On: #4641 Signed-off-by: Wei Liu <weix.w.liu@intel.com> Acked-by: Victor Sun <victor.sun@intel.com>
This commit is contained in:
@@ -64,7 +64,6 @@ def get_scenario_item_values(board_info, scenario_info):
|
||||
scenario_item_values["hv,DEBUG_OPTIONS,SERIAL_CONSOLE"] = board_cfg_lib.get_ttys_info(board_info)
|
||||
scenario_item_values["hv,DEBUG_OPTIONS,LOG_DESTINATION"] = hv_cfg_lib.get_select_range("DEBUG_OPTIONS", "LOG_DESTINATION_BITMAP")
|
||||
|
||||
scenario_item_values["hv,CAPACITIES,MAX_KATA_VM_NUM"] = hv_cfg_lib.get_select_range("CAPACITIES", "KATA_VM_NUM")
|
||||
scenario_item_values["hv,CAPACITIES,MAX_IOAPIC_NUM"] = hv_cfg_lib.get_select_range("CAPACITIES", "IOAPIC_NUM")
|
||||
|
||||
scenario_item_values["hv,FEATURES,MULTIBOOT2"] = hv_cfg_lib.N_Y
|
||||
@@ -170,12 +169,6 @@ def main(args):
|
||||
common.print_red("Validate the scenario item failure", err=True)
|
||||
return err_dic
|
||||
|
||||
# get kata vm count
|
||||
scenario_cfg_lib.KATA_VM_COUNT = int(scenario_items['hv'].cap.max_kata_vm_num)
|
||||
if scenario_cfg_lib.KATA_VM_COUNT > 1:
|
||||
err_dic['scenario config'] = "Only one kata vm is supported!"
|
||||
return err_dic
|
||||
|
||||
# generate board defconfig
|
||||
with open(config_hv, 'w+') as config:
|
||||
err_dic = board_defconfig.generate_file(scenario_items['hv'], config)
|
||||
|
@@ -59,11 +59,10 @@ def clos_config_output(vm_info, i, config):
|
||||
def scenario_vm_num(scenario_items, config):
|
||||
|
||||
load_type_cnt = scenario_items['vm'].load_order_cnt
|
||||
kata_vm_num = scenario_items['hv'].cap.max_kata_vm_num
|
||||
print("#define PRE_VM_NUM\t\t{}U".format(load_type_cnt.pre_vm), file=config)
|
||||
print("#define SOS_VM_NUM\t\t{}U".format(load_type_cnt.sos_vm), file=config)
|
||||
print("#define MAX_POST_VM_NUM\t\t{}U".format(load_type_cnt.post_vm), file=config)
|
||||
print("#define CONFIG_MAX_KATA_VM_NUM\t\t{}U".format(kata_vm_num), file=config)
|
||||
print("#define CONFIG_MAX_KATA_VM_NUM\t\t{}U".format(scenario_cfg_lib.KATA_VM_COUNT), file=config)
|
||||
|
||||
|
||||
def gen_pre_launch_vm(vm_info, config):
|
||||
|
Reference in New Issue
Block a user