#
c8819f5d |
| 02-Nov-2022 |
kn <kn@openbsd.org> |
Remove audio(9) speaker_ctl(), let open() handle speakers where needed
Only five legacy half-duplex hardware drivers require this function to change between playing and recording: i386: ess(4), gus
Remove audio(9) speaker_ctl(), let open() handle speakers where needed
Only five legacy half-duplex hardware drivers require this function to change between playing and recording: i386: ess(4), gus(4), pas(4), sb(4) luna88k: nec86(4)
If defined, it is always called early in audio_open(), so just move the call from audio(4) to each hardware driver's open() handler.
SPKR_ON/OFF remain defined to leave driver-specific code unchanged.
Further cleanup (unchecked speaker_ctl() return values, FWRITE -> AUMODE_PLAY -> SPKR_ON dances, etc.) can happen later.
Builds fine on i386. OK ratchov
show more ...
|
#
1c987c6f |
| 28-Oct-2022 |
kn <kn@openbsd.org> |
Remove unused audio(9) get_props()/AUDIO_PROP_FULLDUPLEX
All audio drivers have been cleaned up and, if needed, now check for duplex mode in their open() handler.
OK ratchov miod
|
#
f9631a84 |
| 19-Oct-2022 |
kn <kn@openbsd.org> |
Remove unused setfd member from struct audio_hw_if
All consumers now use C99 struct init and none of them sets `.setfd'.
OK ratchov miod
|
#
18b10ac7 |
| 18-Oct-2022 |
kn <kn@openbsd.org> |
Remove unused AUDIO_PROP_{MMAP,INDEPENDENT}
AUDIO_PROP_FULLDUPLEX is the only audio(9) in use, the other two died with commit 1cf2860827c8ca659d8097d8da94a5ae5b888c53 Author: ratchov <ratchov@open
Remove unused AUDIO_PROP_{MMAP,INDEPENDENT}
AUDIO_PROP_FULLDUPLEX is the only audio(9) in use, the other two died with commit 1cf2860827c8ca659d8097d8da94a5ae5b888c53 Author: ratchov <ratchov@openbsd.org> Date: Thu Jun 25 06:43:45 2015 +0000
Reimplement the audio driver in a simpler way, removing unused/unusable functionality. Same API and ABI except for the removed bits and no behaviour change for programs using libsndio. With help from armani@ and mpi@, thanks.
but remained defined and set in drivers.
and the following merely moved them when they were dead code already:
commit 9215aa3dfad387bca877a805534df6dcfe8722eb Author: ratchov <ratchov@openbsd.org> Date: Wed Aug 31 07:22:43 2016 +0000
Delete unused ioctls and associated macros. Move macros that are still used internally by low-level drivers from sys/audioio.h to dev/audio_if.h instead of deleting them.
None of this is used in base or ports; codesearch.debian.net only shows AUDIO_PROP_{CAPTURE,PLAYBACK} in firefox-esr, mozjs and cubeb.
ratchov points out that audio_if.h and audioio.h are private interfaces and the codesearch shows SunOS and NetBSD bits (#ifdef'd out on OpenBSD).
OK ratchov
show more ...
|
#
0d6a2fde |
| 21-Mar-2022 |
miod <miod@openbsd.org> |
Constify struct {audio,midi,radio,video}_hw_if. No functional change.
ok mpi@ ratchov@ "More const is good" deraadt@
|
#
2baa08e2 |
| 16-Feb-2022 |
anton <anton@openbsd.org> |
Make room for a cookie argument passed to audio_attach_mi(). Currently unused but intended to be used to correlate audio and wskbd devices.
ok ratchov@
|
#
fd806da7 |
| 05-Sep-2019 |
ratchov <ratchov@openbsd.org> |
Add the set_blksz() and set_nblks() audio driver functions.
The first sets the block size in frames, which is necessarily common to play and recording directions no matter the number of channels. Th
Add the set_blksz() and set_nblks() audio driver functions.
The first sets the block size in frames, which is necessarily common to play and recording directions no matter the number of channels. The second sets the number of blocks per buffer for the given direction. Together, these two functions allow audio drivers to easily set the block size, matching both playback and recording constraints.
The round_blocksize() didn't allow to do so because it returns the block size in *bytes*. Since the driver doesn't know if it's called for the play or for the record block size, it's impossible to calculate the block size in all cases if play and record number of channels are different.
ok mpi@
show more ...
|
#
6e023a32 |
| 12-Mar-2019 |
ratchov <ratchov@openbsd.org> |
Add new copy_output() and underrun() methods to support drivers using bounce buffers, like the uaudio(4) driver.
ok mpi
|
#
557afc54 |
| 11-Mar-2017 |
ratchov <ratchov@openbsd.org> |
AUDIO_ENCODING_{S,U}LINEAR constants are neither used by low level drivers nor exposed to user-land. Remove definitions and code to handle convertions.
|
#
56fd3f56 |
| 19-Sep-2016 |
ratchov <ratchov@openbsd.org> |
Remove unused getdev() audio driver functions.
|
#
7cb42e31 |
| 14-Sep-2016 |
ratchov <ratchov@openbsd.org> |
Remove drain(), query_encoding(), mappage() and get_default_params() methods from all audio drivers and from the audio_if structure as they are never called.
|
#
9215aa3d |
| 31-Aug-2016 |
ratchov <ratchov@openbsd.org> |
Delete unused ioctls and associated macros. Move macros that are still used internally by low-level drivers from sys/audioio.h to dev/audio_if.h instead of deleting them.
|
#
1cf28608 |
| 25-Jun-2015 |
ratchov <ratchov@openbsd.org> |
Reimplement the audio driver in a simpler way, removing unused/unusable functionality. Same API and ABI except for the removed bits and no behaviour change for programs using libsndio. With help from
Reimplement the audio driver in a simpler way, removing unused/unusable functionality. Same API and ABI except for the removed bits and no behaviour change for programs using libsndio. With help from armani@ and mpi@, thanks.
show more ...
|
#
ac2bb4f3 |
| 11-May-2015 |
ratchov <ratchov@openbsd.org> |
Remove all audio format conversion code from the kernel (btw holding the kernel_lock), as we already do better conversions in user-mode. Yet, no need for every single driver to fiddle with the conver
Remove all audio format conversion code from the kernel (btw holding the kernel_lock), as we already do better conversions in user-mode. Yet, no need for every single driver to fiddle with the conversion code as they are done transparently by common MI code. With help from armani and miod, support from mpi
ok armani@
show more ...
|
#
886882aa |
| 15-May-2013 |
ratchov <ratchov@openbsd.org> |
Introduce a global interrupt-aware mutex protecting data structures (including sound-card registers) from concurent access by syscall and interrupt code-paths. Since critical sections remain the same
Introduce a global interrupt-aware mutex protecting data structures (including sound-card registers) from concurent access by syscall and interrupt code-paths. Since critical sections remain the same, calls to splraise/spllower can be safely replaced by calls to mtx_enter/mtx_leave with two exceptions: (1) mutexes are not reentrant (the inner splraise is thus removed), and (2) we're not allowed to sleep with a mutex (either msleep is used or the mutex is released before sleeping).
ok and help from kettenis, a lot of work from armani
show more ...
|
#
16579317 |
| 15-Jul-2010 |
jakemsr <jakemsr@openbsd.org> |
add two new members to structs audio_encoding and audio_prinfo. for both structs, the new members are 'bps' and 'msb', which describe the number of bytes per sample and data alignment in the sample,
add two new members to structs audio_encoding and audio_prinfo. for both structs, the new members are 'bps' and 'msb', which describe the number of bytes per sample and data alignment in the sample, respectively. drivers must properly set these fields in the 'query_encoding', 'set_parameters' and 'get_default_params' hardware interface methods.
discussed with ratchov, deraadt
show more ...
|
#
19281baf |
| 21-Apr-2008 |
jakemsr <jakemsr@openbsd.org> |
allow low level audio drivers to specify a default sample format, instead of 8-bit mono mulaw @ 8kHz.
this is just the infrastructure; no drivers are specifying a default yet.
ok ratchov@, deanna@
|
#
e69d8f77 |
| 16-Apr-2004 |
pvalchev <pvalchev@openbsd.org> |
remote splaudio hack, now that all architectures that need it, have it in MI includes; ok miod
|
#
5c1534d0 |
| 24-Feb-2004 |
deraadt <deraadt@openbsd.org> |
same gory splaudio hack for amd64, sigh
|
#
bbc1f3c3 |
| 31-Jan-2004 |
drahn <drahn@openbsd.org> |
Arm provides audio interrupt bits, do not default them here. ok deraadt@
|
#
84bc2b8a |
| 28-Mar-2003 |
jmc <jmc@openbsd.org> |
mu-law and A-law spelling; mu-law and u-law are the same, so used mu-law for consistency;
ok jason@
|
#
4c063ccc |
| 25-Jan-2003 |
jason <jason@openbsd.org> |
hppa provides its own IPL_AUDIO, too
|
#
f1f0c652 |
| 26-Aug-2002 |
mickey <mickey@openbsd.org> |
space cleanup; some from grendel@zeitbombe.org
|
#
72ad3cd4 |
| 23-Jul-2002 |
drahn <drahn@openbsd.org> |
Cardbus/pcmcia support for macppc. parts borrowed from NetBSD, and other portions of the tree.
|
#
213e382c |
| 30-May-2002 |
mickey <mickey@openbsd.org> |
fallout from the radio attachment fix
|