On Fri, 10 Apr 2026 at 16:35, Morten Brørup <[email protected]> wrote:
>
> Is there a workaround until this patch is added, if I don't want 
> rte_eal_init() to probe any devices, but I want my application to probe 
> devices later by calling rte_bus_scan() followed by rte_bus_probe()?
>
> It's not something we really need, so if you don't know it off the top of 
> your head, don't spend time trying to figure it out.

Well, starting from the well known -a pci:0000:00:00.0 trick, I wrote
an incomplete workaround implemented for OVS.
https://patchwork.ozlabs.org/project/openvswitch/patch/[email protected]/

Incomplete, because some buses make life harder with some additional
parsing restraints (bus/dpaa is the first one that comes to mind) or
requiring a driver handling the device exists (bus/platform which has
*no* in-tree driver, though this is a different story..).

+    if (!args_contains(&args, "-a") && !args_contains(&args, "-b")
+        && !smap_get_bool(ovs_other_config, "dpdk-probe-at-init", false)) {
+#ifdef RTE_BUS_AUXILIARY
+        svec_add(&args, "-a");
+        svec_add(&args, "auxiliary:");
+#endif
+#ifdef RTE_BUS_CDX
+        svec_add(&args, "-a");
+        svec_add(&args, "cdx:cdx-");
+#endif
+#ifdef RTE_BUS_FSLMC
+        svec_add(&args, "-a");
+        svec_add(&args, "fslmc:dpni.65535");
+#endif
+#ifdef RTE_BUS_PCI
+        svec_add(&args, "-a");
+        svec_add(&args, "pci:0000:00:00.0");
+#endif
+#ifdef RTE_BUS_UACCE
+        svec_add(&args, "-a");
+        svec_add(&args, "uacce:");
+#endif
+#ifdef RTE_BUS_VMBUS
+        svec_add(&args, "-a");
+        svec_add(&args, "vmbus:00000000-0000-0000-0000-000000000000");
+#endif
+    }
+


-- 
David Marchand

Reply via email to