Commit 727dede0 authored by Takashi Iwai's avatar Takashi Iwai
Browse files

sound: Retire OSS

Since no complaints have been raised after disabling the build of OSS
(Open Sound System) by the commit 31cbee6a

 ("sound: Disable the
build of OSS drivers"), let's finally drop the whole code and
documentation.

Some glue codes are still left intact since sound/oss/dmasound stuff
remains -- which is an independent implementation solely for m68k, and
it's not covered by ALSA yet.

Also, a couple of API header files (linux/sound.h and
linux/soundcard.h) are kept remaining as well, since the OSS API
itself is still supported by ALSA OSS emulation, and applications can
refer to these.

Where we're at it, some help texts in the top-level Kconfig are
adjusted, too (who still needs to specify I/O port in kbuild
nowadays?).
Reviewed-by: default avatarJaroslav Kysela <perex@perex.cz>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 3f1185d6
ALS-007/ALS-100/ALS-200 based sound cards
=========================================
Support for sound cards based around the Avance Logic
ALS-007/ALS-100/ALS-200 chip is included. These chips are a single
chip PnP sound solution which is mostly hardware compatible with the
Sound Blaster 16 card, with most differences occurring in the use of
the mixer registers. For this reason the ALS code is integrated
as part of the Sound Blaster 16 driver (adding only 800 bytes to the
SB16 driver).
To use an ALS sound card under Linux, enable the following options as
modules in the sound configuration section of the kernel config:
- 100% Sound Blaster compatibles (SB16/32/64, ESS, Jazz16) support
- FM synthesizer (YM3812/OPL-3) support
- standalone MPU401 support may be required for some cards; for the
ALS-007, when using isapnptools, it is required
Since the ALS-007/100/200 are PnP cards, ISAPnP support should probably be
compiled in. If kernel level PnP support is not included, isapnptools will
be required to configure the card before the sound modules are loaded.
When using kernel level ISAPnP, the kernel should correctly identify and
configure all resources required by the card when the "sb" module is
inserted. Note that the ALS-007 does not have a 16 bit DMA channel and that
the MPU401 interface on this card uses a different interrupt to the audio
section. This should all be correctly configured by the kernel; if problems
with the MPU401 interface surface, try using the standalone MPU401 module,
passing "0" as the "sb" module's "mpu_io" module parameter to prevent the
soundblaster driver attempting to register the MPU401 itself. The onboard
synth device can be accessed using the "opl3" module.
If isapnptools is used to wake up the sound card (as in 2.2.x), the settings
of the card's resources should be passed to the kernel modules ("sb", "opl3"
and "mpu401") using the module parameters. When configuring an ALS-007, be
sure to specify different IRQs for the audio and MPU401 sections - this card
requires they be different. For "sb", "io", "irq" and "dma" should be set
to the same values used to configure the audio section of the card with
isapnp. "dma16" should be explicitly set to "-1" for an ALS-007 since this
card does not have a 16 bit dma channel; if not specified the kernel will
default to using channel 5 anyway which will cause audio not to work.
"mpu_io" should be set to 0. The "io" parameter of the "opl3" module should
also agree with the setting used by isapnp. To get the MPU401 interface
working on an ALS-007 card, the "mpu401" module will be required since this
card uses separate IRQs for the audio and MPU401 sections and there is no
parameter available to pass a different IRQ to the "sb" driver (whose
inbuilt MPU401 driver would otherwise be fine). Insert the mpu401 module
passing appropriate values using the "io" and "irq" parameters.
The resulting sound driver will provide the following capabilities:
- 8 and 16 bit audio playback
- 8 and 16 bit audio recording
- Software selection of record source (line in, CD, FM, mic, master)
- Record and playback of midi data via the external MPU-401
- Playback of midi data using inbuilt FM synthesizer
- Control of the ALS-007 mixer via any OSS-compatible mixer programs.
Controls available are Master (L&R), Line in (L&R), CD (L&R),
DSP/PCM/audio out (L&R), FM (L&R) and Mic in (mono).
Jonathan Woithe
jwoithe@just42.net
30 March 1998
Modified 2000-02-26 by Dave Forrest, drf5n@virginia.edu to add ALS100/ALS200
Modified 2000-04-10 by Paul Laufer, pelaufer@csupomona.edu to add ISAPnP info.
Modified 2000-11-19 by Jonathan Woithe, jwoithe@just42.net
- updated information for kernel 2.4.x.
Driver
------
Information about Audio Excel DSP 16 driver can be found in the source
file aedsp16.c
Please, read the head of the source before using it. It contain useful
information.
Configuration
-------------
The Audio Excel configuration, is now done with the standard Linux setup.
You have to configure the sound card (Sound Blaster or Microsoft Sound System)
and, if you want it, the Roland MPU-401 (do not use the Sound Blaster MPU-401,
SB-MPU401) in the main driver menu. Activate the lowlevel drivers then select
the Audio Excel hardware that you want to initialize. Check the IRQ/DMA/MIRQ
of the Audio Excel initialization: it must be the same as the SBPRO (or MSS)
setup. If the parameters are different, correct it.
I you own a Gallant's audio card based on SC-6600, activate the SC-6600 support.
If you want to change the configuration of the sound board, be sure to
check off all the configuration items before re-configure it.
Module parameters
-----------------
To use this driver as a module, you must configure some module parameters, to
set up I/O addresses, IRQ lines and DMA channels. Some parameters are
mandatory while some others are optional. Here a list of parameters you can
use with this module:
Name Description
==== ===========
MANDATORY
io I/O base address (0x220 or 0x240)
irq irq line (5, 7, 9, 10 or 11)
dma dma channel (0, 1 or 3)
OPTIONAL
mss_base I/O base address for activate MSS mode (default SBPRO)
(0x530 or 0xE80)
mpu_base I/O base address for activate MPU-401 mode
(0x300, 0x310, 0x320 or 0x330)
mpu_irq MPU-401 irq line (5, 7, 9, 10 or 0)
A configuration file in /etc/modprobe.d/ directory will have lines like this:
options opl3 io=0x388
options ad1848 io=0x530 irq=11 dma=3
options aedsp16 io=0x220 irq=11 dma=3 mss_base=0x530
Where the aedsp16 options are the options for this driver while opl3 and
ad1848 are the corresponding options for the MSS and OPL3 modules.
Loading MSS and OPL3 needs to pre load the aedsp16 module to set up correctly
the sound card. Installation dependencies must be written in configuration
files under /etc/modprobe.d/ directory:
softdep ad1848 pre: aedsp16
softdep opl3 pre: aedsp16
Then you must load the sound modules stack in this order:
sound -> aedsp16 -> [ ad1848, opl3 ]
With the above configuration, loading ad1848 or opl3 modules, will
automatically load all the sound stack.
Sound cards supported
---------------------
This driver supports the SC-6000 and SC-6600 based Gallant's sound card.
It don't support the Audio Excel DSP 16 III (try the SC-6600 code).
I'm working on the III version of the card: if someone have useful
information about it, please let me know.
For all the non-supported audio cards, you have to boot MS-DOS (or WIN95)
activating the audio card with the MS-DOS device driver, then you have to
<ctrl>-<alt>-<del> and boot Linux.
Follow these steps:
1) Compile Linux kernel with standard sound driver, using the emulation
you want, with the parameters of your audio card,
e.g. Microsoft Sound System irq10 dma3
2) Install your new kernel as the default boot kernel.
3) Boot MS-DOS and configure the audio card with the boot time device
driver, for MSS irq10 dma3 in our example.
4) <ctrl>-<alt>-<del> and boot Linux. This will maintain the DOS configuration
and will boot the new kernel with sound driver. The sound driver will find
the audio card and will recognize and attach it.
Reports on User successes
-------------------------
> Date: Mon, 29 Jul 1996 08:35:40 +0100
> From: Mr S J Greenaway <sjg95@unixfe.rl.ac.uk>
> To: riccardo@cdc8g5.cdc.polimi.it (Riccardo Facchetti)
> Subject: Re: Audio Excel DSP 16 initialization code
>
> Just to let you know got my Audio Excel (emulating a MSS) working
> with my original SB16, thanks for the driver!
Last revised: 20 August 1998
Riccardo Facchetti
fizban@tin.it
Documentation for CMI 8330 (SoundPRO)
-------------------------------------
Alessandro Zummo <azummo@ita.flashnet.it>
( Be sure to read Documentation/sound/oss/SoundPro too )
This adapter is now directly supported by the sb driver.
The only thing you have to do is to compile the kernel sound
support as a module and to enable kernel ISAPnP support,
as shown below.
CONFIG_SOUND=m
CONFIG_SOUND_SB=m
CONFIG_PNP=y
CONFIG_ISAPNP=y
and optionally:
CONFIG_SOUND_MPU401=m
for MPU401 support.
(I suggest you to use "make menuconfig" or "make xconfig"
for a more comfortable configuration editing)
Then you can do
modprobe sb
and everything will be (hopefully) configured.
You should get something similar in syslog:
sb: CMI8330 detected.
sb: CMI8330 sb base located at 0x220
sb: CMI8330 mpu base located at 0x330
sb: CMI8330 mail reports to Alessandro Zummo <azummo@ita.flashnet.it>
sb: ISAPnP reports CMI 8330 SoundPRO at i/o 0x220, irq 7, dma 1,5
The old documentation file follows for reference
purposes.
How to enable CMI 8330 (SOUNDPRO) soundchip on Linux
------------------------------------------
Stefan Laudat <Stefan.Laudat@asit.ro>
[Note: The CMI 8338 is unrelated and is supported by cmpci.o]
In order to use CMI8330 under Linux you just have to use a proper isapnp.conf, a good isapnp and a little bit of patience. I use isapnp 1.17, but
you may get a better one I guess at http://www.roestock.demon.co.uk/isapnptools/.
Of course you will have to compile kernel sound support as module, as shown below:
CONFIG_SOUND=m
CONFIG_SOUND_OSS=m
CONFIG_SOUND_SB=m
CONFIG_SOUND_ADLIB=m
CONFIG_SOUND_MPU401=m
# Mikro$chaft sound system (kinda useful here ;))
CONFIG_SOUND_MSS=m
The /etc/isapnp.conf file will be:
<snip below>
(READPORT 0x0203)
(ISOLATE PRESERVE)
(IDENTIFY *)
(VERBOSITY 2)
(CONFLICT (IO FATAL)(IRQ FATAL)(DMA FATAL)(MEM FATAL)) # or WARNING
(VERIFYLD N)
# WSS
(CONFIGURE CMI0001/16777472 (LD 0
(IO 0 (SIZE 8) (BASE 0x0530))
(IO 1 (SIZE 8) (BASE 0x0388))
(INT 0 (IRQ 7 (MODE +E)))
(DMA 0 (CHANNEL 0))
(NAME "CMI0001/16777472[0]{CMI8330/C3D Audio Adapter}")
(ACT Y)
))
# MPU
(CONFIGURE CMI0001/16777472 (LD 1
(IO 0 (SIZE 2) (BASE 0x0330))
(INT 0 (IRQ 11 (MODE +E)))
(NAME "CMI0001/16777472[1]{CMI8330/C3D Audio Adapter}")
(ACT Y)
))
# Joystick
(CONFIGURE CMI0001/16777472 (LD 2
(IO 0 (SIZE 8) (BASE 0x0200))
(NAME "CMI0001/16777472[2]{CMI8330/C3D Audio Adapter}")
(ACT Y)
))
# SoundBlaster
(CONFIGURE CMI0001/16777472 (LD 3
(IO 0 (SIZE 16) (BASE 0x0220))
(INT 0 (IRQ 5 (MODE +E)))
(DMA 0 (CHANNEL 1))
(DMA 1 (CHANNEL 5))
(NAME "CMI0001/16777472[3]{CMI8330/C3D Audio Adapter}")
(ACT Y)
))
(WAITFORKEY)
<end of snip>
The module sequence is trivial:
/sbin/insmod soundcore
/sbin/insmod sound
/sbin/insmod uart401
# insert this first
/sbin/insmod ad1848 io=0x530 irq=7 dma=0 soundpro=1
# The sb module is an alternative to the ad1848 (Microsoft Sound System)
# Anyhow, this is full duplex and has MIDI
/sbin/insmod sb io=0x220 dma=1 dma16=5 irq=5 mpu_io=0x330
Alma Chao <elysian@ethereal.torsion.org> suggests the following in
a /etc/modprobe.d/*conf file:
alias sound ad1848
alias synth0 opl3
options ad1848 io=0x530 irq=7 dma=0 soundpro=1
options opl3 io=0x388
Documentation for the ESS AudioDrive chips
In 2.4 kernels the SoundBlaster driver not only tries to detect an ESS chip, it
tries to detect the type of ESS chip too. The correct detection of the chip
doesn't always succeed however, so unless you use the kernel isapnp facilities
(and you chip is pnp capable) the default behaviour is 2.0 behaviour which
means: only detect ES688 and ES1688.
All ESS chips now have a recording level setting. This is a need-to-have for
people who want to use their ESS for recording sound.
Every chip that's detected as a later-than-es1688 chip has a 6 bits logarithmic
master volume control.
Every chip that's detected as a ES1887 now has Full Duplex support. Made a
little testprogram that shows that is works, haven't seen a real program that
needs this however.
For ESS chips an additional parameter "esstype" can be specified. This controls
the (auto) detection of the ESS chips. It can have 3 kinds of values:
-1 Act like 2.0 kernels: only detect ES688 or ES1688.
0 Try to auto-detect the chip (may fail for ES1688)
688 The chip will be treated as ES688
1688 ,, ,, ,, ,, ,, ,, ES1688
1868 ,, ,, ,, ,, ,, ,, ES1868
1869 ,, ,, ,, ,, ,, ,, ES1869
1788 ,, ,, ,, ,, ,, ,, ES1788
1887 ,, ,, ,, ,, ,, ,, ES1887
1888 ,, ,, ,, ,, ,, ,, ES1888
Because Full Duplex is supported for ES1887 you can specify a second DMA
channel by specifying module parameter dma16. It can be one of: 0, 1, 3 or 5.
Documentation for the ESS1868F AudioDrive PnP sound card
The ESS1868 sound card is a PnP ESS1688-compatible 16-bit sound card.
It should be automatically detected by the Linux Kernel isapnp support when you
load the sb.o module. Otherwise you should take care of:
* The ESS1868 does not allow use of a 16-bit DMA, thus DMA 0, 1, 2, and 3
may only be used.
* isapnptools version 1.14 does work with ESS1868. Earlier versions might
not.
* Sound support MUST be compiled as MODULES, not statically linked
into the kernel.
NOTE: this is only needed when not using the kernel isapnp support!
For configuring the sound card's I/O addresses, IRQ and DMA, here is a
sample copy of the isapnp.conf directives regarding the ESS1868:
(CONFIGURE ESS1868/-1 (LD 1
(IO 0 (BASE 0x0220))
(IO 1 (BASE 0x0388))
(IO 2 (BASE 0x0330))
(DMA 0 (CHANNEL 1))
(INT 0 (IRQ 5 (MODE +E)))
(ACT Y)
))
(for a full working isapnp.conf file, remember the
(ISOLATE)
(IDENTIFY *)
at the beginning and the
(WAITFORKEY)
at the end.)
In this setup, the main card I/O is 0x0220, FM synthesizer is 0x0388, and
the MPU-401 MIDI port is located at 0x0330. IRQ is IRQ 5, DMA is channel 1.
After configuring the sound card via isapnp, to use the card you must load
the sound modules with the proper I/O information. Here is my setup:
# ESS1868F AudioDrive initialization
/sbin/modprobe sound
/sbin/insmod uart401
/sbin/insmod sb io=0x220 irq=5 dma=1 dma16=-1
/sbin/insmod mpu401 io=0x330
/sbin/insmod opl3 io=0x388
/sbin/insmod v_midi
opl3 is the FM synthesizer
/sbin/insmod opl3 io=0x388
Introduction Notes on Modular Sound Drivers and Soundcore
Wade Hampton
2/14/2001
Purpose:
========
This document provides some general notes on the modular
sound drivers and their configuration, along with the
support modules sound.o and soundcore.o.
Note, some of this probably should be added to the Sound-HOWTO!
Note, soundlow.o was present with 2.2 kernels but is not
required for 2.4.x kernels. References have been removed
to this.
Copying:
========
none
History:
========
0.1.0 11/20/1998 First version, draft
1.0.0 11/1998 Alan Cox changes, incorporation in 2.2.0
as Documentation/sound/oss/Introduction
1.1.0 6/30/1999 Second version, added notes on making the drivers,
added info on multiple sound cards of similar types,]
added more diagnostics info, added info about esd.
added info on OSS and ALSA.
1.1.1 19991031 Added notes on sound-slot- and sound-service.
(Alan Cox)
1.1.2 20000920 Modified for Kernel 2.4 (Christoph Hellwig)
1.1.3 20010214 Minor notes and corrections (Wade Hampton)
Added examples of sound-slot-0, etc.
Modular Sound Drivers:
======================
Thanks to the GREAT work by Alan Cox (alan@lxorguk.ukuu.org.uk),
[And Oleg Drokin, Thomas Sailer, Andrew Veliath and more than a few
others - not to mention Hannu's original code being designed well
enough to cope with that kind of chopping up](Alan)
the standard Linux kernels support a modular sound driver. From
Alan's comments in linux/drivers/sound/README.FIRST:
The modular sound driver patches were funded by Red Hat Software
(www.redhat.com). The sound driver here is thus a modified version of
Hannu's code. Please bear that in mind when considering the appropriate
forums for bug reporting.
The modular sound drivers may be loaded via insmod or modprobe.
To support all the various sound modules, there are two general
support modules that must be loaded first:
soundcore.o: Top level handler for the sound system, provides
a set of functions for registration of devices
by type.
sound.o: Common sound functions required by all modules.
For the specific sound modules (e.g., sb.o for the Soundblaster),
read the documentation on that module to determine what options
are available, for example IRQ, address, DMA.
Warning, the options for different cards sometime use different names
for the same or a similar feature (dma1= versus dma16=). As a last
resort, inspect the code (search for module_param).
Notes:
1. There is a new OpenSource sound driver called ALSA which is
currently under development: http://www.alsa-project.org/
The ALSA drivers support some newer hardware that may not
be supported by this sound driver and also provide some
additional features.
2. The commercial OSS driver may be obtained from the site:
http://www.opensound.com. This may be used for cards that
are unsupported by the kernel driver, or may be used
by other operating systems.
3. The enlightenment sound daemon may be used for playing
multiple sounds at the same time via a single card, eliminating
some of the requirements for multiple sound card systems. For
more information, see: http://www.tux.org/~ricdude/EsounD.html
The "esd" program may be used with the real-player and mpeg
players like mpg123 and x11amp. The newer real-player
and some games even include built-in support for ESD!
Building the Modules:
=====================
This document does not provide full details on building the
kernel, etc. The notes below apply only to making the kernel
sound modules. If this conflicts with the kernel's README,
the README takes precedence.
1. To make the kernel sound modules, cd to your /usr/src/linux
directory (typically) and type make config, make menuconfig,
or make xconfig (to start the command line, dialog, or x-based
configuration tool).
2. Select the Sound option and a dialog will be displayed.
3. Select M (module) for "Sound card support".
4. Select your sound driver(s) as a module. For ProAudio, Sound
Blaster, etc., select M (module) for OSS sound modules.
[thanks to Marvin Stodolsky <stodolsk@erols.com>]A
5. Make the kernel (e.g., make bzImage), and install the kernel.
6. Make the modules and install them (make modules; make modules_install).
Note, for 2.5.x kernels, make sure you have the newer module-init-tools
installed or modules will not be loaded properly. 2.5.x requires an
updated module-init-tools.
Plug and Play (PnP:
===================
If the sound card is an ISA PnP card, isapnp may be used
to configure the card. See the file isapnp.txt in the
directory one level up (e.g., /usr/src/linux/Documentation).
Also the 2.4.x kernels provide PnP capabilities, see the
file NEWS in this directory.
PCI sound cards are highly recommended, as they are far
easier to configure and from what I have read, they use
less resources and are more CPU efficient.
INSMOD:
=======
If loading via insmod, the common modules must be loaded in the
order below BEFORE loading the other sound modules. The card-specific
modules may then be loaded (most require parameters). For example,
I use the following via a shell script to load my SoundBlaster:
SB_BASE=0x240
SB_IRQ=9
SB_DMA=3
SB_DMA2=5
SB_MPU=0x300
#
echo Starting sound
/sbin/insmod soundcore
/sbin/insmod sound
#
echo Starting sound blaster....
/sbin/insmod uart401
/sbin/insmod sb io=$SB_BASE irq=$SB_IRQ dma=$SB_DMA dma16=$SB_DMA2 mpu_io=$SB_MP
When using sound as a module, I typically put these commands
in a file such as /root/soundon.sh.
MODPROBE:
=========
If loading via modprobe, these common files are automatically loaded when
requested by modprobe. For example, my /etc/modprobe.d/oss.conf contains:
alias sound sb
options sb io=0x240 irq=9 dma=3 dma16=5 mpu_io=0x300
All you need to do to load the module is:
/sbin/modprobe sb
Sound Status:
=============
The status of sound may be read/checked by:
cat (anyfile).au >/dev/audio
[WWH: This may not work properly for SoundBlaster PCI 128 cards
such as the es1370/1 (see the es1370/1 files in this directory)
as they do not automatically support uLaw on /dev/audio.]
The status of the modules and which modules depend on
which other modules may be checked by:
/sbin/lsmod
/sbin/lsmod should show something like the following:
sb 26280 0
uart401 5640 0 [sb]
sound 57112 0 [sb uart401]
soundcore 1968 8 [sb sound]
Removing Sound:
===============
Sound may be removed by using /sbin/rmmod in the reverse order
in which you load the modules. Note, if a program has a sound device
open (e.g., xmixer), that module (and the modules on which it
depends) may not be unloaded.
For example, I use the following to remove my Soundblaster (rmmod
in the reverse order in which I loaded the modules):
/sbin/rmmod sb
/sbin/rmmod uart401
/sbin/rmmod sound
/sbin/rmmod soundcore
When using sound as a module, I typically put these commands
in a script such as /root/soundoff.sh.
Removing Sound for use with OSS:
================================
If you get really stuck or have a card that the kernel modules
will not support, you can get a commercial sound driver from