summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/cir_driver.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/cir_driver.c b/src/cir_driver.c
index 7e470bb..c6967da 100644
--- a/src/cir_driver.c
+++ b/src/cir_driver.c
@@ -256,6 +256,17 @@ CIRProbe(DriverPtr drv, int flags)
they should be handled in this driver (as opposed to their
own driver). */
pPci = xf86GetPciInfoForEntity(usedChips[i]);
+
+#ifdef XSERVER_LIBPCIACCESS
+ if (pci_device_has_kernel_driver(pPci)) {
+ xf86DrvMsg(0, X_ERROR,
+ "cirrus: The PCI device 0x%x at %2.2d@%2.2d:%2.2d:%1.1d has a kernel module claiming it.\n",
+ pPci->device_id, pPci->bus, pPci->domain, pPci->dev, pPci->func);
+ xf86DrvMsg(0, X_ERROR,
+ "cirrus: This driver cannot operate until it has been unloaded.\n");
+ return FALSE;
+ }
+#endif
pScrn = NULL;
if (pPci && (PCI_DEV_DEVICE_ID(pPci) == PCI_CHIP_GD5462 ||
PCI_DEV_DEVICE_ID(pPci) == PCI_CHIP_GD5464 ||