vfio: improve musl compatibility
authorAnatoly Burakov <anatoly.burakov@intel.com>
Thu, 4 Oct 2018 10:20:34 +0000 (11:20 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Mon, 22 Oct 2018 09:28:35 +0000 (11:28 +0200)
Musl already has PAGE_SIZE defined, and our define clashed with it.
Rename our define to SYS_PAGE_SIZE.

Bugzilla ID: 36

Signed-off-by: Anatoly Burakov <anatoly.burakov@intel.com>
Acked-by: Bruce Richardson <bruce.richardson@intel.com>
drivers/bus/pci/linux/pci_vfio.c

index cc2387e..b1f0683 100644 (file)
@@ -37,7 +37,9 @@
 
 #ifdef VFIO_PRESENT
 
+#ifndef PAGE_SIZE
 #define PAGE_SIZE   (sysconf(_SC_PAGESIZE))
+#endif
 #define PAGE_MASK   (~(PAGE_SIZE - 1))
 
 static struct rte_tailq_elem rte_vfio_tailq = {