[PATCH] xf86-video-geode: fix GPIO BAR detection with libpciaccess

Andres Salomon dilinger at queued.net
Fri May 22 14:30:21 PDT 2009


From: Otavio Salvador <otavio at ossystems.com.br>

This patch fixes an issue with the GPIO BAR detection.  Basically,
with libpciaccess we're finding the ISA device and checking its BARs,
but we're not bothering to fill in the BAR information via
pci_device_probe.  This results in a 0'd out bar and:

(EE) GEODE(0): Could not find the GPIO I/O base

Signed-off-by: Otavio Salvador <otavio at ossystems.com.br>
Signed-off-by: Andres Salomon <dilinger at collabora.co.uk>
---
 src/geode_ddc.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/src/geode_ddc.c b/src/geode_ddc.c
index 2533488..086dbb1 100644
--- a/src/geode_ddc.c
+++ b/src/geode_ddc.c
@@ -72,6 +72,9 @@ geode_gpio_iobase(void)
     if (pci == NULL)
 	return 0;
 
+    if (pci_device_probe(pci) != 0)
+        return 0;
+
     /* The GPIO I/O address is in resource 1 */
     return (unsigned short)pci->regions[1].base_addr;
 #else
-- 
1.6.3.1.54.g99dd




More information about the xorg mailing list