Hi, Today, as far as I can see (at least for linux generic), the type of pktio selected at open time depends on: 1) the priority order defined in pktio_io/io_ops.c (currentely: netmap mmap socket and usual sockets) 2)A set of environment variable (ODP_PKTIO_DISABLE_NETMAP, ODP_PKTIO_DISABLE_SOCKET_MMAP...) from which the order defined in 1) can be changed... 3)Some mechanism taking the device name as a hint (looback, pcap...)
I am not sure I really understand why this is done so, and how these mechanism can be extented: I can see a future in which a odp application will need to talk (read send and receive packet) to different type of pktio at the same time. Possibly one to the linux jernel (Ravineet's work), some normal sockets (possibly netmapped) and some NICs (possibly many) -my problem-.... and surely some more to come. Aren't we missing a proper pktio selection mechanism? Can/Should the application be really pktio-type (un)aware?. A first hack could be having a dev name like: "NIC:<pci_address>" to start a PMD driver on the nic at that address, but by choosing specific dev name the application becomes well aware of the pktio devices anyway.... The underlying question is also whether ODP should be performing PCI enumeration and how NIC should be selected... Christophe.
_______________________________________________ lng-odp mailing list [email protected] https://lists.linaro.org/mailman/listinfo/lng-odp
