diff options
author | Jacob Meuser <jakemsr@cvs.openbsd.org> | 2008-05-29 07:20:16 +0000 |
---|---|---|
committer | Jacob Meuser <jakemsr@cvs.openbsd.org> | 2008-05-29 07:20:16 +0000 |
commit | 518ab18a332a7f800ee41b06f35f75612dd98cc2 (patch) | |
tree | 6265105414d70d9846a127e3d63d4a5e626a7831 /sys/dev/pci/eso.c | |
parent | 008a1587034d4d02528c1afa89c7cf943a3921b5 (diff) |
specify alternate default audio parameters to make the default expansion
factor 1
also obsoletes a XXX workaround in azalia
ok ratchov@
Diffstat (limited to 'sys/dev/pci/eso.c')
-rw-r--r-- | sys/dev/pci/eso.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/sys/dev/pci/eso.c b/sys/dev/pci/eso.c index b7af1fb89af..b26aec62434 100644 --- a/sys/dev/pci/eso.c +++ b/sys/dev/pci/eso.c @@ -1,4 +1,4 @@ -/* $OpenBSD: eso.c,v 1.25 2008/04/21 00:32:43 jakemsr Exp $ */ +/* $OpenBSD: eso.c,v 1.26 2008/05/29 07:20:15 jakemsr Exp $ */ /* $NetBSD: eso.c,v 1.48 2006/12/18 23:13:39 kleink Exp $ */ /* @@ -110,6 +110,7 @@ void eso_close(void *); int eso_query_encoding(void *, struct audio_encoding *); int eso_set_params(void *, int, int, struct audio_params *, struct audio_params *); +void eso_get_default_params(void *, int, struct audio_params *); int eso_round_blocksize(void *, int); int eso_halt_output(void *); int eso_halt_input(void *); @@ -158,7 +159,7 @@ struct audio_hw_if eso_hw_if = { eso_get_props, eso_trigger_output, eso_trigger_input, - NULL + eso_get_default_params }; const char * const eso_rev2model[] = { @@ -680,6 +681,17 @@ eso_query_encoding(void *hdl, struct audio_encoding *fp) return (0); } +void +eso_get_default_params(void *addr, int mode, struct audio_params *params) +{ + params->sample_rate = 48000; + params->encoding = AUDIO_ENCODING_ULINEAR_LE; + params->precision = 16; + params->channels = 2; + params->sw_code = NULL; + params->factor = 1; +} + int eso_set_params(void *hdl, int setmode, int usemode, struct audio_params *play, struct audio_params *rec) |