Subject: port-i386/330: sbreg.h does not DTRT with SoundBlaster Pro
To: None <gnats-admin>
From: Jason R. Thorpe <thorpej@yuri.CS.ORST.EDU>
List: netbsd-bugs
Date: 07/07/1994 14:05:20
>Number: 330
>Category: port-i386
>Synopsis: sbreg.h does not DTRT with SoundBlaster Pro
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: gnats-admin (GNATS administrator)
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Jul 7 14:05:09 1994
>Originator: Jason R. Thorpe
>Organization:
Oregon State University
Department of Computer Science
>Release: NetBSD 0.9C (Jul 5 source)
>Environment:
System: NetBSD yuri 0.9C NetBSD 0.9C (YURI) #1: Thu Jul 7 13:04:05 PDT 1994 thorpej@yuri:/tmp_mnt/hurricane/NetBSD/src/sys/arch/i386/compile/YURI i386
>Description:
The macro to check for valid IRQs on the SoundBlaster does not
check for the right ones on a SoundBlaster Pro. This does not
manifest itself unless you're running out of IRQs and need to use
one that's not supported by the current driver.
>How-To-Repeat:
Put your SoundBlaster Pro on IRQ 10 and watch your kernel tell
you that IRQ 10 is invalid.
>Fix:
I have used the following patch to /sys/arch/i386/isa/sbreg.h
for close to 4 months now...I've just finally gotten around to
doing the send-pr :-)
This particular patch is based on the following version of
sbreg.h:
$Id: sbreg.h,v 1.2 1994/03/29 04:36:28 mycroft Exp $
NOTE: The patch requires that you put the following in your
kernel config file:
options SBPRO
*** distribution/sbreg.h Mon Jun 20 22:41:22 1994
--- sbreg.h Mon Jun 20 22:41:41 1994
***************
*** 139,146 ****
--- 139,151 ----
/*
* Macros to detect valid hardware configuration data.
*/
+ #ifdef SBPRO
+ #define SB_IRQ_VALID(mask) ((mask) & 0x04a4) /* IRQ 2,5,7,10 */
+ #define SB_DRQ_VALID(chan) (((chan) == 0) || ((chan) == 1) || ((chan) == 3))
+ #else /* ! SBPRO */
#define SB_IRQ_VALID(mask) ((mask) & 0x00ac) /* IRQ 2,3,5,7 */
#define SB_DRQ_VALID(chan) ((chan) == 1)
+ #endif /* SBPRO */
#define SB_BASE_VALID(base) ((base) == 0x220 || (base) == 0x240)
#define SB_INPUT_RATE 0
>Audit-Trail:
>Unformatted:
------------------------------------------------------------------------------