acrn-config: fix the wrong 'key' type returned to webUI

Fix the wrong 'key' type of error list returned to webUI for parsing.

 Tracked-On: #3913
Signed-off-by: Wei Liu <weix.w.liu@intel.com>
Acked-by: Victor Sun <victor.sun@intel.com>
This commit is contained in:
Wei Liu 2019-10-24 10:16:41 +08:00 committed by wenlingz
parent e7134585b6
commit d9f0d8dcf0
2 changed files with 10 additions and 10 deletions

View File

@ -425,7 +425,7 @@ def pt_devs_check(bdf_list, vpid_list, item):
if is_bdf_format(bdf_str):
continue
else:
key = "uos,id={},passthrough_devices,{}".format(i_cnt, item)
key = "uos:id={},passthrough_devices,{}".format(i_cnt, item)
ERR_LIST[key] = "Unkonw the BDF format of {} device".format(item)
i_cnt += 1
@ -435,7 +435,7 @@ def pt_devs_check(bdf_list, vpid_list, item):
if is_vpid_format(vpid_str):
continue
else:
key = "uos,id={},passthrough_devices,{}".format(i_cnt, item)
key = "uos:id={},passthrough_devices,{}".format(i_cnt, item)
ERR_LIST[key] = "Unkonw the Vendor:Product ID format of {} device".format(item)
i_cnt += 1
@ -448,7 +448,7 @@ def empty_err(i_cnt, item):
:param item: the item of tag from config xml
:return: None
"""
key = "uos,id={},{}".format(i_cnt, item)
key = "uos:id={},{}".format(i_cnt, item)
ERR_LIST[key] = "The parameter should not be empty"
@ -473,7 +473,7 @@ def args_aval_check(arg_list, item, avl_list):
continue
if arg_str not in avl_list:
key = "uos,id={},{}".format(i_cnt, item)
key = "uos:id={},{}".format(i_cnt, item)
ERR_LIST[key] = "The {} is invalidate".format(item)
i_cnt += 1
@ -532,7 +532,7 @@ def mem_size_check(arg_list, item):
mem_size_set = int(arg_str.strip())
if mem_size_set > total_mem_mb:
key = "uos,id={},{}".format(i_cnt, item)
key = "uos:id={},{}".format(i_cnt, item)
ERR_LIST[key] = "{}MB should be less than total memory {}MB".format(item)
i_cnt += 1

View File

@ -202,7 +202,7 @@ def check_board_private_info():
(err_dic, private_info) = get_board_private_info(SCENARIO_INFO_FILE)
if not private_info['rootfs'] and err_dic:
ERR_LIST['vm,id=0,boot_private,rootfs'] = "The board have to chose one rootfs partition"
ERR_LIST['vm:id=0,boot_private,rootfs'] = "The board have to chose one rootfs partition"
ERR_LIST.update(err_dic)
@ -718,14 +718,14 @@ def avl_vuart_ui_select(scenario_info):
vm_type = get_order_type_by_vmid(vm_i)
if vm_type == "SOS_VM":
key = "vm={},vuart=0,base".format(vm_i)
key = "vm={}:vuart=0,base".format(vm_i)
tmp_vuart[key] = ['SOS_COM1_BASE', 'INVALID_COM_BASE']
key = "vm={},vuart=1,base".format(vm_i)
key = "vm={}:vuart=1,base".format(vm_i)
tmp_vuart[key] = ['SOS_COM2_BASE', 'INVALID_COM_BASE']
else:
key = "vm={},vuart=0,base".format(vm_i)
key = "vm={}:vuart=0,base".format(vm_i)
tmp_vuart[key] = ['INVALID_COM_BASE', 'COM1_BASE']
key = "vm={},vuart=1,base".format(vm_i)
key = "vm={}:vuart=1,base".format(vm_i)
tmp_vuart[key] = ['INVALID_COM_BASE', 'COM2_BASE']
#print(tmp_vuart)