[PATCH 3/3] net/ionic: add vdev support for embedded applications
Boyer, Andrew
Andrew.Boyer at amd.com
Mon Feb 19 23:02:22 CET 2024
On Feb 19, 2024, at 10:24 AM, Yigit, Ferruh <Ferruh.Yigit at amd.com> wrote:
On 2/16/2024 5:07 PM, Andrew Boyer wrote:
Add support for running DPDK applications directly on AMD Pensando
embedded HW. The platform exposes the device BARs through UIO. The
UIO code in the common/ionic library walks the sysfs filesystem
to identify the relevant BARs and map them into process memory.
The SoCs are named 'Capri' and 'Elba'.
The vdev device interface code is located in ionic_dev_vdev.c.
Some datapath operations are #ifdef-ed out to save on resources when
running in embedded mode.
Some controlpath operations are skipped by the ionic_is_embedded()
helper function.
Before ringing the doorbell, use an ARM 'dsb st' barrier. The normal
barrier inside rte_write64() is insufficient on these devices due to
a chip errata.
Signed-off-by: Andrew Boyer <andrew.boyer at amd.com>
Signed-off-by: Neel Patel <neel.patel at amd.com>
Signed-off-by: R Mohamed Shah <mohamedshah.r at amd.com>
Signed-off-by: Alfredo Cardigliano <cardigliano at ntop.org>
<...>
+static struct rte_vdev_driver rte_vdev_ionic_pmd = {
+ .probe = eth_ionic_vdev_probe,
+ .remove = eth_ionic_vdev_remove,
+};
+
+RTE_PMD_REGISTER_VDEV(net_ionic, rte_vdev_ionic_pmd);
+
+static void
+vdev_ionic_scan_cb(__rte_unused void *arg)
+{
+ ionic_uio_scan_mnet_devices();
+}
+
+RTE_INIT(vdev_ionic_custom_add)
+{
+ rte_vdev_add_custom_scan(vdev_ionic_scan_cb, NULL);
+}
Hi Andrew,
My understanding is 'rte_vdev_add_custom_scan()' to add a vdev
automatically (via rte_devargs_add()) before vdev scan starts.
As far as I can see you are not doing this, why callback is added?
Why not call 'ionic_uio_scan_mnet_devices()' within the
'eth_ionic_vdev_probe()'?
I think you are correct and our scan should be restricted to the vdev_probe function. Otherwise it will run in all cases, even on irrelevant hardware.
Thanks!
Andrew
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mails.dpdk.org/archives/dev/attachments/20240219/2b7f10a5/attachment.htm>
More information about the dev
mailing list