Skip to content

Commit 6572cb6

Browse files
committed
Fix version and installation criteria in testpmd
1 parent c4f52f8 commit 6572cb6

File tree

4 files changed

+9
-7
lines changed

4 files changed

+9
-7
lines changed

microsoft/testsuites/dpdk/common.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ def _should_install(
241241
# At the moment, we use create() to force re-initialization.
242242
# If we ever fix things so that we use .get,
243243
# we will need this check. So add it now.q
244-
or (required_arch != self._arch)
244+
or (self._arch and required_arch != self._arch)
245245
or (
246246
required_version is not None
247247
and required_version > self.get_installed_version()

microsoft/testsuites/dpdk/dpdktestpmd.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -898,7 +898,7 @@ def _install(self) -> bool:
898898
):
899899
raise SkippedException("MANA DPDK test is not supported on this OS")
900900

901-
self.installer.do_installation()
901+
self.installer.do_installation(required_arch=self._build_arch)
902902
self._dpdk_version_info = self.installer.get_installed_version()
903903
self._load_drivers_for_dpdk()
904904
self.find_testpmd_binary(check_path=self._expected_install_path)

microsoft/testsuites/dpdk/dpdkutil.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
)
6363
from microsoft.testsuites.dpdk.dpdktestpmd import PACKAGE_MANAGER_SOURCE, DpdkTestpmd
6464
from microsoft.testsuites.dpdk.rdmacore import (
65-
RDMA_CORE_I386_DEFAULT_SOURCE,
65+
RDMA_CORE_I386_MANA_DEFAULT_SOURCE,
6666
RDMA_CORE_MANA_DEFAULT_SOURCE,
6767
RDMA_CORE_PACKAGE_DEPENDENCIES,
6868
RDMA_CORE_SOURCE_DEPENDENCIES,
@@ -138,8 +138,7 @@ def get_rdma_core_installer(
138138
# set rdma-core installer type.
139139
if not build_arch:
140140
build_arch = node.tools[Lscpu].get_architecture()
141-
if build_arch == CpuArchitecture.I386 and not rdma_source:
142-
rdma_source = RDMA_CORE_I386_DEFAULT_SOURCE
141+
143142
if rdma_source:
144143
if is_url_for_git_repo(rdma_source):
145144
# else, if we have a user provided rdma-core source, use it
@@ -153,7 +152,10 @@ def get_rdma_core_installer(
153152
)
154153
# handle MANA special case, build a default rdma-core with mana provider
155154
elif not rdma_source and node.nics.is_mana_device_present():
156-
downloader = TarDownloader(node, RDMA_CORE_MANA_DEFAULT_SOURCE)
155+
if build_arch == CpuArchitecture.I386:
156+
downloader = TarDownloader(node, RDMA_CORE_I386_MANA_DEFAULT_SOURCE)
157+
else:
158+
downloader = TarDownloader(node, RDMA_CORE_MANA_DEFAULT_SOURCE)
157159
else:
158160
# no rdma_source and not mana, just use the package manager
159161
return RdmaCorePackageManagerInstall(

microsoft/testsuites/dpdk/rdmacore.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
"https://github.com/linux-rdma/rdma-core/"
1919
"releases/download/v50.1/rdma-core-50.1.tar.gz"
2020
)
21-
RDMA_CORE_I386_DEFAULT_SOURCE = (
21+
RDMA_CORE_I386_MANA_DEFAULT_SOURCE = (
2222
"https://github.com/linux-rdma/rdma-core/"
2323
"releases/download/v53.1/rdma-core-53.1.tar.gz"
2424
)

0 commit comments

Comments
 (0)