From vanmaren@vanmaren.aros.net  Sun Nov 29 11:01:49 1998
Received: from vanmaren.aros.net (vanmaren.aros.net [208.219.24.33])
          by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id LAA23568
          for <FreeBSD-gnats-submit@freebsd.org>; Sun, 29 Nov 1998 11:01:48 -0800 (PST)
          (envelope-from vanmaren@vanmaren.aros.net)
Received: (from vanmaren@localhost)
	by vanmaren.aros.net (8.9.1/8.9.1) id MAA29287;
	Sun, 29 Nov 1998 12:01:30 -0700 (MST)
	(envelope-from vanmaren)
Message-Id: <199811291901.MAA29287@vanmaren.aros.net>
Date: Sun, 29 Nov 1998 12:01:30 -0700 (MST)
From: vanmaren@aros.net
Reply-To: vanmaren@cs.utah.edu
To: FreeBSD-gnats-submit@freebsd.org
Subject: PCI devices without an associated driver are silently ignored
X-Send-Pr-Version: 3.2

>Number:         8898
>Category:       kern
>Synopsis:       PCI devices without an associated driver are silently ignored
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Nov 29 11:10:00 PST 1998
>Closed-Date:    Thu Jun 1 15:33:31 PDT 2000
>Last-Modified:  Thu Jun 01 15:34:26 PDT 2000
>Originator:     Kevin Van Maren
>Release:        FreeBSD 3.0-CURRENT i386
>Organization:
University of Utah
>Environment:

FreeBSD vanmaren.aros.net 3.0-CURRENT FreeBSD 3.0-CURRENT #4: Mon Nov  9 20:53:15 MST 1998     vanmaren@vanmaren.aros.net:/usr/src/sys/compile/VANMAREN  i386

>Description:

Unlike in 2.2, when 3.0 doesn't have a driver configured in for a PCI
device, no message is generated.  This can be the root of much confusion,
especially for users who have used 2.2 and expected the behavior to be
similar.

This change occured as a result of the PCI code modifications that have
yet not been completed.

>How-To-Repeat:

Boot a 3.0 kernel without support for one of the PCI devices in the system.
It looks like the device doesn't exist at all.

>Fix:

This is NOT the correct fix, but it is the quick and dirty way to
alert the user that the PCI device was found, but not attached to
any driver.  However, it is better than nothing until the PCI
code has been finished, and it should work as a temporary solution.

Index: pci_compat.c
===================================================================
RCS file: /usr/lsrc/FreeBSD/CVS/src/sys/pci/pci_compat.c,v
retrieving revision 1.13
diff -u -r1.13 pci_compat.c
--- pci_compat.c	1998-11-09 01:03:01-07	1.13
+++ pci_compat.c	1998-11-29 09:34:15-07
@@ -430,6 +430,14 @@
 
 		dinfo->conf.pd_unit = unit;
 
+	} else {
+		/*
+		 * XXX: quick hack so the user knows that the card
+		 * was found, but there was no driver configured for it.
+		 */
+		printf("No driver for device 0x%08lx at pci%d:%d:%d\n",
+			pci_cfgread(cfg, PCIR_DEVVENDOR, 4),
+			cfg->bus, cfg->slot, cfg->func);
 	}
 }
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: phk 
State-Changed-When: Thu Jun 1 15:33:31 PDT 2000 
State-Changed-Why:  
Overtaken by events.  I'm not sure that the current code does the 
right thing, but at least booting with -v will give you all the 
info you need.  pciconf(8) is also a solution. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=8898 
>Unformatted:
