hi, shaopeng

On 7/6/2018 11:17 PM, He, Shaopeng wrote:
-----Original Message-----
From: Guo, Jia
Sent: Thursday, July 5, 2018 3:39 PM

[...]
+       switch (pdev->kdrv) {
+       case RTE_KDRV_IGB_UIO:
+       case RTE_KDRV_UIO_GENERIC:
+       case RTE_KDRV_NIC_UIO:
+               /* mmio resources is invalid, remap it to be safe. */
Better to keep consistent as: mmio resource is

ok.

[...]

Is it helpful that pci_uio_remap_resource could also remap UIO event and 
control fd?
So, up-layer application will be easier to deal with the un-plug event.

The fd remove should be after the device be closed, since it will still use the fd to close the interrupt when uninitialized driver, and removing fd is go on to let the pci_uio_unmap_resource to do it when device detach.

+/* remap the PCI resource of a PCI device in anonymous virtual memory */
+int
+pci_uio_remap_resource(struct rte_pci_device *dev)
+{
+       int i;
+       void *map_address;
Acked-by: Shaopeng He <shaopeng...@intel.com>


Reply via email to