NetBSD Problem Report #10025

Received: (qmail 24065 invoked from network); 1 May 2000 12:39:37 -0000
Message-Id: <20000501124330.12430.qmail@mailhost.dave.dtsp.co.nz>
Date: 1 May 2000 12:43:30 -0000
From: dave@dtsp.co.nz
Reply-To: dave@dtsp.co.nz
To: gnats-bugs@gnats.netbsd.org
Cc: dave@dtsp.co.nz
Subject: pciide should display revision ID's like most drivers
X-Send-Pr-Version: 3.95

>Number:         10025
>Category:       kern
>Synopsis:       pciide should display revision ID's like most drivers
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    kern-bug-people
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon May 01 12:40:00 +0000 2000
>Closed-Date:    Fri May 12 17:52:21 +0000 2000
>Last-Modified:  Fri May 12 17:52:21 +0000 2000
>Originator:     Dave Sainty
>Release:        Recent NetBSD-current
>Organization:
Dynamic Technology Services and Products Ltd (NZ)
>Environment:
System: NetBSD tequila.dave.dtsp.co.nz 1.4R NetBSD 1.4R (TEQUILA) #3: Wed Feb 16 20:01:31 NZDT 2000 dave@tequila.dave.dtsp.co.nz:/vol/tequila/userB/u2/NetBSD-current/src/sys/arch/i386/compile/TEQUILA i386


>Description:
	The pciide driver does not display the PCI function revision if the
	device is recognised.  This can be a nuisance if you want to know
	it...

>How-To-Repeat:
	Boot a machine with a PCI IDE interface.
>Fix:

--- src/sys/dev/pci/pciide.c.orig	Sun Apr  2 10:40:25 2000
+++ src/sys/dev/pci/pciide.c	Tue May  2 00:27:13 2000
@@ -463,16 +463,18 @@
 	struct pciide_softc *sc = (struct pciide_softc *)self;
 	pcireg_t csr;
 	char devinfo[256];
+	const char *displaydev;

 	sc->sc_pp = pciide_lookup_product(pa->pa_id);
 	if (sc->sc_pp == NULL) {
 		sc->sc_pp = &default_product_desc;
 		pci_devinfo(pa->pa_id, pa->pa_class, 0, devinfo);
-		printf(": %s (rev. 0x%02x)\n", devinfo,
-		    PCI_REVISION(pa->pa_class));
-	} else {
-		printf(": %s\n", sc->sc_pp->ide_name);
-	}
+		displaydev = devinfo;
+	} else
+		displaydev = sc->sc_pp->ide_name;
+
+	printf(": %s (rev. 0x%02x)\n", displaydev, PCI_REVISION(pa->pa_class));
+
 	sc->sc_pc = pa->pa_pc;
 	sc->sc_tag = pa->pa_tag;
 #ifdef WDCDEBUG

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: thorpej 
State-Changed-When: Fri May 12 10:52:13 PDT 2000 
State-Changed-Why:  
Done, thanks! 
>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.