[V1] framework/dut: Modify the format of eal parameter API output
Checks
Context |
Check |
Description |
ci/Intel-dts-suite-test |
success
|
Testing OK
|
Commit Message
- Remove blank from cores list
- Change validate rule of port to compatible with FreeBSD
- Modify file prefix generate rule to compatible with FreeBSD
Signed-off-by: Jun Dong <junx.dong@intel.com>
---
framework/dut.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
@@ -1386,7 +1386,7 @@ class _EalParameter(object):
or all(map(lambda _port: type(_port) == str, ports))
and all(
map(
- lambda _port: re.match(r"^([\d\w]+:){2}[\d\w]+\.[\d\w]+$", _port),
+ lambda _port: re.match(r"^([\d\w]+:){1,2}[\d\w]+\.[\d\w]+$", _port),
ports,
)
)
@@ -1446,7 +1446,7 @@ class _EalParameter(object):
)
return _formated_core_list
- return f'-l {", ".join(_get_consecutive_cores_range(core_list))}'
+ return f'-l {",".join(_get_consecutive_cores_range(core_list))}'
def _make_memory_channels(self) -> str:
param_template = "-n {}"
@@ -1499,7 +1499,6 @@ class _EalParameter(object):
if not self.fixed_prefix:
fixed_file_prefix = fixed_file_prefix + "_" + self.dut.prefix_subfix
fixed_file_prefix = self._do_os_handle_with_prefix_param(fixed_file_prefix)
- fixed_file_prefix = "--file-prefix=" + fixed_file_prefix
return fixed_file_prefix
def _make_vdevs_param(self) -> str:
@@ -1570,6 +1569,7 @@ class _EalParameter(object):
file_prefix = ""
else:
self.dut.prefix_list.append(file_prefix)
+ file_prefix = "--file-prefix=" + file_prefix
return file_prefix
def make_eal_param(self) -> str: