* [PATCH v1] dts: automate VFIO-PCI modprobe
@ 2025-11-21 21:06 Andrew Bailey
2025-11-21 21:08 ` Patrick Robb
2025-11-26 14:16 ` [PATCH v2] " Andrew Bailey
0 siblings, 2 replies; 3+ messages in thread
From: Andrew Bailey @ 2025-11-21 21:06 UTC (permalink / raw)
To: probb; +Cc: abailey, dev, dmarx, luca.vizzarro
Currently, users must modprobe vfio-pci before running DTS when using a
non-mellanox NIC. This patch automates the process on test run start up.
Signed-off-by: Andrew Bailey <abailey@iol.unh.edu>
---
dts/framework/test_run.py | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/dts/framework/test_run.py b/dts/framework/test_run.py
index ff0a12c9ce..38f9e6c07d 100644
--- a/dts/framework/test_run.py
+++ b/dts/framework/test_run.py
@@ -347,6 +347,10 @@ def next(self) -> State | None:
test_run.ctx.dpdk.setup()
test_run.ctx.topology.setup()
+ if test_run.ctx.sut_node.ports[0].config.os_driver_for_dpdk == "vfio-pci":
+ test_run.ctx.sut_node.main_session.send_command("modprobe vfio")
+ test_run.ctx.sut_node.main_session.send_command("modprobe vfio-pci")
+
if test_run.config.use_virtual_functions:
test_run.ctx.topology.instantiate_vf_ports()
--
2.50.1
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH v1] dts: automate VFIO-PCI modprobe
2025-11-21 21:06 [PATCH v1] dts: automate VFIO-PCI modprobe Andrew Bailey
@ 2025-11-21 21:08 ` Patrick Robb
2025-11-26 14:16 ` [PATCH v2] " Andrew Bailey
1 sibling, 0 replies; 3+ messages in thread
From: Patrick Robb @ 2025-11-21 21:08 UTC (permalink / raw)
To: Andrew Bailey; +Cc: dev, dmarx, luca.vizzarro
[-- Attachment #1: Type: text/plain, Size: 1222 bytes --]
I think there is a missing check for if ports is None (user is not
providing ports, trying to only run NO_LINKS tests).
On Fri, Nov 21, 2025 at 4:06 PM Andrew Bailey <abailey@iol.unh.edu> wrote:
> Currently, users must modprobe vfio-pci before running DTS when using a
> non-mellanox NIC. This patch automates the process on test run start up.
>
> Signed-off-by: Andrew Bailey <abailey@iol.unh.edu>
> ---
> dts/framework/test_run.py | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/dts/framework/test_run.py b/dts/framework/test_run.py
> index ff0a12c9ce..38f9e6c07d 100644
> --- a/dts/framework/test_run.py
> +++ b/dts/framework/test_run.py
> @@ -347,6 +347,10 @@ def next(self) -> State | None:
> test_run.ctx.dpdk.setup()
> test_run.ctx.topology.setup()
>
> + if test_run.ctx.sut_node.ports[0].config.os_driver_for_dpdk ==
> "vfio-pci":
> + test_run.ctx.sut_node.main_session.send_command("modprobe
> vfio")
> + test_run.ctx.sut_node.main_session.send_command("modprobe
> vfio-pci")
> +
> if test_run.config.use_virtual_functions:
> test_run.ctx.topology.instantiate_vf_ports()
>
> --
> 2.50.1
>
>
[-- Attachment #2: Type: text/html, Size: 1700 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread* [PATCH v2] dts: automate VFIO-PCI modprobe
2025-11-21 21:06 [PATCH v1] dts: automate VFIO-PCI modprobe Andrew Bailey
2025-11-21 21:08 ` Patrick Robb
@ 2025-11-26 14:16 ` Andrew Bailey
1 sibling, 0 replies; 3+ messages in thread
From: Andrew Bailey @ 2025-11-26 14:16 UTC (permalink / raw)
To: probb; +Cc: dev, dmarx, luca.vizzarro, Andrew Bailey
Currently, users must modprobe vfio-pci before running DTS when using a
non-mellanox NIC. This patch automates the process on test run start up.
Signed-off-by: Andrew Bailey <abailey@iol.unh.edu>
---
dts/framework/test_run.py | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/dts/framework/test_run.py b/dts/framework/test_run.py
index ff0a12c9ce..9d7b6271c7 100644
--- a/dts/framework/test_run.py
+++ b/dts/framework/test_run.py
@@ -106,6 +106,7 @@
from types import MethodType
from typing import ClassVar, Protocol, Union
+from api.capabilities import LinkTopology
from framework.config.test_run import TestRunConfiguration
from framework.context import Context, init_ctx
from framework.exception import InternalError, SkippedTestException, TestCaseVerifyError
@@ -347,6 +348,13 @@ def next(self) -> State | None:
test_run.ctx.dpdk.setup()
test_run.ctx.topology.setup()
+ if (
+ test_run.ctx.topology.type != LinkTopology.NO_LINK
+ and test_run.ctx.sut_node.ports[0].config.os_driver_for_dpdk == "vfio-pci"
+ ):
+ test_run.ctx.sut_node.main_session.send_command("modprobe vfio")
+ test_run.ctx.sut_node.main_session.send_command("modprobe vfio-pci")
+
if test_run.config.use_virtual_functions:
test_run.ctx.topology.instantiate_vf_ports()
--
2.50.1
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2025-11-26 14:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-11-21 21:06 [PATCH v1] dts: automate VFIO-PCI modprobe Andrew Bailey
2025-11-21 21:08 ` Patrick Robb
2025-11-26 14:16 ` [PATCH v2] " Andrew Bailey
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).