diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-11 12:58:37 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-11 12:58:37 -0700 |
commit | 0a3fd051c7036ef71b58863f8e5da7c3dabd9d3f (patch) | |
tree | 43388a81494ded94008afff66777f9f6e8cb5484 /sound/isa/sb/sb16_csp.c | |
parent | 57a44415beee38d1afcd8e1b5fad66f3414d2dac (diff) | |
parent | c911d1e16dfc1f0338bbc245ff724322c0113395 (diff) | |
download | blackbird-op-linux-0a3fd051c7036ef71b58863f8e5da7c3dabd9d3f.tar.gz blackbird-op-linux-0a3fd051c7036ef71b58863f8e5da7c3dabd9d3f.zip |
Merge branch 'linus' of master.kernel.org:/pub/scm/linux/kernel/git/perex/alsa
* 'linus' of master.kernel.org:/pub/scm/linux/kernel/git/perex/alsa: (122 commits)
[ALSA] version 1.0.14rc4
[ALSA] Add speaker pin sequencing to hda_codec.c:snd_hda_parse_pin_def_config()
[ALSA] hda-codec - Add ALC861VD Lenovo support
[ALSA] hda-codec - Fix connection list in generic parser
[ALSA] usb-audio: work around wrong wMaxPacketSize on ESI M4U
[ALSA] usb-audio: work around broken M-Audio MidiSport Uno firmware
[ALSA] usb-audio: explicitly match Logitech QuickCam
[ALSA] hda-codec - Fix a typo
[ALSA] hda-codec - Fix ALC880 uniwill auto-mutes
[ALSA] hda-codec - Fix AD1988 SPDIF playback route control
[ALSA] wm8750 typo fix
[ALSA] wavefront: only declare isapnp on CONFIG_PNP
[ALSA] hda-codec - bug fixes for stac92xx HDA codecs.
[ALSA] add MODULE_FIRMWARE entries
[ALSA] do not depend on FW_LOADER when internal firmware images are used
[ALSA] hda-codec - Fix resume of STAC92xx codecs
[ALSA] usbaudio - Revert the minimal period size fix patch
[ALSA] hda-codec - Add support for new HP DV series laptops
[ALSA] usb-audio - Fix the minimum period size per transfer mode
[ALSA] sound/pcmcia/vx/vxpocket.c: fix an if() condition
...
Diffstat (limited to 'sound/isa/sb/sb16_csp.c')
-rw-r--r-- | sound/isa/sb/sb16_csp.c | 30 |
1 files changed, 18 insertions, 12 deletions
diff --git a/sound/isa/sb/sb16_csp.c b/sound/isa/sb/sb16_csp.c index 3d9d7e0107ca..b279f2308aef 100644 --- a/sound/isa/sb/sb16_csp.c +++ b/sound/isa/sb/sb16_csp.c @@ -36,6 +36,13 @@ MODULE_AUTHOR("Uros Bizjak <uros@kss-loka.si>"); MODULE_DESCRIPTION("ALSA driver for SB16 Creative Signal Processor"); MODULE_LICENSE("GPL"); +#ifndef CONFIG_SND_SB16_CSP_FIRMWARE_IN_KERNEL +MODULE_FIRMWARE("sb16/mulaw_main.csp"); +MODULE_FIRMWARE("sb16/alaw_main.csp"); +MODULE_FIRMWARE("sb16/ima_adpcm_init.csp"); +MODULE_FIRMWARE("sb16/ima_adpcm_playback.csp"); +MODULE_FIRMWARE("sb16/ima_adpcm_capture.csp"); +#endif #ifdef SNDRV_LITTLE_ENDIAN #define CSP_HDR_VALUE(a,b,c,d) ((a) | ((b)<<8) | ((c)<<16) | ((d)<<24)) @@ -161,13 +168,17 @@ int snd_sb_csp_new(struct snd_sb *chip, int device, struct snd_hwdep ** rhwdep) */ static void snd_sb_csp_free(struct snd_hwdep *hwdep) { +#ifndef CONFIG_SND_SB16_CSP_FIRMWARE_IN_KERNEL int i; +#endif struct snd_sb_csp *p = hwdep->private_data; if (p) { if (p->running & SNDRV_SB_CSP_ST_RUNNING) snd_sb_csp_stop(p); +#ifndef CONFIG_SND_SB16_CSP_FIRMWARE_IN_KERNEL for (i = 0; i < ARRAY_SIZE(p->csp_programs); ++i) release_firmware(p->csp_programs[i]); +#endif kfree(p); } } @@ -690,9 +701,7 @@ static int snd_sb_csp_load_user(struct snd_sb_csp * p, const unsigned char __use return err; } -#define FIRMWARE_IN_THE_KERNEL - -#ifdef FIRMWARE_IN_THE_KERNEL +#ifdef CONFIG_SND_SB16_CSP_FIRMWARE_IN_KERNEL #include "sb16_csp_codecs.h" static const struct firmware snd_sb_csp_static_programs[] = { @@ -714,22 +723,19 @@ static int snd_sb_csp_firmware_load(struct snd_sb_csp *p, int index, int flags) "sb16/ima_adpcm_capture.csp", }; const struct firmware *program; - int err; BUILD_BUG_ON(ARRAY_SIZE(names) != CSP_PROGRAM_COUNT); program = p->csp_programs[index]; if (!program) { - err = request_firmware(&program, names[index], - p->chip->card->dev); - if (err >= 0) - p->csp_programs[index] = program; - else { -#ifdef FIRMWARE_IN_THE_KERNEL - program = &snd_sb_csp_static_programs[index]; +#ifdef CONFIG_SND_SB16_CSP_FIRMWARE_IN_KERNEL + program = &snd_sb_csp_static_programs[index]; #else + int err = request_firmware(&program, names[index], + p->chip->card->dev); + if (err < 0) return err; #endif - } + p->csp_programs[index] = program; } return snd_sb_csp_load(p, program->data, program->size, flags); } |