Commit Graph

39 Commits

Author SHA1 Message Date
itojun aca4c091d3 sprintf -> snprintf 2004-04-22 00:17:10 +00:00
jmmv 8d3610f027 Be consistent with other messages: output "VIA Technologies" instead of
only "VIA".  Also add a missing "Audio" word to a message.
Closes PR kern/25152 by Nicolas Joly.
2004-04-12 15:44:53 +00:00
jmcneill e927880cc0 Don't allow block sizes < 288 bytes on VT823x chips (patch from kent@).
Fixes kern/22788.
2004-03-31 21:10:04 +00:00
xtraeme 1b33913193 err fix previous (return -> break) in case statement. 2004-03-25 23:07:09 +00:00
xtraeme 8ded9ee13c There are two revisions of the VT8235 audio chipset (0x50 and 0x60), so
print any of them as VT8235, approved by martin@.
2004-03-25 22:48:43 +00:00
martin 82ebc8b5ab Better identify some revisions of via 823* audio chips.
From PR kern/24906.
2004-03-25 10:20:27 +00:00
simonb b6abb6ab1d Remove some assigned-to but otherwise unused variables. 2003-10-30 01:58:17 +00:00
jmmv 99aaf4a240 Enable auvia_reset_codec's code and wait until the card is available.
Fixes 'invalid codec' problems (at least with AD1980).  Ok'ed by tsarna@.
2003-09-14 14:48:17 +00:00
wiz 1ffa7b76c4 DMA, not dma nor Dma. 2003-05-03 18:10:37 +00:00
thorpej b193480908 Add extensible malloc types, adapted from FreeBSD. This turns
malloc types into a structure, a pointer to which is passed around,
instead of an int constant.  Allow the limit to be adjusted when the
malloc type is defined, or with a function call, as suggested by
Jonathan Stone.
2003-02-01 06:23:35 +00:00
thorpej 7ec10e2d99 Use aprint_*(). 2003-01-31 00:07:39 +00:00
kent 22d0e4bb85 auvia_set_params:
For a fixed-rate codec, when AUMODE_RECORD and AUDIO_ENCODING_MULAW or
AUDIO_ENCODING_ALAW, use AUDIO_ENCODING_SLINEAR_LE/16bit for native encoding
instead of AUDIO_ENCODING_ULINEAR/8bit because aurateconv does not support
sampling rate conversion for 8 bit PCM.
This change fixes PR kern/18834.
2002-11-04 16:38:49 +00:00
kent 565a6b3384 Support for 4ch/6ch audio playback with VT8233/VT8235. 2002-10-16 15:27:28 +00:00
kent 54419c891c - Enable in-kernel sampling rate conversion for fixed-rate codec
- Remove VRA/VRM enabling in auvia_attach()
- Use ac97_codec_if::set_rate()
- Return no AUDIO_PROPS_MMAP for fixed-rate codec
- Remove unused variables in auvia_softc
2002-10-08 13:10:24 +00:00
kent e3b5b1897b Revive VIA8233_RP_DXS_[LR]VOL in auvia_trigger_*(). 2002-10-07 16:28:24 +00:00
kent bebbf91a39 - auvia_trigger_output(): correct register;
AUVIA_RP_CONTROL -> AUVIA_RP_MODE
- auvia_trigger_output(), auvia_trigger_input(): Remove DXS_[LR]VOL setting.
- whitespace
2002-10-06 23:14:25 +00:00
kent f06ae93219 Add some constant symbols for AC97 registers and values based on OpenBSD.
Rename some symbols to sync with OpenBSD:
	AC97_REG_EXTENDED_ID
	-> AC97_REG_EXT_AUDIO_ID
	AC97_REG_EXTENDED_STATUS
	-> AC97_REG_EXT_AUDIO_CTRL
	AC97_CODEC_DOES_VRA/AC97_ENAB_VRA
	-> AC97_EXT_AUDIO_VRA
	AC97_CODEC_DOES_MICVRA/AC97_ENAB_MICVRA
	-> AC97_EXT_AUDIO_VRM

ac97feature: "mic channel" -> "dedicated mic channel"
ac97_attach(): print extended capabilities; VRA, DRA, SPDIF, VRM, CDAC,
SDAC, LDAC.
2002-10-06 16:33:35 +00:00
kent 550acc6c64 Add support for VIA VT8233/VT8235. The patch was provided by Ola Eriksson
<ola at mreriksson dot net> in PR kern/18375.  It is based on auvia of
OpenBSD.
2002-10-05 18:08:30 +00:00
thorpej 9b2c2ec24d Add trailing ; to CFATTACH_DECL. 2002-10-02 16:50:59 +00:00
thorpej 387fc6dc87 Use CFATTACH_DECL(). 2002-09-30 20:37:04 +00:00
thorpej f818766afe Declare all cfattach structures const. 2002-09-27 20:31:45 +00:00
provos 0f09ed48a5 remove trailing \n in panic(). approved perry. 2002-09-27 15:35:29 +00:00
fvdl 03295688de Return 0 when no interrupt was handled. 2002-04-02 16:02:38 +00:00
jmcneill 94e84af5fb Backout addition of the VIA VT8233. 2002-03-16 21:45:49 +00:00
jmcneill 5f17e8f802 Add support for the VT8233 AC'97. 2002-03-16 17:20:05 +00:00
lukem 9048aaae21 add RCSID 2001-11-13 07:48:40 +00:00
augustss 1339e88a86 Add a new optional method, dev_ioctl, to the audio hardware driver interface.
It is called when an unrecognized ioctl() is performed on a device,
thus allowing ioctl()s that frob the hardware driver (like loading
microcode).
2001-10-03 00:04:47 +00:00
jdolecek fcc522e5ce It seems the fixed rate versions are actually fixed at 48 kHz, not 44.1 kHz. 2001-08-04 22:15:56 +00:00
fvdl 44467271c4 Switch line in mute off by default. 2001-02-19 21:14:49 +00:00
augustss 49f333783f Don't make local defines for stuff that's already in ac97reg.h. 2001-01-05 03:33:39 +00:00
sommerfeld 851de295eb Change pci_intr_map to get interrupt source information from a "struct
pci_attach_args *" instead of from four separate parameters which in
all cases were extracted from the same "struct pci_attach_args".

This both simplifies the driver api, and allows for alternate PCI
interrupt mapping schemes, such as one using the tables described in
the Intel Multiprocessor Spec which describe interrupt wirings for
devices behind pci-pci bridges based on the device's location rather
the bridge's location.

Tested on alpha and i386; welcome to 1.5Q
2000-12-28 22:59:06 +00:00
jdolecek 48f421c3fa do not try to get/set sample rate on codecs which don't support variable
rate audio - always report/use fixed rate of 44100 for them, so that the
other audio code DTRT
2000-12-10 15:43:02 +00:00
jdolecek 4046a1bd78 if AC97_CODEC_DOES_VRA is not supported, only print warning than
hw Variable Rate Audio is not supported and continue attaching the driver.
This is I believe more correct than what was done in rev 1.5
2000-11-15 21:06:33 +00:00
thorpej cfe0892ed3 NBPG -> PAGE_SIZE 2000-11-14 18:42:55 +00:00
jdolecek 0bc8e23c3a even through the integrated audio on my MSI 694D Pro
does not set AC97_CODEC_DOES_VRA in AC97_REG_EXT_AUDIO_ID request, it
works okay; only require the bit set for revision < 'H'
2000-09-01 00:02:04 +00:00
simonb 889c658b5b Change the kernel mmap interface so that the offset to map is an
"off_t" and the return value is a "paddr_t" to allow mappings
at offsets past 2^31 bytes.  Somewhat inspired by FreeBSD, which
only changed the offset to a "vm_offset_t".

Includes updates for the i386, pc532 and sh3 mmmmap from Jason Thorpe.
2000-06-26 04:55:19 +00:00
thorpej 1838aef29c ac97.h -> ac97var.h 2000-05-15 01:27:44 +00:00
tsarna a1ea15c0e1 Fix auvia_free, clean up more on close, and be more careful in interrupt
handler.
2000-04-08 03:33:58 +00:00
tsarna 07dea214dc Add auvia, a driver for the integrated AC'97 audio on the VIA VT82C686A
southbridge.

Tested on a ASUS K7M (w/ AD1881 codec). Please report any problems.
2000-03-31 04:45:28 +00:00