On 2021/1/24 23:22, Xueming(Steven) Li wrote:
+       } else if (flags & IORESOURCE_MEM) {
+               iobar = 0;
+               base = (unsigned long)dev->mem_resource[bar].addr;
+               RTE_LOG(INFO, EAL, "%s(): MMIO BAR %08lx detected\n",
__func__, base);
Same here, INFO level seems chatty.
makes sense. would remove it.

+       } else {
+               RTE_LOG(ERR, EAL, "%s(): unknown BAR type\n", __func__);
+               goto error;
+       }
+
+
+       if (iobar && rte_eal_iopl_init() != 0) {
+               RTE_LOG(ERR, EAL, "%s(): insufficient ioport permissions for
PCI device %s\n",
+                       __func__, dev->name);
                goto error;
        }
Same as Maxime's suggestion, please move this block as well.
Thanks. It is already moved in v6 patch.
-       base = (unsigned long)phys_addr;
-       RTE_LOG(INFO, EAL, "%s(): PIO BAR %08lx detected\n", __func__,
base);

-       if (base > UINT16_MAX)
+       if (iobar && (base > UINT16_MAX)) {
PIO_MAX defined below, please use it here. UNI16_MAX used in patch 1/3 as well.
ok.

Reply via email to