Subject: port-i386/860: kernel will not link with ProAudio Spectrum driver specified
To: None <gnats-admin@NetBSD.ORG>
From: John F. Woods <jfw@jfwhome.funhouse.com>
List: netbsd-bugs
Date: 03/11/1995 08:05:20
>Number: 860
>Category: port-i386
>Synopsis: kernel will not link with ProAudio Spectrum driver specified
>Confidential: no
>Severity: critical
>Priority: low
>Responsible: gnats-admin (GNATS administrator)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Mar 11 08:05:17 1995
>Originator: John F. Woods
>Organization:
Misanthropes-R-Us
>Release: March 9. 1995
>Environment:
486/33 ISA
NetBSD-current
System: NetBSD jfwhome.funhouse.com 1.0A NetBSD 1.0A (JFW) #10: Fri Mar 3 22:38:25 EST 1995 jfw@jfwhome.funhouse.com:/usr/src/sys/arch/i386/compile/JFW i386
>Description:
If you config a kernel with "pas0" specified instead of "sb0", the
link will fail, with sbdsp.o referring to an undefined symbol
"sb_device". sbdsp.c believes it should initialize the Sound Blaster
driver's version string for it; sb.c ought to take that responsibility.
>How-To-Repeat:
See above.
>Fix:
Apply the following patch, which moves that initialization out of
sbdsp.c and into sb.c, analogous to pas.c:
*** sb.c.orig Sat Mar 11 10:54:14 1995
--- sb.c Sat Mar 11 10:54:57 1995
***************
*** 284,289 ****
--- 284,292 ----
sbdsp_attach(&sc->sc_sbdsp);
+ sprintf(sb_device.version, "%d.%d",
+ SBVER_MAJOR(sc->sc_model), SBVER_MINOR(sc->sc_model));
+
if (audio_hardware_attach(&sb_hw_if, (caddr_t)&sc->sc_sbdsp) != 0)
printf("sb: could not attach to audio pseudo-device driver\n");
}
*** sbdsp.c.orig Sat Mar 11 10:53:49 1995
--- sbdsp.c Sat Mar 11 10:55:08 1995
***************
*** 87,94 ****
int wmidi;
} sberr;
- extern struct audio_device sb_device;
-
#ifdef DEBUG
void
sb_printsc(struct sbdsp_softc *sc)
--- 87,92 ----
***************
*** 192,199 ****
}
printf(": dsp v%d.%d\n",
SBVER_MAJOR(sc->sc_model), SBVER_MINOR(sc->sc_model));
- sprintf(sb_device.version, "%d.%d",
- SBVER_MAJOR(sc->sc_model), SBVER_MINOR(sc->sc_model));
}
/*
--- 190,195 ----
>Audit-Trail:
>Unformatted: