[PATCH v2 02/16] PCI: Replace magic number in setup_device()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



User PCI_BASE_ADDRESS_SPACE_IO instead of explicit magic number. No
functional change intended.

Signed-off-by: Andrey Smirnov <andrew.smirnov@xxxxxxxxx>
---
 drivers/pci/pci.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index 1f9d360d79..5e67750c39 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -182,7 +182,7 @@ static void setup_device(struct pci_dev *dev, int max_bar)
 			continue;
 		}
 
-		if (mask & 0x01) { /* IO */
+		if (mask & PCI_BASE_ADDRESS_SPACE_IO) { /* IO */
 			size = pci_size(orig, mask, 0xfffffffe);
 			if (!size) {
 				pr_debug("pbar%d bad IO mask\n", bar);
-- 
2.20.1


_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux