Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 15 Sep 1998 09:15:06 -0500
From:      Kris Kirby <kris@airnet.net>
To:        freebsd-multimedia@FreeBSD.ORG
Subject:   VoxWare 3.0, MediaVision Jazz16 Problems.
Message-ID:  <35FE766A.68EC8467@airnet.net>

next in thread | raw e-mail | index | archive | help
After just a touch of hacking, I finally got my sound card to work. The
required work was to #define JAZZ_DMA16 in sound_config.h, per the SB
routine:

#ifndef JAZZ_DMA16
#define JAZZ_DMA16      5
#endif                    

I also found that I needed to edit the Makefile for my kernel (in the
kernel compile directory) and add "-DJAZZ16" to the IDENT line. For some
reason, #options JAZZ16 produced a syntax error when interpreted by
config(8). At this point, I had a working kernel, and a kernel that
finally supported 16-bit sound for my sound card. Yay! But all was not
hunky-dory.

It seems that for whatever reason, the kernel doesn't want to let go of
the DMA channel.

%uname -a
FreeBSD ninbox.ml.org 2.2.7-RELEASE FreeBSD 2.2.7-RELEASE #0: Tue Sep 15
06:45:15 CDT 1998     kris@ninbox.ml.org:/usr/src/sys/compile/NINBOX 
i386

%cat /dev/sndstat
cat: /dev/sndstat: Device busy

%dmesg (after one working use, one failed)
Copyright (c) 1992-1998 FreeBSD Inc.
Copyright (c) 1982, 1986, 1989, 1991, 1993
        The Regents of the University of California.  All rights
reserved.

FreeBSD 2.2.7-RELEASE #0: Tue Sep 15 06:45:15 CDT 1998
    kris@ninbox.ml.org:/usr/src/sys/compile/NINBOX
Calibrating clock(s) ... i586 clock: 75181347 Hz, i8254 clock: 1193364
Hz
Press a key on the console to abort clock calibration
Calibrating clock(s) ... i586 clock: 75181238 Hz, i8254 clock: 1193360
Hz
Calibrating clock(s) ... i586 clock: 75181644 Hz, i8254 clock: 1193366
Hz
CPU: AMD K5 model 0 (75.18-MHz 586-class CPU)
  Origin = "AuthenticAMD"  Id = 0x500  Stepping=0
  Features=0x3bf<FPU,VME,DE,PSE,TSC,MSR,MCE,CX8,APIC>
real memory  = 33554432 (32768K bytes)
Physical memory chunk(s):
0x00001000 - 0x0009efff, 647168 bytes (158 pages)
0x0024a000 - 0x01ffdfff, 31145984 bytes (7604 pages)
avail memory = 30539776 (29824K bytes)
pcibus_setup(1):        mode 1 addr port (0x0cf8) is 0x80000058
pcibus_setup(1a):       mode1res=0x80000000 (0x80000000)
pcibus_check:   device 0 is there (id=70308086)
Probing for devices on PCI bus 0:
        configuration mode 1 allows 32 devices.
chip0 <Intel 82437VX PCI cache memory controller> rev 2 on pci0:0:0
        PCI Concurrency: enabled
        Cache: 512K dual-bank pipelined-burst secondary; L1 enabled
        DRAM: no memory hole, 50 MHz refresh
        Read burst timing: x-2-2-2/x-3-3-3
        Write burst timing: x-2-2-2
        RAS-CAS delay: 2 clocks
chip1 <Intel 82371SB PCI-ISA bridge> rev 1 on pci0:7:0
        I/O Recovery Timing: 8-bit 1 clocks, 16-bit 1 clocks
        Extended BIOS: disabled
        Lower BIOS: disabled
        Coprocessor IRQ13: enabled
        Mouse IRQ12: enabled
        Interrupt Routing: A: disabled, B: disabled, C: IRQ9, D:
disabled
                MB0: IRQ15, MB1:
chip2 <Intel 82371SB IDE interface> rev 0 on pci0:7:1
        mapreg[20] type=1 addr=0000f000 size=0010.
        Primary IDE: enabled
        Secondary IDE: enabled
vga0 <VGA-compatible display device> rev 10 on pci0:17:0
        mapreg[10] type=0 addr=e0000000 size=1000000.
        mapreg[14] type=1 addr=00006100 size=0100.
ed1 <NE2000 PCI Ethernet (RealTek 8029)> rev 0 int a irq 9 on pci0:19:0
        mapreg[10] type=1 addr=00006200 size=0020.
ed1: address 00:40:05:4d:11:af, type NE2000 (16 bit)
bpf: ed1 attached
pci0: uses 16777216 bytes of memory from e0000000 upto e0ffffff.
pci0: uses 304 bytes of I/O space from 6100 upto f00f.
Probing for devices on the ISA bus:
sc0: the current keyboard controller command byte 0047
kbdio: DIAGNOSE status:0055
kbdio: TEST_KBD_PORT status:0000
kbdio: RESET_KBD return code:00fa
kbdio: RESET_KBD status:00aa
sc0 at 0x60-0x6f irq 1 on motherboard
sc0: BIOS video mode:3
sc0: VGA registers upon power-up
50 18 10 00 10 00 03 00 02 67 5f 4f 50 82 55 81
bf 1f 00 4f 0e 0f 00 00 07 80 9c 8e 8f 28 1f 96
b9 a3 ff 00 01 02 03 04 05 14 07 38 39 3a 3b 3c
3d 3e 3f 0c 00 0f 08 00 00 00 00 00 10 0e 00 ff
sc0: video mode:24
sc0: VGA registers in BIOS for mode:24
50 18 10 00 10 00 03 00 02 67 5f 4f 50 82 55 81
bf 1f 00 4f 0d 0e 00 00 00 00 9c 8e 8f 28 1f 96
b9 a3 ff 00 01 02 03 04 05 14 07 38 39 3a 3b 3c
3d 3e 3f 0c 00 0f 08 00 00 00 00 00 10 0e 00 ff
sc0: VGA registers to be used for mode:24
50 18 10 00 10 00 03 00 02 67 5f 4f 50 82 55 81
bf 1f 00 4f 0d 0e 00 00 00 00 9c 8e 8f 28 1f 96
b9 a3 ff 00 01 02 03 04 05 14 07 38 39 3a 3b 3c
3d 3e 3f 0c 00 0f 08 00 00 00 00 00 10 0e 00 ff
sc0: rows_offset:1
sc0: VGA color <16 virtual consoles, flags=0x0>
ed0: disabled, not probed.
lpt0: disabled, not probed.
psm0: current command byte:0047
kbdio: TEST_AUX_PORT status:0000
kbdio: RESET_AUX return code:00fa
kbdio: RESET_AUX status:00aa
kbdio: RESET_AUX ID:0000
psm: status 00 02 64
psm: status 00 00 64
psm: status 00 03 64
psm: status 00 03 64
psm: status 10 00 64
psm: data 08 00 00
psm: data 08 00 00    
psm: status 00 02 64
psm0 at 0x60-0x64 irq 12 on motherboard
psm0: model Generic PS/2 mouse, device ID 0, 2 buttons
psm0: config:00000000, flags:00000000, packet size:3
psm0: syncmask:c0, syncbits:00
sio0: irq maps: 0x1 0x11 0x1 0x1
sio0 at 0x3f8-0x3ff irq 4 on isa
sio0: type 16550A
sio1: irq maps: 0x1 0x9 0x1 0x1
sio1 at 0x2f8-0x2ff irq 3 on isa
sio1: type 16550A
pca0 on motherboard
pca0: PC speaker audio driver
wdc0 at 0x1f0-0x1f7 irq 14 flags 0x80ff80ff on isa
wdc0: unit 0 (wd0): <Maxtor 90680D4>, 32-bit, multi-block-16
wd0: 6485MB (13281408 sectors), 13176 cyls, 16 heads, 63 S/T, 512 B/S
wdc1 at 0x170-0x177 irq 15 flags 0x80ff80ff on isa
wdc1: unit 0 (atapi): <Cyberdrive 120D/V1.00>, removable, dma, iordy
wcd0: 2062Kb/sec, 240Kb cache, audio play, 255 volume levels, ejectable
tray
wcd0: door open, unlocked
fdc0 at 0x3f0-0x3f7 irq 6 drq 2 on isa
fdc0: NEC 72065B
fdc0: FIFO enabled, 8 bytes threshold
fd0: 1.44MB 3.5in
npx0 on motherboard
npx0: INT 16 interface
sb0 at 0x220 irq 5 drq 1 on isa
sb0: <MV Jazz16 3.1>
opl0 at 0x388 on isa
opl0: <Yamaha OPL-3 FM>
uart0: disabled, not probed.
apm0 on isa
apm: found APM BIOS version 1.1
joy0 at 0x201 on isa
joy0: joystick
imasks: bio c008c040, tty c007121a, net c007121a
BIOS Geometries:
 0:0338fe3f 0..824=825 cylinders, 0..254=255 heads, 1..63=63 sectors
 0 accounted for
Device configuration finished.
bpf: tun0 attached
bpf: sl0 attached
bpf: sl1 attached
bpf: ppp0 attached
bpf: ppp1 attached
new masks: bio c008c040, tty c007121a, net c007121a
bpf: lo0 attached
Considering FFS root f/s.
wd0s1: type 0x6, start 63, end = 4096574, size 4096512 : OK
wd0s2: type 0x6, start 4096575, end = 6634844, size 2538270 : OK
wd0s3: type 0xa5, start 6634845, end = 9157049, size 2522205 : OK
wd0s4: type 0xa5, start 9157050, end = 13269689, size 4112640 : OK
Sequencer busy
isa_dma_acquire: channel 5 already in use

I used xdoom (from the 2.2.5-RELEASE package) to test the card. Though
it hosed because of color differences, it did run setup the card
correctly. I have no doubt that the problem lies in the code, but I am
not a professional programmer by any means.

/usr/src/sys/i386/isa/sound/sb_dsp.c:

static void
sb_dsp_close (int dev)
{
#ifdef JAZZ16
  /* Release 16 bit dma channel
   */
  if (Jazz16_detected)
    RELEASE_DMA_CHN (dma16);
#endif

  DMAbuf_close_dma (dev);
  sb_free_irq ();
  dsp_cleanup ();
  dsp_speaker (OFF);
  sb_dsp_busy = 0;
  sb_dsp_highspeed = 0;
  open_mode = 0;
}

I have checked all #include files and found no mention of
RELEASE_DMA_CHN. In this file there is one other reference to
RELEASE_DMA_CHN, but it is in a function. I would like to ammend this
problem, as this sound card sounds much better than the OPTi-931 it
replaced. Rebooting after one "peep" isn't fun.
                                                       
-- 
Kris Kirby 
UAH Mail <kirbyk@email.uah.edu> UAH CS <kkirby@cs.uah.edu>
Home     <kris@airnet.net>      WWW <nomurphy@hotmail.com>
-------------------------------------------
TGIFreeBSD... 'Nuff said.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-multimedia" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?35FE766A.68EC8467>