summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/proc.c9
-rw-r--r--lspci.c4
2 files changed, 9 insertions, 4 deletions
diff --git a/lib/proc.c b/lib/proc.c
index f5ae883..87b0631 100644
--- a/lib/proc.c
+++ b/lib/proc.c
@@ -1,5 +1,5 @@
/*
- * $Id: proc.c,v 1.1 1999/01/22 21:05:39 mj Exp $
+ * $Id: proc.c,v 1.2 1999/04/18 19:08:12 mj Exp $
*
* The PCI Library -- Configuration Access via /proc/bus/pci
*
@@ -107,7 +107,12 @@ proc_scan(struct pci_access *a)
struct pci_dev *d = pci_alloc_dev(a);
unsigned int dfn, vend;
- sscanf(buf, "%x %x %x %lx %lx %lx %lx %lx %lx %lx",
+ sscanf(buf,
+#ifdef HAVE_64BIT_ADDRESS
+ "%x %x %x %llx %llx %llx %llx %llx %llx %llx",
+#else
+ "%x %x %x %lx %lx %lx %lx %lx %lx %lx",
+#endif
&dfn,
&vend,
&d->irq,
diff --git a/lspci.c b/lspci.c
index 9c89da2..ab987cd 100644
--- a/lspci.c
+++ b/lspci.c
@@ -1,5 +1,5 @@
/*
- * $Id: lspci.c,v 1.23 1999/02/28 20:23:07 mj Exp $
+ * $Id: lspci.c,v 1.24 1999/04/18 19:07:16 mj Exp $
*
* Linux PCI Utilities -- List All PCI Devices
*
@@ -292,7 +292,7 @@ show_bases(struct device *d, int cnt)
if (buscentric_view)
{
if (a || z)
- printf("%08x%08lx", z, a);
+ printf("%08x" ADDR_FORMAT, z, a);
else
printf("<unassigned>");
done = 1;