#
350a5faf |
| 23-Dec-2000 |
Cameron Grant <cg@FreeBSD.org> |
update code dealing with snd_dbuf objects to do so using a functional interface
modify chn_setblocksize() to pick a default soft-blocksize appropriate to the sample rate and format in use. it will
update code dealing with snd_dbuf objects to do so using a functional interface
modify chn_setblocksize() to pick a default soft-blocksize appropriate to the sample rate and format in use. it will aim for a power of two size small enough to generate block sizes of at most 20ms. it will also set the hard-blocksize taking into account rate/format conversions in use.
update drivers to implement setblocksize correctly: updated, tested: sb16, emu10k1, maestro, solo updated, untested: ad1816, ess, mss, sb8, csa not updated: ds1, es137x, fm801, neomagic, t4dwave, via82c686
i lack hardware to test: ad1816, csa, fm801, neomagic others will be updated/tested in the next few days.
show more ...
|
#
0f55ac6c |
| 18-Dec-2000 |
Cameron Grant <cg@FreeBSD.org> |
kobjify.
this gives us several benefits, including:
* easier extensibility- new optional methods can be added to ac97/mixer/channel classes without having to fixup every driver.
* forward compat
kobjify.
this gives us several benefits, including:
* easier extensibility- new optional methods can be added to ac97/mixer/channel classes without having to fixup every driver.
* forward compatibility for drivers, provided no new mandatory methods are added.
show more ...
|
Revision tags: release/4.2.0 |
|
#
9ec437a3 |
| 26-Oct-2000 |
Cameron Grant <cg@FreeBSD.org> |
add reinit functions to mixers unstaticize chn_start() add reset/resetdone functions to channels
|
#
04c24efd |
| 28-Sep-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
Add suspend/resume hooks.
Submitted by: sean@stat.duke.edu
|
Revision tags: release/4.1.1_cvs |
|
#
7dfc9325 |
| 18-Sep-2000 |
Cameron Grant <cg@FreeBSD.org> |
fix warnings
|
#
306f91b6 |
| 09-Sep-2000 |
Cameron Grant <cg@FreeBSD.org> |
detach support remove un-needed setdir functions add bus_teardown_intr calls where necessary destroy our dma tags where necessary destroy ac97 before releasing resources
|
#
33dbf14a |
| 01-Sep-2000 |
Cameron Grant <cg@FreeBSD.org> |
change mixer api slightly change channel interface - kobj implementation coming soonish make pcm_makelinks not panic if modular add pcm_unregister()
these changes support newpcm kld unloading, but t
change mixer api slightly change channel interface - kobj implementation coming soonish make pcm_makelinks not panic if modular add pcm_unregister()
these changes support newpcm kld unloading, but this is only implemented by ds1.c
show more ...
|
#
513693be |
| 21-Aug-2000 |
Cameron Grant <cg@FreeBSD.org> |
rework feeder sytem to allow feeders in klds
modify driver capability reporting format to list every audio format seperately- required for above and because we could not previously indicate that mon
rework feeder sytem to allow feeders in klds
modify driver capability reporting format to list every audio format seperately- required for above and because we could not previously indicate that mono was unsupported.
there should be no functional impact.
show more ...
|
#
4e77c048 |
| 19-Aug-2000 |
Cameron Grant <cg@FreeBSD.org> |
don't complain about bad irqs if using a shared irq
|
#
6ba60b3c |
| 13-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
This patch appears to solve the problems with recording resulting in bogus hwptr warnings. Further comments sought on -hackers were not forthcoming. I can only hope that calling DELAY() like this doe
This patch appears to solve the problems with recording resulting in bogus hwptr warnings. Further comments sought on -hackers were not forthcoming. I can only hope that calling DELAY() like this doesn't cause any heartburn.
show more ...
|
#
0edeb3dc |
| 09-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
A couple of cosmetic fixes, plus a biggie: When checking the DMA position, channel 1's dma position register must be quiescent. So the driver will spl, pause the DMA, delay a bit and hold as still as
A couple of cosmetic fixes, plus a biggie: When checking the DMA position, channel 1's dma position register must be quiescent. So the driver will spl, pause the DMA, delay a bit and hold as still as possible while snapping the picture.
I'm sure there HAS to be a better way to do this, but if there is, it's not documented.
So far as I can tell, this fixes recording, which means the Solo is open for business.
show more ...
|
#
3ac1ca33 |
| 03-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
1. Increase the size of the DMA buffer.
2. Offer half duplex with both playback and record on channel 1 or full duplex with playback always on channel 2 as a compile-time option.
3. 16 bit record o
1. Increase the size of the DMA buffer.
2. Offer half duplex with both playback and record on channel 1 or full duplex with playback always on channel 2 as a compile-time option.
3. 16 bit record output is byte swapped for some dumb reason. Report the _BE AFMTs for recording.
show more ...
|
#
a7e11506 |
| 02-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
Undo some of my own damage. With this patch, it appears that both recording and playback now work correctly.
|
#
bb7f26c3 |
| 02-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
Fix channel 1 playback the rest of the way. There are a couple of hiccups, but playback now proceeds mostly normally using both channel 1 and 2.
|
#
19a0702e |
| 02-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
Get playback on channel 1 closer to working. 8 bit samples work. 16 bit samples have some sort of choppiness, the nature of which is not completely clear, but it clearly has something to do with dma
Get playback on channel 1 closer to working. 8 bit samples work. 16 bit samples have some sort of choppiness, the nature of which is not completely clear, but it clearly has something to do with dma buffer synchronization. But at least channel 1 makes noise now.
show more ...
|
#
8eb3acc9 |
| 02-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
Fix channel 1, sort of. recording now generates IRQs and the output appears to be the correct length, but quality of output has not yet been tested. Also, full duplex audio (that is, playback on chan
Fix channel 1, sort of. recording now generates IRQs and the output appears to be the correct length, but quality of output has not yet been tested. Also, full duplex audio (that is, playback on channel 1) does not yet work. Two constants and I am there!
Obtained from: major hints from ALSA
show more ...
|
#
80a8e065 |
| 01-Aug-2000 |
Nick Sayer <nsayer@FreeBSD.org> |
Reverse the sense of the signed/unsigned formatting bit.
This dramatically cleans up playback quality, at least with mxaudio.
|
#
fd1aaecc |
| 31-Jul-2000 |
Cameron Grant <cg@FreeBSD.org> |
almost-there ess solo-1 driver, committed so people can tell me why it doesn't generate irqs.
|
#
7e857dd1 |
| 12-Jun-2009 |
Oleksandr Tymoshenko <gonzo@FreeBSD.org> |
- Merge from HEAD
|
#
90da2b28 |
| 07-Jun-2009 |
Ariff Abdullah <ariff@FreeBSD.org> |
Sound Mega-commit. Expect further cleanup until code freeze.
For a slightly thorough explaination, please refer to [1] http://people.freebsd.org/~ariff/SOUND_4.TXT.html .
Summary of changes includ
Sound Mega-commit. Expect further cleanup until code freeze.
For a slightly thorough explaination, please refer to [1] http://people.freebsd.org/~ariff/SOUND_4.TXT.html .
Summary of changes includes:
1 Volume Per-Channel (vpc). Provides private / standalone volume control unique per-stream pcm channel without touching master volume / pcm. Applications can directly use SNDCTL_DSP_[GET|SET][PLAY|REC]VOL, or for backwards compatibility, SOUND_MIXER_PCM through the opened dsp device instead of /dev/mixer. Special "bypass" mode is enabled through /dev/mixer which will automatically detect if the adjustment is made through /dev/mixer and forward its request to this private volume controller. Changes to this volume object will not interfere with other channels.
Requirements: - SNDCTL_DSP_[GET|SET][PLAY|REC]_VOL are newer ioctls (OSSv4) which require specific application modifications (preferred). - No modifications required for using bypass mode, so applications like mplayer or xmms should work out of the box.
Kernel hints: - hint.pcm.%d.vpc (0 = disable vpc).
Kernel sysctls: - hw.snd.vpc_mixer_bypass (default: 1). Enable or disable /dev/mixer bypass mode. - hw.snd.vpc_autoreset (default: 1). By default, closing/opening /dev/dsp will reset the volume back to 0 db gain/attenuation. Setting this to 0 will preserve its settings across device closing/opening. - hw.snd.vpc_reset (default: 0). Panic/reset button to reset all volume settings back to 0 db. - hw.snd.vpc_0db (default: 45). 0 db relative to linear mixer value.
2 High quality fixed-point Bandlimited SINC sampling rate converter, based on Julius O'Smith's Digital Audio Resampling - http://ccrma.stanford.edu/~jos/resample/. It includes a filter design script written in awk (the clumsiest joke I've ever written) - 100% 32bit fixed-point, 64bit accumulator. - Possibly among the fastest (if not fastest) of its kind. - Resampling quality is tunable, either runtime or during kernel compilation (FEEDER_RATE_PRESETS). - Quality can be further customized during kernel compilation by defining FEEDER_RATE_PRESETS in /etc/make.conf.
Kernel sysctls: - hw.snd.feeder_rate_quality. 0 - Zero-order Hold (ZOH). Fastest, bad quality. 1 - Linear Interpolation (LINEAR). Slightly slower than ZOH, better quality but still does not eliminate aliasing. 2 - (and above) - Sinc Interpolation(SINC). Best quality. SINC quality always start from 2 and above.
Rough quality comparisons: - http://people.freebsd.org/~ariff/z_comparison/
3 Bit-perfect mode. Bypasses all feeder/dsp effects. Pure sound will be directly fed into the hardware.
4 Parametric (compile time) Software Equalizer (Bass/Treble mixer). Can be customized by defining FEEDER_EQ_PRESETS in /etc/make.conf.
5 Transparent/Adaptive Virtual Channel. Now you don't have to disable vchans in order to make digital format pass through. It also makes vchans more dynamic by choosing a better format/rate among all the concurrent streams, which means that dev.pcm.X.play.vchanformat/rate becomes sort of optional.
6 Exclusive Stream, with special open() mode O_EXCL. This will "mute" other concurrent vchan streams and only allow a single channel with O_EXCL set to keep producing sound.
Other Changes: * most feeder_* stuffs are compilable in userland. Let's not speculate whether we should go all out for it (save that for FreeBSD 16.0-RELEASE). * kobj signature fixups, thanks to Andriy Gapon <avg@freebsd.org> * pull out channel mixing logic out of vchan.c and create its own feeder_mixer for world justice. * various refactoring here and there, for good or bad. * activation of few more OSSv4 ioctls() (see [1] above). * opt_snd.h for possible compile time configuration: (mostly for debugging purposes, don't try these at home) SND_DEBUG SND_DIAGNOSTIC SND_FEEDER_MULTIFORMAT SND_FEEDER_FULL_MULTIFORMAT SND_FEEDER_RATE_HP SND_PCM_64 SND_OLDSTEREO
Manual page updates are on the way.
Tested by: joel, Olivier SMEDTS <olivier at gid0 d org>, too many unsung / unnamed heroes.
show more ...
|
Revision tags: release/7.2.0_cvs, release/7.2.0, release/7.1.0_cvs, release/7.1.0, release/6.4.0_cvs, release/6.4.0, release/7.0.0_cvs, release/7.0.0, release/6.3.0_cvs, release/6.3.0 |
|
#
082f6383 |
| 17-Jun-2007 |
Ariff Abdullah <ariff@FreeBSD.org> |
Flush remaining malloc() cleanups (M_NOWAIT -> M_WAITOK).
|
#
bdfbdcec |
| 11-Jun-2007 |
Ariff Abdullah <ariff@FreeBSD.org> |
Filter/compress the amount of channel trigger. This should reduce much of lock/unlock contentions within the interrupt handler. Most of these drivers only need PCMTRIG_START or STOP (ABORT).
Discuss
Filter/compress the amount of channel trigger. This should reduce much of lock/unlock contentions within the interrupt handler. Most of these drivers only need PCMTRIG_START or STOP (ABORT).
Discussed with: scottl
show more ...
|
#
79462204 |
| 27-May-2007 |
Ariff Abdullah <ariff@FreeBSD.org> |
Fix broken binary issues with latest gcc 4.x due to bitfield signess mishaps for emu10k1 [1] and few other places.
Reported/Submitted/Tested by: Ed Schouten <ed@fxq.nl> [1]
|
#
2e334adf |
| 18-Apr-2007 |
Ariff Abdullah <ariff@FreeBSD.org> |
sndbuf_alloc() now accept dmaflags argument which will be forwarded to internal bus_dmammem_alloc() for greater flexibility on setting up DMA / page attributes.
|
#
4582b3a1 |
| 15-Mar-2007 |
Ariff Abdullah <ariff@FreeBSD.org> |
Fix severe out-of-bound mtx "type" pointer, causing WITNESS refcount confusions and panic provided that the following conditions are met:
1) WITNESS is enabled (watch/trace). 2) Using modules, i
Fix severe out-of-bound mtx "type" pointer, causing WITNESS refcount confusions and panic provided that the following conditions are met:
1) WITNESS is enabled (watch/trace). 2) Using modules, instead of statically linked (Not a strict requirement, but easier to reproduce this way). 3) 2 or more modules share the same mtx type ("sound softc"). - They might share the same name (strcmp() == 0), but it always point to different address. 4) Repetitive kldunload/load on any module that shares the same mtx type (Not a strict requirement, but easier to reproduce this way).
Consider module A and module B: - From enroll() - subr_witness.c: * Load module A. Everything seems fine right now. wA-w_refcount == 1 ; wA-w_name = "sound softc" * Load module B. * w->w_name == description will always fail. ("sound softc" from A and B point to different address). * wA->w_refcount > 0 && strcmp(description, wA->w_name) == 0 * enroll() will return wA instead of returning (possibly unique) wB. wA->w_refcount++ , == 2. * Unload module A, mtx_destroy(), wA->w_name become invalid, but wA->w_refcount-- become 1 instead of 0. wA will not be removed from witness list. * Some other places call mtx_init(), iterating witness list, found wA, failed on wA->w_name == description * wA->w_refcount > 0 && strcmp(description, wA->w_name) * Panic on strcmp() since wA->w_name no longer point to valid address.
Note that this could happened in other places as well, not just sound (eg. consider lots of drivers that share simmilar MTX_NETWORK_LOCK).
Solutions (for sound case): 1) Provide unique mtx type string for each mutex creation (chosen) or 2) Put "sound softc" global variable somewhere and use it.
show more ...
|