Zero could be a legitimate address inn PIO address space. Thus, marking unimplemented BARs using zero is a bad idea. Use INVALID_PHYS_ADDR instead. Cc: Thomas Huth <thuth@xxxxxxxxxx> Cc: Andrew Jones <drjones@xxxxxxxxxx> Signed-off-by: Alexander Gordeev <agordeev@xxxxxxxxxx> --- lib/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pci.c b/lib/pci.c index 62b1c6b0b7c5..28ef5781a07a 100644 --- a/lib/pci.c +++ b/lib/pci.c @@ -336,7 +336,7 @@ void pci_scan_bars(struct pci_dev *dev) dev->resource[i] = pci_bar_get_addr(dev, i); if (pci_bar_is64(dev, i)) { i++; - dev->resource[i] = (phys_addr_t)0; + dev->resource[i] = INVALID_PHYS_ADDR; } } } -- 1.8.3.1