diff --git a/misc/acrn-config/board_config/board_c.py b/misc/acrn-config/board_config/board_c.py index 509e2a87e..00f2439b7 100644 --- a/misc/acrn-config/board_config/board_c.py +++ b/misc/acrn-config/board_config/board_c.py @@ -91,17 +91,21 @@ def gen_dmar_structure(config): print("};", file=config) -def populate_clos_mask_msr(rdt_res, common_clos_max, mask, config): +def populate_clos_mask_msr(rdt_res, common_clos_max, config): """ Populate the clos bitmask and msr index for a given RDT resource :param rdt_res: it is a string representing the RDT resource :param common_clos_max: Least common clos supported by all RDT resource - :param mask: Max CLOS mask supported by the RDT resource :param config: it is a file pointer of board information for writing to """ + cat_mask_list = common.get_hv_item_tag(common.SCENARIO_INFO_FILE, "FEATURES", "RDT", "CLOS_MASK") + cat_max_mask_settings_len = len(cat_mask_list) for idx in range(common_clos_max): print("\t{", file=config) - print("\t\t.clos_mask = {0}U,".format(hex(mask)), file=config) + if idx < cat_max_mask_settings_len: + print("\t\t.clos_mask = {0}U,".format(cat_mask_list[idx]), file=config) + else: + print("\t\t.clos_mask = 0xffU,", file=config) print("\t\t.msr_index = MSR_IA32_{0}_MASK_BASE + {1},".format( rdt_res, idx), file=config) print("\t},", file=config) @@ -129,7 +133,7 @@ def gen_rdt_res(config): err_dic = {} rdt_res_str ="" res_present = [0, 0, 0] - (rdt_resources, rdt_res_clos_max, rdt_res_mask_max) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) + (rdt_resources, rdt_res_clos_max, _) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) if len(rdt_res_clos_max) != 0: common_clos_max = min(rdt_res_clos_max) else: @@ -151,14 +155,14 @@ def gen_rdt_res(config): rdt_res_str = "l2" print("struct platform_clos_info platform_{0}_clos_array[{1}] = {{".format(rdt_res_str, "MAX_PLATFORM_CLOS_NUM"), file=config) - populate_clos_mask_msr(rdt_res, common_clos_max, int(rdt_res_mask_max[idx].strip('\''), 16), config) + populate_clos_mask_msr(rdt_res, common_clos_max, config) print("};\n", file=config) res_present[RDT.L2.value] = 1 elif rdt_res == "L3": rdt_res_str = "l3" print("struct platform_clos_info platform_{0}_clos_array[{1}] = {{".format(rdt_res_str, "MAX_PLATFORM_CLOS_NUM"), file=config) - populate_clos_mask_msr(rdt_res, common_clos_max, int(rdt_res_mask_max[idx].strip('\''), 16), config) + populate_clos_mask_msr(rdt_res, common_clos_max, config) print("};\n", file=config) res_present[RDT.L3.value] = 1 elif rdt_res == "MBA": diff --git a/misc/acrn-config/config_app/controller.py b/misc/acrn-config/config_app/controller.py index d5aee2aad..a335b408d 100644 --- a/misc/acrn-config/config_app/controller.py +++ b/misc/acrn-config/config_app/controller.py @@ -208,6 +208,18 @@ class XmlConfig: new_node = ElementTree.SubElement(dest_node, key, attrib={'desc': desc}) new_node.text = value + def get_curr_elem(self, *args): + """ + get elements for current path. + :param args: the path of the element. + :return: current element. + """ + if self._curr_xml_tree is None: + return + + dest_node = self._get_dest_node(*args) + return dest_node + def clone_curr_elem(self, elem, *args): """ clone elements for current path. @@ -235,6 +247,18 @@ class XmlConfig: dest_node = self._get_dest_node(*args) dest_node.insert(index, elem) + def delete_curr_elem(self, *args): + """ + delete the element by its path. + :param args: the path of the element. + :return: None. + """ + if self._curr_xml_tree is None: + return + father_node = self._get_dest_node(*args[:-1]) + dest_node = self._get_dest_node(*args) + father_node.remove(dest_node) + def delete_curr_key(self, *args): """ delete the element by its path. diff --git a/misc/acrn-config/config_app/static/main.js b/misc/acrn-config/config_app/static/main.js index eb235ef70..86539d98d 100644 --- a/misc/acrn-config/config_app/static/main.js +++ b/misc/acrn-config/config_app/static/main.js @@ -401,6 +401,18 @@ $().ready(function(){ show_com_target(id, value); }); + $("select[ID$='FEATURES,RDT,CDP_ENABLED']").change(function(){ + var id = $(this).attr('id'); + var value = $(this).val(); + update_vcpu_clos_option(id, value); + }); + + $("select[ID$='FEATURES,RDT,CDP_ENABLED']").each(function(index, item) { + var id = $(this).attr('id'); + var value = $(item).val(); + update_vcpu_clos_option(id, value); + }); + $(document).on('click', "button:contains('+')", function() { if($(this).text() != '+') return; @@ -408,7 +420,21 @@ $().ready(function(){ var curr_id = curr_item_id.substr(curr_item_id.lastIndexOf('_')+1); var config_item = $(this).parent().parent(); var config_item_added = config_item.clone(); - var id_added = (parseInt(curr_id)+1).toString(); + var config_vm = config_item.parent(); + var vcpu_index_list = []; + config_vm.children().each(function(){ + if($(this).find("button:contains('+')").size() > 0) { + var btn_add_vm_id = $(this).find("button:contains('+')").attr('id'); + vcpu_index_list.push(parseInt(btn_add_vm_id.substr(btn_add_vm_id.lastIndexOf('_')+1))); + } + }); + var id_added = 0; + for (i=0; i<100; i++) { + if (!vcpu_index_list.includes(i)) { + id_added = i; + break + } + } var id_pre_added = curr_item_id.substr(0, curr_item_id.lastIndexOf('_')); config_item_added.find("button:contains('+')").attr('id', id_pre_added+'_'+id_added); config_item_added.find("button:contains('-')").attr('id', id_pre_added.replace('add_', 'remove_')+'_'+id_added); @@ -418,12 +444,50 @@ $().ready(function(){ config_item_added.find('.selectpicker').val('default').selectpicker('deselectAll');; config_item_added.find('.selectpicker').selectpicker('render'); config_item_added.insertAfter(config_item); + + if(curr_item_id.indexOf('add_vcpu')>=0) { + var config_vm = config_item.parent(); + var curr_vcpu_index = vcpu_index_list.indexOf(parseInt(curr_id)) + var vcpu_clos_item = config_vm.find("label:contains('vcpu_clos')").first().parent(); + while(curr_vcpu_index > 0) { + vcpu_clos_item = vcpu_clos_item.next(); + curr_vcpu_index -= 1; + } + + var vcpu_clos_item_added = vcpu_clos_item.clone(); + vcpu_clos_item_added.find("label:first").text(""); + vcpu_clos_item_added.find('.bootstrap-select').replaceWith(function() { return $('select', this); }); + vcpu_clos_item_added.find('.selectpicker').val('default').selectpicker('deselectAll');; + vcpu_clos_item_added.find('.selectpicker').selectpicker('render'); + vcpu_clos_item_added.insertAfter(vcpu_clos_item); + } }); $(document).on('click', "button:contains('-')", function() { if($(this).text() != '-') return; var config_item = $(this).parent().parent(); + var curr_item_id = $(this).attr('id'); + if(curr_item_id.indexOf('remove_vcpu')>=0) { + var config_vm = config_item.parent(); + var vcpu_index_list = []; + config_vm.children().each(function(){ + if($(this).find("button:contains('+')").size() > 0) { + var btn_del_vm_id = $(this).find("button:contains('+')").attr('id'); + vcpu_index_list.push(parseInt(btn_del_vm_id.substr(btn_del_vm_id.lastIndexOf('_')+1))); + } + }); + var curr_item_id = $(this).attr('id'); + var curr_id = parseInt(curr_item_id.substr(curr_item_id.lastIndexOf('_')+1)); + curr_vcpu_index = vcpu_index_list.indexOf(curr_id); + + var vcpu_clos_item = config_vm.find("label:contains('vcpu_clos')").first().parent(); + while(curr_vcpu_index > 0) { + vcpu_clos_item = vcpu_clos_item.next(); + curr_vcpu_index -= 1; + } + vcpu_clos_item.remove(); + } config_item.remove(); }); @@ -472,6 +536,35 @@ function show_com_target(id, value) { } } + +function update_vcpu_clos_option(id, value) { + if(value == 'y') { + $("select[ID$='clos,vcpu_clos']").each(function(){ + len = $(this).find('option').length; + option = $(this).find('option').first(); + for(i=0; i(len-1)/2){ + option.attr('disabled','disabled'); + } + option = option.next(); + } + $(this).selectpicker('render'); + }); + } else { + $("select[ID$='clos,vcpu_clos']").each(function(){ + len = $(this).find('option').length; + option = $(this).find('option').first(); + for(i=0; i(len-1)/2){ + option.removeAttr('disabled'); + } + option = option.next(); + } + $(this).selectpicker('render'); + }); + } +} + function create_setting(type, default_name, name, mode){ var board_info = $("text#board_type").text(); if (board_info==null || board_info=='') { @@ -570,7 +663,13 @@ function save_scenario(generator=null){ $("input").each(function(){ var id = $(this).attr('id'); var value = $(this).val(); - if(id!='new_scenario_name' && id!='new_scenario_name2' && id!='board_info_file' && id!='board_info_upload' + if(id.indexOf('CLOS_MASK')>=0 ) { + if(id in scenario_config) { + scenario_config[id].push(value); + } else { + scenario_config[id] = [value]; + } + } else if(id!='new_scenario_name' && id!='new_scenario_name2' && id!='board_info_file' && id!='board_info_upload' && id!='scenario_file' && id!='create_name' && id!='load_scenario_name2' && id!='load_launch_name2' && id!='src_path') { scenario_config[id] = value; @@ -586,7 +685,7 @@ function save_scenario(generator=null){ $("select").each(function(){ var id = $(this).attr('id'); var value = $(this).val(); - if(id.indexOf('pcpu_id')>=0 || id.indexOf('pci_dev')>=0) { + if(id.indexOf('pcpu_id')>=0 || id.indexOf('pci_dev')>=0 || id.indexOf('vcpu_clos')>=0) { if(id in scenario_config) { scenario_config[id].push(value); } else { diff --git a/misc/acrn-config/config_app/templates/base.html b/misc/acrn-config/config_app/templates/base.html index 1757f233a..69004bb9d 100644 --- a/misc/acrn-config/config_app/templates/base.html +++ b/misc/acrn-config/config_app/templates/base.html @@ -179,7 +179,7 @@ - + {{board_type if board_type != None else ''}}
@@ -207,4 +207,4 @@ - \ No newline at end of file + diff --git a/misc/acrn-config/config_app/templates/scenario.html b/misc/acrn-config/config_app/templates/scenario.html index 2608b6521..15f5416c3 100644 --- a/misc/acrn-config/config_app/templates/scenario.html +++ b/misc/acrn-config/config_app/templates/scenario.html @@ -210,6 +210,76 @@ the source files will be generated into default path and overwirte the previous {% set first_child = [] %} {% for sub_elem in elem.getchildren() %} {% set sub_elem_text = sub_elem.text if sub_elem.text != None else '' %} + + {% if sub_elem.tag == 'RDT' %} + {% for sub_elem_2 in sub_elem.getchildren() %} + {% if ','.join([vm.tag, elem.tag, sub_elem.tag, sub_elem_2.tag]) not in scenario_item_values %} +
+ + +
+ {% if 'readonly' in sub_elem_2.attrib and sub_elem_2.attrib['readonly'] == 'true' %} + + {% else %} + + {% endif %} +
+

+
+ {% elif sub_elem_2.tag != 'CLOS_MASK' %} +
+ + + +

+
+ {% else %} +
+ + +
+ +
+

+
+ {% endif %} + {% endfor %} + + {% else %} + {% if 'configurable' not in sub_elem.attrib or sub_elem.attrib['configurable'] != '0' %}
{% if 'id' not in elem.attrib %} @@ -222,6 +292,7 @@ the source files will be generated into default path and overwirte the previous title="{{elem.attrib['desc'] if 'desc' in elem.attrib else elem.tag}}"> {% endif %} + @@ -353,6 +424,7 @@ the source files will be generated into default path and overwirte the previous {% endif %}
{% endif %} + {% endif %} {% endfor %} {% elif 'configurable' not in elem.attrib or elem.attrib['configurable'] != '0' %}
diff --git a/misc/acrn-config/config_app/views.py b/misc/acrn-config/config_app/views.py index 0cdfe9c3e..b0191c4fd 100644 --- a/misc/acrn-config/config_app/views.py +++ b/misc/acrn-config/config_app/views.py @@ -147,7 +147,6 @@ def save_scenario(): :return: the error list for the edited scenario setting. """ scenario_config_data = request.json if request.method == "POST" else request.args - xml_configs = get_xml_configs() board_type = xml_configs[1] scenario_config = xml_configs[3] @@ -426,6 +425,7 @@ def create_setting(): create_name = create_config_data['create_name'] xml_configs = get_xml_configs(True) + board_info = xml_configs[0] board_type = xml_configs[1] scenario_config = xml_configs[2] launch_config = xml_configs[3] @@ -470,7 +470,16 @@ def create_setting(): copyfile(src_file_name, os.path.join(current_app.config.get('CONFIG_PATH'), board_type, 'user_defined', create_name + '.xml')) - + if mode == 'create': + # update RDT->CLOS_MASK according to board xml + scenario_config.set_curr(create_name) + rdt_clos_max = get_board_rdt_clos_max(board_info) + elem_clos_max = scenario_config.get_curr_elem('hv', 'FEATURES', 'RDT', 'CLOS_MASK') + if rdt_clos_max > 0: + for i in range(rdt_clos_max - 1): + scenario_config.clone_curr_elem(elem_clos_max, 'hv', 'FEATURES', 'RDT') + else: + scenario_config.delete_curr_elem('hv', 'FEATURES', 'RDT', 'CLOS_MASK') scenario_config.save(create_name) return {'status': 'success', 'setting': create_name, 'error_list': {}} @@ -616,6 +625,17 @@ def upload_board_info(): board_type)) xml_config.set_curr(generic_name[:-4]) xml_config.set_curr_attr('board', board_type) + # update RDT->CLOS_MASK according to board xml + xml_config_root = xml_config.get_curr_root() + if 'board' in xml_config_root.attrib and 'scenario' in xml_config_root.attrib \ + and 'uos_launcher' not in xml_config_root.attrib: + rdt_clos_max = get_board_rdt_clos_max(filename.rsplit('.', 1)[0]) + elem_clos_max = xml_config.get_curr_elem('hv', 'FEATURES', 'RDT', 'CLOS_MASK') + if rdt_clos_max > 0: + for i in range(rdt_clos_max-1): + xml_config.clone_curr_elem(elem_clos_max, 'hv', 'FEATURES', 'RDT') + else: + xml_config.delete_curr_elem('hv', 'FEATURES', 'RDT', 'CLOS_MASK') xml_config.save(generic_name[:-4], user_defined=False) board_info = os.path.splitext(file.filename)[0] @@ -924,7 +944,7 @@ def get_board_info(board_info): """ get board info type :param board_info: the board info file - :return: the board type + :return: the board info """ board_config = get_board_config(board_info) bios_info = None @@ -951,6 +971,32 @@ def get_board_info(board_info): return (bios_info, base_board_info) +def get_board_rdt_clos_max(board_info): + """ + get board info type + :param board_info: the board info file + :return: the rdt clos max + """ + board_config = get_board_config(board_info) + rdt_clos_max = 0 + + if board_config is not None: + board_info_root = board_config.get_curr_root() + if board_info_root: + for item in board_info_root.getchildren(): + if item.tag == 'CLOS_INFO': + for line in item.text.split('\n'): + line = line.strip() + if line.startswith('rdt resource clos max:'): + try: + rdt_clos_max = int(line.split(':')[1].strip()) + break + except: + pass + + return rdt_clos_max + + def assign_vm_id(scenario_config): """ assign vm ids for the scenario setting. diff --git a/misc/acrn-config/hv_config/board_defconfig.py b/misc/acrn-config/hv_config/board_defconfig.py index 55a46a7c2..0bb8ceecf 100644 --- a/misc/acrn-config/hv_config/board_defconfig.py +++ b/misc/acrn-config/hv_config/board_defconfig.py @@ -108,17 +108,6 @@ def get_serial_type(): return (ttys_type, ttys_value) -def is_rdt_supported(): - """ - Returns True if platform supports RDT else False - """ - (rdt_resources, rdt_res_clos_max, _) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) - if len(rdt_resources) == 0 or len(rdt_res_clos_max) == 0: - return False - else: - return True - - def get_memory(hv_info, config): # this dictonary mapped with 'address start':'mem range' @@ -181,6 +170,11 @@ def get_features(hv_info, config): print("CONFIG_{}=y".format(hv_info.features.scheduler), file=config) print("CONFIG_RELOC={}".format(hv_info.features.reloc), file=config) print("CONFIG_MULTIBOOT2={}".format(hv_info.features.multiboot2), file=config) + print("CONFIG_RDT_ENABLED={}".format(hv_info.features.rdt_enabled), file=config) + if hv_info.features.rdt_enabled == 'y': + print("CONFIG_CDP_ENABLED={}".format(hv_info.features.cdp_enabled), file=config) + else: + print("CONFIG_CDP_ENABLED=n", file=config) print("CONFIG_HYPERV_ENABLED={}".format(hv_info.features.hyperv_enabled), file=config) print("CONFIG_IOMMU_ENFORCE_SNP={}".format(hv_info.features.iommu_enforce_snp), file=config) print("CONFIG_ACPI_PARSE_ENABLED={}".format(hv_info.features.acpi_parse_enabled), file=config) @@ -231,11 +225,6 @@ def generate_file(hv_info, config): get_serial_console(config) get_log_opt(hv_info, config) - if is_rdt_supported(): - print("CONFIG_RDT_ENABLED=y", file=config) - else: - print("CONFIG_RDT_ENABLED=n", file=config) - print("CONFIG_ENFORCE_VALIDATED_ACPI_INFO=y", file=config) return err_dic diff --git a/misc/acrn-config/hv_config/hv_item.py b/misc/acrn-config/hv_config/hv_item.py index a15cd7ec0..c849b67e0 100644 --- a/misc/acrn-config/hv_config/hv_item.py +++ b/misc/acrn-config/hv_config/hv_item.py @@ -102,6 +102,9 @@ class Features: self.hv_file = hv_file self.reloc = '' self.multiboot2 = '' + self.rdt_enabled = '' + self.cdp_enabled = '' + self.cat_max_mask = [] self.scheduler = '' self.hyperv_enabled = '' self.iommu_enforce_snp = '' @@ -111,6 +114,9 @@ class Features: def get_info(self): self.multiboot2 = common.get_hv_item_tag(self.hv_file, "FEATURES", "MULTIBOOT2") + self.rdt_enabled = common.get_hv_item_tag(self.hv_file, "FEATURES", "RDT", "RDT_ENABLED") + self.cdp_enabled = common.get_hv_item_tag(self.hv_file, "FEATURES", "RDT", "CDP_ENABLED") + self.cat_max_mask = common.get_hv_item_tag(self.hv_file, "FEATURES", "RDT", "CLOS_MASK") self.scheduler = common.get_hv_item_tag(self.hv_file, "FEATURES", "SCHEDULER") self.reloc = common.get_hv_item_tag(self.hv_file, "FEATURES", "RELOC") self.hyperv_enabled = common.get_hv_item_tag(self.hv_file, "FEATURES", "HYPERV_ENABLED") @@ -121,6 +127,9 @@ class Features: def check_item(self): hv_cfg_lib.ny_support_check(self.multiboot2, "FEATURES", "MULTIBOOT2") + hv_cfg_lib.ny_support_check(self.rdt_enabled, "FEATURES", "RDT", "RDT_ENABLED") + hv_cfg_lib.ny_support_check(self.cdp_enabled, "FEATURES", "RDT", "CDP_ENABLED") + hv_cfg_lib.cat_max_mask_check(self.cat_max_mask, "FEATURES", "RDT", "CLOS_MASK") hv_cfg_lib.scheduler_check(self.scheduler, "FEATURES", "SCHEDULER") hv_cfg_lib.ny_support_check(self.reloc, "FEATURES", "RELOC") hv_cfg_lib.ny_support_check(self.hyperv_enabled, "FEATURES", "HYPERV_ENABLED") diff --git a/misc/acrn-config/library/board_cfg_lib.py b/misc/acrn-config/library/board_cfg_lib.py index 57995cd7b..405f90044 100644 --- a/misc/acrn-config/library/board_cfg_lib.py +++ b/misc/acrn-config/library/board_cfg_lib.py @@ -462,3 +462,33 @@ def parser_pci(): PCI_DEV_BAR_DESC.pci_bar_dic[cur_bdf] = tmp_bar_dic return sub_name_count + + +def is_rdt_supported(): + """ + Returns True if platform supports RDT else False + """ + (rdt_resources, rdt_res_clos_max, _) = clos_info_parser(common.BOARD_INFO_FILE) + if len(rdt_resources) == 0 or len(rdt_res_clos_max) == 0: + return False + else: + return True + + +def get_rdt_select_opt(): + + support_sel = ['n'] + if is_rdt_supported(): + support_sel.append('y') + return support_sel + + +def get_clos_mask_num(): + clos_mask_num = 0 + (rdt_resources, rdt_res_clos_max, _) = clos_info_parser(common.BOARD_INFO_FILE) + if len(rdt_resources) == 0 or len(rdt_res_clos_max) == 0: + clos_mask_num = 0 + else: + clos_mask_num = min(rdt_res_clos_max) + + return clos_mask_num diff --git a/misc/acrn-config/library/common.py b/misc/acrn-config/library/common.py index fc26ce2d2..410b7532c 100644 --- a/misc/acrn-config/library/common.py +++ b/misc/acrn-config/library/common.py @@ -406,7 +406,7 @@ def get_vuart_info_id(config_file, idx): return tmp_tag -def get_hv_item_tag(config_file, branch_tag, tag_str=''): +def get_hv_item_tag(config_file, branch_tag, tag_str='', leaf_str=''): tmp = '' root = get_config_root(config_file) @@ -423,9 +423,25 @@ def get_hv_item_tag(config_file, branch_tag, tag_str=''): # for each 3rd level item for leaf in sub: - if leaf.tag == tag_str and leaf.text and leaf.text != None: - tmp = leaf.text - continue + if leaf.tag == tag_str: + if not leaf_str: + if leaf.tag == tag_str and leaf.text and leaf.text != None: + tmp = leaf.text + else: + # for each 4rd level item + tmp_list = [] + for leaf_s in leaf: + if leaf_s.tag == leaf_str and leaf_s.text and leaf_s.text != None: + if leaf_str == "CLOS_MASK": + tmp_list.append(leaf_s.text) + else: + tmp = leaf_s.text + continue + + if leaf_str == "CLOS_MASK": + tmp = tmp_list + break + return tmp diff --git a/misc/acrn-config/library/hv_cfg_lib.py b/misc/acrn-config/library/hv_cfg_lib.py index 920a235d7..a9eb86df9 100644 --- a/misc/acrn-config/library/hv_cfg_lib.py +++ b/misc/acrn-config/library/hv_cfg_lib.py @@ -7,6 +7,7 @@ import os import sys import common import getopt +import board_cfg_lib ERR_LIST = {} @@ -25,10 +26,14 @@ RANGE_DB = { } -def empty_check(val, prime_item, item): +def empty_check(val, prime_item, item, sub_item=''): if not val or val == None: - key = 'hv,{},{}'.format(prime_item, item) - ERR_LIST[key] = "{} should not empty".format(item) + if sub_item: + key = 'hv,{},{},{}'.format(prime_item, item, sub_item) + ERR_LIST[key] = "{} should not empty".format(sub_item) + else: + key = 'hv,{},{}'.format(prime_item, item) + ERR_LIST[key] = "{} should not empty".format(item) return True return False @@ -100,8 +105,8 @@ def uefi_load_name_check(str_name, mis, mis_uefi_name): ERR_LIST[key] = "{} length should be in range[1, 256]".format(mis_uefi_name) -def ny_support_check(sel_str, feat, feat_item): - if empty_check(sel_str, feat, feat_item): +def ny_support_check(sel_str, feat, feat_item, feat_sub_leaf=''): + if empty_check(sel_str, feat, feat_item, feat_sub_leaf): return if sel_str not in N_Y: key = 'hv,{},{}'.format(feat, feat_item) @@ -128,3 +133,66 @@ def get_select_range(branch_tag, range_key): range_list.append(str(range_i)) return range_list + + +def is_contiguous_bit_set(value): + + bit_1_cnt = 0 + tmp_val = value + is_contiguous = False + + first_p = 0 + last_p = 0 + + while tmp_val > 0: + tmp_val &= (tmp_val - 1) + bit_1_cnt += 1 + + for shift_i in range(32): + mask = (0x1 << shift_i) + if value & mask: + if first_p == 0 and last_p == 0: + first_p = shift_i + 1 + elif first_p != 0: + last_p = shift_i + 1 + else: + if first_p == 0 and last_p == 0: + continue + break + + + contiguous_cnt = last_p - first_p + 1 + if bit_1_cnt == contiguous_cnt or bit_1_cnt in (0, 1): + is_contiguous = True + + return is_contiguous + + +def cat_max_mask_check(cat_mask_list, feature, cat_str, max_mask_str): + + if not board_cfg_lib.is_rdt_supported(): + return + + cpu_num = len(board_cfg_lib.get_processor_info()) + cat_max_mask_settings_len = len(cat_mask_list) + if cpu_num != cat_max_mask_settings_len: + key = 'hv,{},{},{}'.format(feature, cat_str, max_mask_str) + ERR_LIST[key] = "Total {} CPU cores, should set the same number for CLOS_MASK.".format(cpu_num) + return + + (_, rdt_res_clos_max, clos_max_mask_list) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) + clos_max_mask_str = clos_max_mask_list[0].strip('"').strip("'") + clos_max_mask = common.num2int(clos_max_mask_str) + for val_str in cat_mask_list: + if empty_check(val_str, feature, cat_str, max_mask_str): + return + value = common.num2int(val_str) + if value < 0 or value > clos_max_mask: + key = 'hv,{},{},{}'.format(feature, cat_str, max_mask_str) + ERR_LIST[key] = "{} should be in range[0,{}]".format(max_mask_str, clos_max_mask_str) + return + + if not is_contiguous_bit_set(value): + key = 'hv,{},{},{}'.format(feature, cat_str, max_mask_str) + ERR_LIST[key] = "CLOS_MASK {} should be contiguous bit set.".format(max_mask_str, clos_max_mask_str) + return diff --git a/misc/acrn-config/library/scenario_cfg_lib.py b/misc/acrn-config/library/scenario_cfg_lib.py index 30a39c865..9ba6ca208 100644 --- a/misc/acrn-config/library/scenario_cfg_lib.py +++ b/misc/acrn-config/library/scenario_cfg_lib.py @@ -585,3 +585,35 @@ def check_vuart(v0_vuart, v1_vuart): if t_vm_id.isnumeric() and int(t_vm_id) not in common.VM_TYPES.keys(): key = "vm:id={},vuart:id=1,target_vm_id".format(vm_i) ERR_LIST[key] = "target_vm_id which specified does not exist" + + +def vcpu_clos_check(cpus_per_vm, clos_per_vm, prime_item, item): + common_clos_max = 0 + cdp_enabled = cdp_enabled = common.get_hv_item_tag(common.SCENARIO_INFO_FILE, "FEATURES", "RDT", "CDP_ENABLED") + (rdt_resources, rdt_res_clos_max, _) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) + if len(rdt_resources) != 0 and len(rdt_res_clos_max) != 0: + common_clos_max = min(rdt_res_clos_max) + if cdp_enabled == 'y': + common_clos_max //= 2 + + for vm_i,vcpus in cpus_per_vm.items(): + clos_per_vm_len = 0 + if vm_i in clos_per_vm: + clos_per_vm_len = len(clos_per_vm[vm_i]) + + if clos_per_vm_len != len(vcpus): + key = "vm:id={},{},{}".format(vm_i, prime_item, item) + ERR_LIST[key] = "'vcpu_clos' number should be equal 'pcpu_id' number for VM{}".format(vm_i) + return + + if cdp_enabled == 'y' and common_clos_max != 0: + for clos_val in clos_per_vm[vm_i]: + if not clos_val or clos_val == None: + key = "vm:id={},{},{}".format(vm_i, prime_item, item) + ERR_LIST[key] = "'vcpu_clos' should be not None" + return + + if int(clos_val) >= common_clos_max: + key = "vm:id={},{},{}".format(vm_i, prime_item, item) + ERR_LIST[key] = "CDP_ENABLED=y, the clos value should not be greater than {} for VM{}".format(common_clos_max - 1, vm_i) + return diff --git a/misc/acrn-config/scenario_config/scenario_cfg_gen.py b/misc/acrn-config/scenario_config/scenario_cfg_gen.py index 97c39a353..cf3cc6ce2 100755 --- a/misc/acrn-config/scenario_config/scenario_cfg_gen.py +++ b/misc/acrn-config/scenario_config/scenario_cfg_gen.py @@ -46,7 +46,7 @@ def get_scenario_item_values(board_info, scenario_info): scenario_item_values['vm,vm_type'] = scenario_cfg_lib.LOAD_VM_TYPE scenario_item_values["vm,cpu_affinity"] = hw_info.get_processor_val() scenario_item_values["vm,guest_flags"] = guest_flags - scenario_item_values["vm,clos"] = hw_info.get_clos_val() + scenario_item_values["vm,clos,vcpu_clos"] = hw_info.get_clos_val() scenario_item_values["vm,pci_devs"] = scenario_cfg_lib.avl_pci_devs() scenario_item_values["vm,os_config,kern_type"] = scenario_cfg_lib.KERN_TYPE_LIST scenario_item_values.update(scenario_cfg_lib.avl_vuart_ui_select(scenario_info)) @@ -64,6 +64,9 @@ def get_scenario_item_values(board_info, scenario_info): 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 + scenario_item_values["hv,FEATURES,RDT,RDT_ENABLED"] = board_cfg_lib.get_rdt_select_opt() + scenario_item_values["hv,FEATURES,RDT,CDP_ENABLED"] = board_cfg_lib.get_rdt_select_opt() + scenario_item_values["hv,FEATURES,RDT,CLOS_MASK"] = board_cfg_lib.get_clos_mask_num() scenario_item_values["hv,FEATURES,SCHEDULER"] = hv_cfg_lib.SCHEDULER_TYPE scenario_item_values["hv,FEATURES,RELOC"] = hv_cfg_lib.N_Y scenario_item_values["hv,FEATURES,HYPERV_ENABLED"] = hv_cfg_lib.N_Y @@ -178,7 +181,7 @@ def main(args): # generate vm_configuration.c with open(vm_config_c, 'w') as config: - err_dic = vm_configurations_c.generate_file(scenario_items['vm'], config) + err_dic = vm_configurations_c.generate_file(scenario_items, config) if err_dic: return err_dic diff --git a/misc/acrn-config/scenario_config/scenario_item.py b/misc/acrn-config/scenario_config/scenario_item.py index 35642a260..b8b11aeeb 100644 --- a/misc/acrn-config/scenario_config/scenario_item.py +++ b/misc/acrn-config/scenario_config/scenario_item.py @@ -48,9 +48,11 @@ class HwInfo: :return: clos support list """ self.clos_val = [] + (rdt_resources, rdt_res_clos_max, _) = board_cfg_lib.clos_info_parser(self.board_info) if len(rdt_resources) != 0 and len(rdt_res_clos_max) != 0: common_clos_max = min(rdt_res_clos_max) + for i_cnt in range(common_clos_max): self.clos_val.append(str(i_cnt)) @@ -302,6 +304,7 @@ class VmInfo: scenario_cfg_lib.load_vm_check(self.load_vm, "load_vm") scenario_cfg_lib.guest_flag_check(self.guest_flags, "guest_flags", "guest_flag") err_dic = scenario_cfg_lib.vm_cpu_affinity_check(self.scenario_info, self.cpus_per_vm, "pcpu_id") + scenario_cfg_lib.vcpu_clos_check(self.cpus_per_vm, self.clos_per_vm, "clos", "vcpu_clos") self.mem_info.check_item() self.os_cfg.check_item() diff --git a/misc/acrn-config/scenario_config/vm_configurations_c.py b/misc/acrn-config/scenario_config/vm_configurations_c.py index cde6ef315..3c8204e0f 100644 --- a/misc/acrn-config/scenario_config/vm_configurations_c.py +++ b/misc/acrn-config/scenario_config/vm_configurations_c.py @@ -197,20 +197,17 @@ def cpu_affinity_output(vm_info, i, config): print("\t\t.cpu_affinity = VM{}_CONFIG_CPU_AFFINITY,".format(i), file=config) -def clos_output(vm_info, i, config): +def clos_output(scenario_items, i, config): """ This is generate clos setting - :param vm_info: it is the class which contain all user setting information + :param scenario_items: it is the class which contain all user setting information :param i: vm id number :param config: it is the pointer which file write to :return: None """ - (rdt_res, rdt_res_clos_max, _) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) - if len(rdt_res_clos_max) != 0: - common_clos_max = min(rdt_res_clos_max) - else: - common_clos_max = 0 - if len(rdt_res) != 0 and common_clos_max !=0 and i in vm_info.clos_per_vm: + hv_info = scenario_items['hv'] + + if board_cfg_lib.is_rdt_supported() and hv_info.features.rdt_enabled == 'y': print("\t\t.clos = VM{}_VCPU_CLOS,".format(i), file=config) def get_guest_flag(flags): @@ -254,8 +251,9 @@ def gen_source_header(config): print("{0}".format(C_HEADER), file=config) -def gen_sos_vm(vm_type, vm_i, vm_info, config): +def gen_sos_vm(vm_type, vm_i, scenario_items, config): + vm_info = scenario_items['vm'] (err_dic, sos_guest_flags) = get_guest_flag(vm_info.guest_flags[vm_i]) if err_dic: return err_dic @@ -268,6 +266,7 @@ def gen_sos_vm(vm_type, vm_i, vm_info, config): "there is supposed to be the highest severity guest */", file=config) if sos_guest_flags: print("\t\t.guest_flags = {0},".format(sos_guest_flags), file=config) + clos_output(scenario_items, vm_i, config) cpu_affinity_output(vm_info, vm_i, config) print("\t\t.memory = {", file=config) print("\t\t\t.start_hpa = {}UL,".format(vm_info.mem_info.mem_start_hpa[vm_i]), file=config) @@ -291,8 +290,9 @@ def gen_sos_vm(vm_type, vm_i, vm_info, config): print("\t},", file=config) -def gen_pre_launch_vm(vm_type, vm_i, vm_info, config): +def gen_pre_launch_vm(vm_type, vm_i, scenario_items, config): + vm_info = scenario_items['vm'] # guest flags (err_dic, guest_flags) = get_guest_flag(vm_info.guest_flags[vm_i]) if err_dic: @@ -305,7 +305,7 @@ def gen_pre_launch_vm(vm_type, vm_i, vm_info, config): cpu_affinity_output(vm_info, vm_i, config) if guest_flags: print("\t\t.guest_flags = {0},".format(guest_flags), file=config) - clos_output(vm_info, vm_i, config) + clos_output(scenario_items, vm_i, config) print("\t\t.memory = {", file=config) print("\t\t\t.start_hpa = VM{0}_CONFIG_MEM_START_HPA,".format(vm_i), file=config) print("\t\t\t.size = VM{0}_CONFIG_MEM_SIZE,".format(vm_i), file=config) @@ -344,11 +344,13 @@ def gen_pre_launch_vm(vm_type, vm_i, vm_info, config): print("\t},", file=config) -def gen_post_launch_vm(vm_type, vm_i, vm_info, config): +def gen_post_launch_vm(vm_type, vm_i, scenario_items, config): + vm_info = scenario_items['vm'] post_vm_type = get_post_vm_type(vm_type, vm_i) print("\t{{\t/* VM{} */".format(vm_i), file=config) print("\t\t{},".format(post_vm_type), file=config) + clos_output(scenario_items, vm_i, config) cpu_affinity_output(vm_info, vm_i, config) is_need_epc(vm_info.epc_section, vm_i, config) # VUART @@ -368,12 +370,13 @@ def pre_launch_definiation(vm_info, config): "vm{}_pci_devs[{}];".format(vm_i, vm_info.cfg_pci.pci_dev_num[vm_i]), file=config) print("", file=config) -def generate_file(vm_info, config): +def generate_file(scenario_items, config): """ Start to generate vm_configurations.c :param config: it is a file pointer of board information for writing to """ err_dic = {} + vm_info = scenario_items['vm'] gen_source_header(config) for vm_i,pci_dev_num in vm_info.cfg_pci.pci_dev_num.items(): if pci_dev_num >= 2: @@ -384,11 +387,11 @@ def generate_file(vm_info, config): for vm_i, vm_type in common.VM_TYPES.items(): if "SOS_VM" == scenario_cfg_lib.VM_DB[vm_type]['load_type']: - gen_sos_vm(vm_type, vm_i, vm_info, config) + gen_sos_vm(vm_type, vm_i, scenario_items, config) elif "PRE_LAUNCHED_VM" == scenario_cfg_lib.VM_DB[vm_type]['load_type']: - gen_pre_launch_vm(vm_type, vm_i, vm_info, config) + gen_pre_launch_vm(vm_type, vm_i, scenario_items, config) elif "POST_LAUNCHED_VM" == scenario_cfg_lib.VM_DB[vm_type]['load_type']: - gen_post_launch_vm(vm_type, vm_i, vm_info, config) + gen_post_launch_vm(vm_type, vm_i, scenario_items, config) print("};", file=config) return err_dic diff --git a/misc/acrn-config/scenario_config/vm_configurations_h.py b/misc/acrn-config/scenario_config/vm_configurations_h.py index 204f76858..b28663749 100644 --- a/misc/acrn-config/scenario_config/vm_configurations_h.py +++ b/misc/acrn-config/scenario_config/vm_configurations_h.py @@ -37,24 +37,19 @@ def cpu_affinity_output(vm_info, i, config): print("#define VM{0}_CONFIG_CPU_AFFINITY\t\t{1}".format( i, cpu_bits['cpu_map']), file=config) -def clos_config_output(vm_info, i, config): +def clos_config_output(scenario_items, i, config): """ Output the macro vcpu affinity - :param vm_info: the data structure have all the xml items values + :param scenario_items: the data structure have all the xml items values :param i: the index of vm id :param config: file pointor to store the information """ - (rdt_res, rdt_res_clos_max, _) = board_cfg_lib.clos_info_parser(common.BOARD_INFO_FILE) - if len(rdt_res_clos_max) != 0: - common_clos_max = min(rdt_res_clos_max) - else: - common_clos_max = 0 + vm_info = scenario_items['vm'] + hv_info = scenario_items['hv'] - if common_clos_max == 0: - return - - clos_config = vm_info.get_clos_bitmap(i) - print("#define VM{0}_VCPU_CLOS\t\t{1}".format(i, clos_config['clos_map']), file=config) + if board_cfg_lib.is_rdt_supported() and hv_info.features.rdt_enabled == 'y': + clos_config = vm_info.get_clos_bitmap(i) + print("#define VM{0}_VCPU_CLOS\t\t{1}".format(i, clos_config['clos_map']), file=config) def scenario_vm_num(scenario_items, config): @@ -65,8 +60,9 @@ def scenario_vm_num(scenario_items, 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): +def gen_pre_launch_vm(scenario_items, config): + vm_info = scenario_items['vm'] vm_i = 0 for vm_type in common.VM_TYPES.values(): if "PRE_LAUNCHED_VM" != scenario_cfg_lib.VM_DB[vm_type]['load_type']: @@ -75,7 +71,7 @@ def gen_pre_launch_vm(vm_info, config): cpu_bits = vm_info.get_cpu_bitmap(vm_i) cpu_affinity_output(vm_info, vm_i, config) - clos_config_output(vm_info, vm_i, config) + clos_config_output(scenario_items, vm_i, config) print("#define VM{0}_CONFIG_MEM_START_HPA\t\t{1}UL".format( vm_i, vm_info.mem_info.mem_start_hpa[vm_i]), file=config) print("#define VM{0}_CONFIG_MEM_SIZE\t\t\t{1}UL".format( @@ -90,17 +86,18 @@ def gen_pre_launch_vm(vm_info, config): vm_i += 1 -def gen_post_launch_header(vm_info, config): +def gen_post_launch_header(scenario_items, config): vm_i = 0 + vm_info = scenario_items['vm'] for vm_type in common.VM_TYPES.values(): if "POST_LAUNCHED_VM" != scenario_cfg_lib.VM_DB[vm_type]['load_type']: vm_i += 1 continue cpu_affinity_output(vm_info, vm_i, config) - clos_config_output(vm_info, vm_i, config) + clos_config_output(scenario_items, vm_i, config) vm_i += 1 -def gen_sos_header(vm_info, config): +def gen_sos_header(scenario_items, config): if 'SOS_VM' not in common.VM_TYPES.values(): return @@ -109,12 +106,16 @@ def gen_sos_header(vm_info, config): print("\t\t\t\t\tSOS_CONSOLE\t\\", file=config) print("\t\t\t\t\tSOS_BOOTARGS_DIFF", file=config) + for vm_i,vm_type in common.VM_TYPES.items(): + if vm_type == 'SOS_VM': + clos_config_output(scenario_items, vm_i, config) -def gen_header_file(vm_info, config): - gen_post_launch_header(vm_info, config) - gen_pre_launch_vm(vm_info, config) - gen_sos_header(vm_info, config) +def gen_header_file(scenario_items, config): + + gen_pre_launch_vm(scenario_items, config) + gen_sos_header(scenario_items, config) + gen_post_launch_header(scenario_items, config) def get_dm_owned_guest_flag_mask(vm_info, config): @@ -149,6 +150,6 @@ def generate_file(scenario_items, config): scenario_vm_num(scenario_items, config) print("", file=config) - gen_header_file(vm_info, config) + gen_header_file(scenario_items, config) print("", file=config) print("{0}".format(VM_END_DEFINE), file=config) diff --git a/misc/acrn-config/xmls/config-xmls/apl-mrb/hybrid.xml b/misc/acrn-config/xmls/config-xmls/apl-mrb/hybrid.xml index c327388b3..9c45beb4b 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-mrb/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-mrb/hybrid.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -57,7 +65,7 @@ 3 - + 0 @@ -148,7 +156,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-mrb/industry.xml b/misc/acrn-config/xmls/config-xmls/apl-mrb/industry.xml index 7dc0558cb..ebfe3eb0b 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-mrb/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-mrb/industry.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + y + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -101,7 +109,7 @@ 1 - + 0 @@ -130,7 +138,8 @@ 2 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-mrb/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/apl-mrb/logical_partition.xml index 21b976f33..e9a566ba5 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-mrb/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-mrb/logical_partition.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -58,7 +66,8 @@ 0 2 - > + > + 0 0 @@ -108,7 +117,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-mrb/sdc.xml b/misc/acrn-config/xmls/config-xmls/apl-mrb/sdc.xml index e383b35a4..b0cc1fdfe 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-mrb/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-mrb/sdc.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -102,7 +110,8 @@ 1 2 - + + 0 0 @@ -124,12 +133,12 @@ KATA_VM - - 0 - 3 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-up2-n3350/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/apl-up2-n3350/logical_partition.xml index 442e74f11..76159f92f 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-up2-n3350/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-up2-n3350/logical_partition.xml @@ -14,6 +14,12 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + y n y @@ -58,7 +64,7 @@ 0 - + 0 @@ -107,7 +113,7 @@ 1 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-up2/hybrid.xml b/misc/acrn-config/xmls/config-xmls/apl-up2/hybrid.xml index fa3019b0b..da54d9cac 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-up2/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-up2/hybrid.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -57,7 +65,7 @@ 3 - + 0 @@ -148,7 +156,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-up2/industry.xml b/misc/acrn-config/xmls/config-xmls/apl-up2/industry.xml index 110ebd3b8..7b9869526 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-up2/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-up2/industry.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + y + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -55,7 +63,7 @@ 0 - 3 + 0 0 @@ -101,7 +109,7 @@ 1 - + 3 @@ -130,7 +138,7 @@ 2 3 - + 1 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-up2/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/apl-up2/logical_partition.xml index b0ba88217..fde7522aa 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-up2/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-up2/logical_partition.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -59,7 +67,8 @@ 0 2 - + + 0 0 @@ -109,7 +118,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/apl-up2/sdc.xml b/misc/acrn-config/xmls/config-xmls/apl-up2/sdc.xml index 222a23431..fc046638c 100644 --- a/misc/acrn-config/xmls/config-xmls/apl-up2/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/apl-up2/sdc.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -102,7 +110,8 @@ 1 2 - + + 0 0 @@ -124,12 +133,12 @@ KATA_VM - - 0 - 3 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/hybrid.xml b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/hybrid.xml index c880f5fa6..1cf7c7792 100644 --- a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/hybrid.xml @@ -14,6 +14,26 @@ y SCHED_BVT y + + n + n + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + y n y @@ -53,7 +73,7 @@ 3 - + 0 @@ -142,7 +162,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/industry.xml b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/industry.xml index fbd0e1832..795e9c28a 100644 --- a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/industry.xml @@ -14,6 +14,26 @@ y SCHED_BVT y + + y + n + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + y n y @@ -95,7 +115,7 @@ 1 - + 0 @@ -124,7 +144,8 @@ 2 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/logical_partition.xml index 8b348463e..1e2c3612e 100644 --- a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/logical_partition.xml @@ -14,6 +14,26 @@ y SCHED_BVT y + + n + n + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + y n y @@ -56,7 +76,8 @@ 0 2 - + + 0 0 @@ -107,7 +128,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/sdc.xml b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/sdc.xml index 877b1c9b2..b7914e6d9 100644 --- a/misc/acrn-config/xmls/config-xmls/ehl-crb-b/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/ehl-crb-b/sdc.xml @@ -14,6 +14,26 @@ y SCHED_BVT y + + n + n + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + 0xfff + y n y @@ -95,7 +115,7 @@ 1 - + 0 @@ -117,12 +137,12 @@ KATA_VM - - 0 - 1 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/generic/hybrid.xml b/misc/acrn-config/xmls/config-xmls/generic/hybrid.xml index 8caa31f01..e55fe32ef 100644 --- a/misc/acrn-config/xmls/config-xmls/generic/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/generic/hybrid.xml @@ -14,6 +14,11 @@ y SCHED_BVT y + + n + n + + y n y @@ -57,7 +62,7 @@ 3 - + 0 @@ -146,7 +151,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/generic/industry.xml b/misc/acrn-config/xmls/config-xmls/generic/industry.xml index f20bf6af5..0bd3e5544 100644 --- a/misc/acrn-config/xmls/config-xmls/generic/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/generic/industry.xml @@ -14,6 +14,11 @@ y SCHED_BVT y + + n + n + + y n y @@ -99,7 +104,7 @@ 1 - + 0 @@ -128,7 +133,8 @@ 2 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/generic/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/generic/logical_partition.xml index 856dbd69c..dd305aa16 100644 --- a/misc/acrn-config/xmls/config-xmls/generic/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/generic/logical_partition.xml @@ -14,6 +14,11 @@ y SCHED_BVT y + + n + n + + y n y @@ -60,7 +65,8 @@ 0 2 - + + 0 0 @@ -111,7 +117,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/generic/sdc.xml b/misc/acrn-config/xmls/config-xmls/generic/sdc.xml index da55c7195..44188cf01 100644 --- a/misc/acrn-config/xmls/config-xmls/generic/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/generic/sdc.xml @@ -14,6 +14,11 @@ y SCHED_BVT y + + n + n + + y n y @@ -99,7 +104,7 @@ 1 - + 0 @@ -121,12 +126,12 @@ KATA_VM - - 0 - 1 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc6cayh/hybrid.xml b/misc/acrn-config/xmls/config-xmls/nuc6cayh/hybrid.xml index 18529ea0e..84056c131 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc6cayh/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc6cayh/hybrid.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -57,7 +65,7 @@ 3 - + 0 @@ -147,7 +155,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc6cayh/industry.xml b/misc/acrn-config/xmls/config-xmls/nuc6cayh/industry.xml index be5339414..ab225d675 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc6cayh/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc6cayh/industry.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + y + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -101,7 +109,7 @@ 1 - + 0 @@ -130,7 +138,8 @@ 2 3 - + + 0 0 @@ -159,7 +168,8 @@ 0 1 - + + 0 0 @@ -188,7 +198,8 @@ 0 1 - + + 0 0 @@ -217,7 +228,8 @@ 0 1 - + + 0 0 @@ -246,7 +258,8 @@ 0 1 - + + 0 0 @@ -268,13 +281,14 @@ KATA_VM - - 0 - 0 1 + + 0 + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc6cayh/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/nuc6cayh/logical_partition.xml index 47873271d..0193a6119 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc6cayh/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc6cayh/logical_partition.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -59,7 +67,8 @@ 0 2 - + + 0 0 @@ -109,7 +118,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc6cayh/sdc.xml b/misc/acrn-config/xmls/config-xmls/nuc6cayh/sdc.xml index df3335037..8f327c53f 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc6cayh/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc6cayh/sdc.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -102,7 +110,8 @@ 1 2 - + + 0 0 @@ -124,12 +133,12 @@ KATA_VM - - 0 - 3 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/hybrid.xml b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/hybrid.xml index 56b25e677..b8427ef38 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/hybrid.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -57,7 +61,7 @@ 3 - + 0 @@ -147,7 +151,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/industry.xml b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/industry.xml index 76ed6940c..679df8deb 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/industry.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -101,7 +105,8 @@ 0 1 - + + 0 0 @@ -130,7 +135,8 @@ 2 3 - + + 0 0 @@ -159,7 +165,8 @@ 0 1 - + + 0 0 @@ -188,7 +195,8 @@ 0 1 - + + 0 0 @@ -217,7 +225,8 @@ 0 1 - + + 0 0 @@ -246,7 +255,8 @@ 0 1 - + + 0 0 @@ -268,13 +278,14 @@ KATA_VM - - 0 - 0 1 + + 0 + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/logical_partition.xml index 29710164c..3f4e189f9 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/logical_partition.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -59,7 +63,8 @@ 0 2 - + + 0 0 @@ -110,7 +115,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/sdc.xml b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/sdc.xml index e45b6d099..831ebd94c 100644 --- a/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/nuc7i7dnb/sdc.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -101,7 +105,8 @@ 1 2 - + + 0 0 @@ -123,12 +128,12 @@ KATA_VM - - 0 - 3 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/template/HV.xml b/misc/acrn-config/xmls/config-xmls/template/HV.xml index d88d741a1..8cd928cff 100644 --- a/misc/acrn-config/xmls/config-xmls/template/HV.xml +++ b/misc/acrn-config/xmls/config-xmls/template/HV.xml @@ -14,6 +14,11 @@ y SCHED_BVT y + + n + n + + y n y diff --git a/misc/acrn-config/xmls/config-xmls/template/KATA_VM.xml b/misc/acrn-config/xmls/config-xmls/template/KATA_VM.xml index d65d5676b..310e0c421 100644 --- a/misc/acrn-config/xmls/config-xmls/template/KATA_VM.xml +++ b/misc/acrn-config/xmls/config-xmls/template/KATA_VM.xml @@ -1,12 +1,12 @@ KATA_VM - - 0 - + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/template/POST_RT_VM.xml b/misc/acrn-config/xmls/config-xmls/template/POST_RT_VM.xml index 8cbf0a816..f2124c63e 100644 --- a/misc/acrn-config/xmls/config-xmls/template/POST_RT_VM.xml +++ b/misc/acrn-config/xmls/config-xmls/template/POST_RT_VM.xml @@ -7,7 +7,7 @@ - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/template/POST_STD_VM.xml b/misc/acrn-config/xmls/config-xmls/template/POST_STD_VM.xml index 166d10ad3..e573cb587 100644 --- a/misc/acrn-config/xmls/config-xmls/template/POST_STD_VM.xml +++ b/misc/acrn-config/xmls/config-xmls/template/POST_STD_VM.xml @@ -7,7 +7,7 @@ - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/template/PRE_STD_VM.xml b/misc/acrn-config/xmls/config-xmls/template/PRE_STD_VM.xml index 676c128ab..26fab8c13 100644 --- a/misc/acrn-config/xmls/config-xmls/template/PRE_STD_VM.xml +++ b/misc/acrn-config/xmls/config-xmls/template/PRE_STD_VM.xml @@ -8,7 +8,7 @@ - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/template/SAFETY_VM.xml b/misc/acrn-config/xmls/config-xmls/template/SAFETY_VM.xml index f577f7354..33b1c1029 100644 --- a/misc/acrn-config/xmls/config-xmls/template/SAFETY_VM.xml +++ b/misc/acrn-config/xmls/config-xmls/template/SAFETY_VM.xml @@ -8,7 +8,7 @@ - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/tgl-rvp/industry.xml b/misc/acrn-config/xmls/config-xmls/tgl-rvp/industry.xml index 3d40b818a..c5aa8ec43 100644 --- a/misc/acrn-config/xmls/config-xmls/tgl-rvp/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/tgl-rvp/industry.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -98,7 +102,7 @@ 1 - + 0 @@ -127,7 +131,8 @@ 2 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/hybrid.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/hybrid.xml index 742bfd85c..ee6ca760c 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/hybrid.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -57,7 +61,7 @@ 3 - + 0 @@ -147,7 +151,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/industry.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/industry.xml index 668f2ac24..5d3ac5bc2 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/industry.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -101,7 +105,8 @@ 0 1 - + + 0 0 @@ -130,7 +135,8 @@ 2 3 - + + 0 0 @@ -159,7 +165,8 @@ 0 1 - + + 0 0 @@ -188,7 +195,8 @@ 0 1 - + + 0 0 @@ -217,7 +225,8 @@ 0 1 - + + 0 0 @@ -246,7 +255,8 @@ 0 1 - + + 0 0 @@ -268,13 +278,14 @@ KATA_VM - - 0 - 0 1 + + 0 + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/logical_partition.xml index df60b9bbb..4e5b3f8ac 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/logical_partition.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -59,7 +63,8 @@ 0 2 - + + 0 0 @@ -109,7 +114,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/sdc.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/sdc.xml index 902548aa8..17baf9e08 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i5/sdc.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -101,7 +105,8 @@ 1 2 - + + 0 0 @@ -123,12 +128,12 @@ KATA_VM - - 0 - 3 + + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/hybrid.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/hybrid.xml index cdeaeee4b..0bbc80b3d 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/hybrid.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/hybrid.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -57,7 +61,7 @@ 3 - + 0 @@ -147,7 +151,7 @@ 2 - + 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/industry.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/industry.xml index 291dd00b5..6109b66d7 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/industry.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/industry.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -101,7 +105,8 @@ 0 1 - + + 0 0 @@ -130,7 +135,7 @@ 2 3 - + 0 @@ -159,7 +164,8 @@ 0 1 - + + 0 0 @@ -188,7 +194,8 @@ 0 1 - + + 0 0 @@ -217,7 +224,8 @@ 0 1 - + + 0 0 @@ -246,7 +254,8 @@ 0 1 - + + 0 0 @@ -268,13 +277,14 @@ KATA_VM - - 0 - 0 1 + + 0 + 0 + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/logical_partition.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/logical_partition.xml index 436eba565..45cddf167 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/logical_partition.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/logical_partition.xml @@ -14,6 +14,10 @@ y SCHED_BVT y + + n + n + y n y @@ -59,7 +63,8 @@ 0 2 - + + 0 0 @@ -109,7 +114,8 @@ 1 3 - + + 0 0 diff --git a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/sdc.xml b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/sdc.xml index 6b554ca31..10b75c0ab 100644 --- a/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/sdc.xml +++ b/misc/acrn-config/xmls/config-xmls/whl-ipc-i7/sdc.xml @@ -14,6 +14,14 @@ y SCHED_BVT y + + n + n + 0xff + 0xff + 0xff + 0xff + y n y @@ -101,7 +109,8 @@ 1 2 - + + 0 0 @@ -123,12 +132,12 @@ KATA_VM - - 0 - 3 + + 0 + 0 0