summaryrefslogtreecommitdiff
path: root/src/ast_driver.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ast_driver.c')
-rw-r--r--src/ast_driver.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/ast_driver.c b/src/ast_driver.c
index 67d6f78..7c0095f 100644
--- a/src/ast_driver.c
+++ b/src/ast_driver.c
@@ -295,6 +295,21 @@ ASTProbe(DriverPtr drv, int flags)
for (i = 0; i < numUsed; i++) {
ScrnInfoPtr pScrn = NULL;
+#ifdef XSERVER_LIBPCIACCESS
+ {
+ struct pci_device *pPci = xf86GetPciInfoForEntity(usedChips[i]);
+
+ if (pci_device_has_kernel_driver(pPci)) {
+ xf86DrvMsg(0, X_ERROR,
+ "ast: 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
+
/* Allocate new ScrnInfoRec and claim the slot */
if ((pScrn = xf86ConfigPciEntity(pScrn, 0, usedChips[i],
ASTPciChipsets, 0, 0, 0, 0, 0)))