📄 via82cxxx.txt
字号:
Via motherboard audio driver Copyright 1999,2000 Jeff Garzik <jgarzik@mandrakesoft.com>Driver software and documentation distributed under the GNU GENERALPUBLIC LICENSE (GPL) Version 2. See the "COPYING" file distributed withthis software for more info.Introduction------------------------------------------------------------------------The via82cxxx audio driver found in the drivers/sound directoryof the kernel source tree is a PCI audio driver for audio chipsfound on Via-based motherboards, such as the MVP4.Currently the driver exports the following features: * /dev/dsp and /dev/audio support * 16-bit stereo PCM output channel * AC97 mixerPlease send bug reports to the mailing list linux-via@gtf.org.To subscribe, e-mail majordomo@gtf.org with "subscribe linux-via" in thebody of the message.Thanks------------------------------------------------------------------------Via for providing e-mail support, specs, and NDA'd source code.MandrakeSoft for providing hacking time.AC97 mixer interface fixes and debugging by Ron Cemer <roncemer@gte.net>Installation------------------------------------------------------------------------If the driver is being statically compiled into the kernel, noconfiguration should be necessary.If the driver is being compiled as a module, generally one line mustbe added to your /etc/conf.modules (or /etc/modules.conf) file: alias sound via82cxxx_audioDriver notes------------------------------------------------------------------------Two /proc pseudo-files provide diagnostic information. This is generallynot useful to most users. Power users can disable VIA_PROC_FS macro in the driver source code, and remove the /proc support code. In any case, onceversion 2.0.0 is released, the /proc support code will be disabled bydefault. Available /proc pseudo-files: /proc/driver/via/0/info /proc/driver/via/0/ac97This driver by default supports all PCI audio devices which reporta vendor id of 0x1106, and a device id of 0x3058. Subsystem vendorand device ids are not examined.Only supports a single sound chip, as this is a motherboard chipset.Some architecture remains for multiple cards, feel free to submita patch to clean some of that up. Ideally, No consideration for SMP, this chipset is not known to be found onany SMP motherboards. However, spin_locks must be used anyway in orderto handle interrupts correctly.GNU indent formatting options: -kr -i8 -pcsTested Hardware------------------------------------------------------------------------The following is an _incomplete_ list of motherboards supported by thisaudio driver. If your motherboard (or notebook) is not listed here,please e-mail the maintainer with details. AOpen MX59 Pro Compaq Presario 1247Random Developer Notes / Comments------------------------------------------------------------------------Via has graciously donated e-mail support and source code to help furtherthe development of this driver. Their assistance has been invaluablein the design and coding of the next major version of this driver.The Via audio chip apparently provides a second PCM scatter-gatherDMA channel just for FM data, but does not have a full hardware MIDIprocessor. I haven't put much thought towards a solution here, but itmight involve using SoftOSS midi wave table, or simply disabling MIDIsupport altogether and using the FM PCM channel as a second (input? output?)General To-do List (patches/suggestions welcome)------------------------------------------------------------------------Recording supportmmap supportOther advanced ioctlsBetter docsCode reviewNative MIDI driver, as described aboveKnown bugs (patches/suggestions welcome)------------------------------------------------------------------------1) Volume too low on many systems. Workaround: use mixer programsuch as xmixer to increase volume.2) RealPlayer output very scratchy. Workaround: use esd, andconfigure RealPlayer to output to esd.3) Applications which attempt to open the sound device in read/writemode (O_RDWR) will fail. This is incorrect OSS behavior, but sincethis driver will eventually support recording as well as playback,we will be able to (in the future) support even broken programs whichunconditionally use O_RDWR.Submitting a bug report------------------------------------------------------------------------Describe the application you were using to play/record sound, and howto reproduce the problem.Obtain the via-audio-diag diagnostics program fromhttp://gtf.org/garzik/drivers/via82cxxx/ and provide a dump of theaudio chip's registers while the problem is occurring. Sample command line: ./via-audio-diag -aps > diag-output.txtDefine "VIA_DEBUG" at the beginning of the driver, then capture and emailthe kernel log output. This can be viewed in the system kernel log (ifenabled), or via the 'dmesg' program.If you wish to increase the size of the buffer displayed by 'dmesg', thenchange the LOG_BUF_LEN macro at the top of linux/kernel/printk.c, recompileyour kernel, and pass the "-s <size>" option to 'dmesg'.Change history------------------------------------------------------------------------Version 1.1.7:* Fix module unload bug where mixer device left registered after driver exitVersion 1.1.6:* Rewrite via_set_rate to mimic ALSA basic AC97 rate setting* Remove much dead code* Complete spin_lock_irqsave -> spin_lock_irq conversion in via_dsp_ioctl* Fix build problem in via_dsp_ioctl* Optimize included headers to eliminate headers found in linux/drivers/soundVersion 1.1.5:* Disable some overly-verbose debugging code* Remove unnecessary sound locks* Fix some ioctls for better time resolution* Begin spin_lock_irqsave -> spin_lock_irq conversion in via_dsp_ioctlVersion 1.1.4:* Completed rewrite of driver. Eliminated SoundBlaster compatibility completely, and now uses the much-faster scatter-gather DMA engine.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -