summaryrefslogtreecommitdiff
path: root/sound/pci/oxygen/virtuoso.c
AgeCommit message (Collapse)Author
2014-09-22ALSA: virtuoso: add partial Xonar Xense supportHarley Griggs
This patch adds partial support for the Xonar Xense. [trivial coding style fixes by tiwai] Signed-off-by: Harley Griggs <hgriggs@posteo.co.uk> Acked-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2014-08-12PCI: Remove DEFINE_PCI_DEVICE_TABLE macro useBenoit Taine
We should prefer `struct pci_device_id` over `DEFINE_PCI_DEVICE_TABLE` to meet kernel coding style guidelines. This issue was reported by checkpatch. A simplified version of the semantic patch that makes this change is as follows (http://coccinelle.lip6.fr/): // <smpl> @@ identifier i; declarer name DEFINE_PCI_DEVICE_TABLE; initializer z; @@ - DEFINE_PCI_DEVICE_TABLE(i) + const struct pci_device_id i[] = z; // </smpl> [bhelgaas: add semantic patch] Signed-off-by: Benoit Taine <benoit.taine@lip6.fr> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
2014-08-04ALSA: virtuoso: add Xonar Essence STX II supportClemens Ladisch
Just add the PCI ID for the STX II. It appears to work the same as the STX, except for the addition of the not-yet-supported daughterboard. Tested-by: Mario <fugazzi99@gmail.com> Tested-by: corubba <corubba@gmx.de> Cc: <stable@vger.kernel.org> Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-12-07ALSA: oxygen: remove __dev* attributesBill Pemberton
CONFIG_HOTPLUG is going away as an option. As result the __dev* markings will be going away. Remove use of __devinit, __devexit_p, __devinitdata, __devinitconst, and __devexit. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Acked-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-11-05ALSA: virtuoso: Xonar DSX supportSergiu Giurgiu
This patch adds support for ASUS - Xonar DSX sound cards. Tested on openSUSE 12.2 with kernel: Linux 3.4.6-2.10-desktop #1 SMP PREEMPT Thu Jul 26 09:36:26 UTC 2012 (641c197) x86_64 x86_64 x86_64 GNU/Linux Works: - play sounds - adjust volume on master channel. - mute . Since Xonar DS uses the same chip, everything that works for DS should work for DSX as well. Signed-off-by: Sergiu Giurgiu <sgiurgiu11@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-08-14ALSA: PCI: Replace CONFIG_PM with CONFIG_PM_SLEEPTakashi Iwai
Otherwise we may get compile warnings due to unused functions. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-07-03ALSA: Convert to new pm_ops for PCI driversTakashi Iwai
Straightforward conversion to the new pm_ops from the legacy suspend/resume ops. Since we change vx222, vx_core and vxpocket have to be converted, too. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2012-04-24ALSA: pci: clean up using module_pci_driver()Takashi Iwai
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2011-12-19ALSA: module_param: make bool parameters really boolRusty Russell
module_param(bool) used to counter-intuitively take an int. In fddd5201 (mid-2009) we allowed bool or int/unsigned int using a messy trick. It's time to remove the int/unsigned int option. For this version it'll simply give a warning, but it'll break next kernel version. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2011-10-31sound: Add module.h to the previously silent sound usersPaul Gortmaker
Lots of sound drivers were getting module.h via the implicit presence of it in <linux/device.h> but we are going to clean that up. So fix up those users now. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
2011-06-10ALSA: Use KBUILD_MODNAME for pci_driver.name entriesTakashi Iwai
The convention for pci_driver.name entry in kernel drivers seem to be the module name or equivalent ones. But, so far, almost all PCI sound drivers use more verbose name like "ABC Xyz (12)", and these are fairly confusing when appearing as a file name. This patch converts the all pci_driver.name entries in sound/pci/* to use KBUILD_MODNAME for more unified appearance. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-10-05ALSA: virtuoso: add HDAV1.3 Slim PCI IDClemens Ladisch
Add a PCI ID for the Xonar HDAV1.3 Slim. There is no actual support, but the presence of the ID allows the EEPROM repair code to work for this card. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-10-05ALSA: virtuoso: fix Xonar DS chip nameClemens Ladisch
The controller on the Xonar DS is labeled "AV66", not "AV200". Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-09-08ALSA: virtuoso: work around missing reset in the Xonar DS Windows driverClemens Ladisch
For the WM8776 chip, this driver uses a different sample format and more features than the Windows driver. When rebooting from Linux into Windows, the latter driver does not reset the chip but assumes all its registers have their default settings, so we get garbled sound or, if the output happened to be muted before rebooting, no sound. To make that driver happy, hook our driver's cleanup function into the shutdown notifier and ensure that the chip gets reset. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Reported-and-tested-by: Nathan Schagen Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-02-09sound: use DEFINE_PCI_DEVICE_TABLEAlexey Dobriyan
Use DEFINE_PCI_DEVICE_TABLE() to make PCI device ids go to .devinit.rodata section, so they can be discarded in some cases, and make them const. Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2010-01-18sound: virtuoso: add Xonar DS supportClemens Ladisch
Add experimental support for the Asus Xonar DS. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2009-09-28sound: virtuoso: split virtuoso.cClemens Ladisch
The virtuoso.c file has become rather big. This patch splits it up so that only code for very similar card models is in one file. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-07-02sound: virtuoso: fix Xonar D1/DX silence after resumeClemens Ladisch
When resuming, we better take the DACs out of the reset state before trying to use them. Reference: kernel bug #13599 http://bugzilla.kernel.org/show_bug.cgi?id=13599 Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-25sound: virtuoso: add Xonar Essence ST supportClemens Ladisch
Add support for the Asus Xonar Essence ST and its daughterboard. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-25sound: virtuoso: enable HDAV S/PDIF inputClemens Ladisch
The Xonar HDAV1.3 has a digital input jack, so enable the corresponding device. This is not related to the HDMI stuff, which stays unsupported. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-05-25sound: virtuoso: add another DX PCI IDClemens Ladisch
Add another PCI ID for a second revision of the Xonar DX. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-02-26sound: virtuoso: add Xonar Essence STX supportClemens Ladisch
Add support for the Asus Xonar Essence STX sound card. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-02-20sound: virtuoso: increase minimum volume to -60 dBClemens Ladisch
Use -60 dB as the minimum value of the master volume mixer control. While the DACs would support ranges down to about -120 dB, such attenuations are not useful in practice. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-02-19sound: oxygen: handle cards with broken EEPROMClemens Ladisch
Under as yet unknown circumstances, the first word of the sound card's EEPROM gets overwritten. When this has happened, we cannot rely on the subsystem IDs that the kernel reads from the PCI configuration registers. Instead, we read the IDs directly from the EEPROM and do the ID matching manually. Because the model-specific driver cannot determine the model before calling oxygen_pci_probe(), that function now gets a get_model() callback as parameter. The customizing of the model structure, which was formerly done by the probe() callback, also has moved into get_model(). Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-02-19sound: oxygen: make the owner module a parameter of the probe functionClemens Ladisch
Move the owner field out of the oxygen_model structure and make it a parameter of oxygen_pci_probe(), because the actual owner module does not depend on the card model. Furthermore, moving it out of the model structure allows us to create the card structure before the actual model is known. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-02-19sound: virtuoso: revert "do not overwrite EEPROM on Xonar D2/D2X"Clemens Ladisch
This reverts commit 7e86c0e6850504ec9516b953f316a47277825e33 ("do not overwrite EEPROM on Xonar D2/D2X") because it did not actually help with the problem. More user reports show that the overwriting of the EEPROM is not triggered by using this driver but by installing Linux, and that the installation of any other operating system (even one without any CMI8788 driver) has the same effect. In other words, the presence of this driver does not have any effect on the occurrence of the error. (So far, the available evidence seems to point to a BIOS bug.) Furthermore, it turns out that the EEPROM chip is protected against stray write commands by the command format and by requiring a separate write-enable command, so the error scenario in the previous commit (that SPI writes can be misinterpreted as an EEPROM write command) is not even theoretically possible. The mixer control that was removed as a consequence of the previous commit can only be partially emulated in userspace, which also means it cannot be seen be the in-kernel OSS API emulation, so it is better to revert that change. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-01-19sound: virtuoso: add newlineClemens Ladisch
Add a missing newline. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-01-19sound: virtuoso: enable UART on Xonar HDAV1.3Clemens Ladisch
This hardware has a better chance of working correctly if we don't forget to enable it. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2009-01-15sound: virtuoso: do not overwrite EEPROM on Xonar D2/D2XClemens Ladisch
On the Asus Xonar D2 and D2X models, the SPI chip select signal for the fourth DAC shares its pin with the serial clock for the EEPROM that contains the PCI subdevice ID values. It appears that when DAC registers are written and some other unknown conditions occur (probably noise on the EEPROM's chip select line), the EEPROM gets overwritten with garbage, which makes it impossible to properly detect the card later. Therefore, we better avoid DAC register writes and make sure that the driver works with the DAC's registers' default values. Consequently, the sample format is now I2S instead of left-justified (no user-visible change), and the DAC's volume/mute registers cannot be used anymore (volume changes are now done by the software volume plugin). Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Cc: <stable@kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-09-22ALSA: virtuoso: add Xonar HDAV1.3 supportClemens Ladisch
Add support for the Asus Xonar HDAV1.3 and the Xonar HDAV1.3 Deluxe. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: virtuoso: rename AC97 callback functionClemens Ladisch
Rename the callback function that switches between line and mic inputs on the Xonar D1 because it is also usable on other models. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: virtuoso: make number of PCM1796 DACs configurableClemens Ladisch
Do not use a hardcoded number when iterating over the PCM1796 DACs to allow for cards with a different number of analog output channels. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: virtuoso: allow I2C-connected PCM1796Clemens Ladisch
Add support for PCM1796 chips that are connected with an I2C bus instead of SPI. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: oxygen: add self-documenting functionsClemens Ladisch
Introduce some trivial functions to better document the relationships of the various model callbacks. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: oxygen: configure MIDI via device_configClemens Ladisch
To enable the MIDI port, model drivers must now set flags in device_config, not only in misc_flags. This allows model drivers to enable the UART without creating an ALSA MIDI device. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: oxygen: rename pcm_dev_cfgClemens Ladisch
Rename the pcm_dev_cfg field to device_config because there will be additional flags that do not describe PCM devices. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: virtuoso: create common functions for GPIO bit switch controlsClemens Ladisch
Factor out the common code of the mixer callbacks that handle controls that just switch a single GPIO bit. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: virtuoso: handle D2X/DX dynamicallyClemens Ladisch
The Xonar D2X and DX are very similar to the D2 and D1, respectively, so we can handle the differences dynamically instead of using a separate model structure for each one. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-09-22ALSA: oxygen: add probe callbackClemens Ladisch
Add a probe callback to the model structure so that model-specific drivers can refine their model detection before the card is initialized. Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
2008-08-14ALSA: virtuoso: add Xonar D1 supportClemens Ladisch
Add support for the Asus Xonar D1. It is the same as the DX, but without the external power detection. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-05-19[ALSA] oxygen: add PM supportClemens Ladisch
Add suspend/resume support. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-05-19[ALSA] virtuoso: add xonar_enable_output()Clemens Ladisch
Move the setting of the output enable GPIO bit to a separate function. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-05-19[ALSA] oxygen: separate out hardware initialization codeClemens Ladisch
Create separate functions for the code that initializes the hardware, as opposed to initializing internal driver state, so that they can be reused for resume support. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-05-19[ALSA] oxygen: simplify DAC volume initializationClemens Ladisch
When initializing the DAC volume registers, we can just use the generic volume update functions instead of setting the registers manually. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-05-19[ALSA] oxygen: save register writesClemens Ladisch
Save the written values of all CMI8788 and AC97 registers and of some of the DAC/ADC registers so that it is possible to restore the register state later. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-05-19[ALSA] oxygen: fix version in MODULE_LICENSEClemens Ladisch
Adjust the MODULE_LICENSE strings to properly reflect the actual license. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
2008-04-24[ALSA] oxygen: generalize DAC volume TLV handlingClemens Ladisch
Add a pointer for DAC volume TLV data to the model structure so that the model driver do not need to manually assign it in their control filter. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24[ALSA] oxygen: mute by defaultClemens Ladisch
Initialize the playback volume controls as being muted and having minimal volume. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24[ALSA] oxygen: generalize handling of DAC volume limitsClemens Ladisch
Add fields for the DAC volume limits to the module structure so that model drivers do not need to install their own control info handlers. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2008-04-24[ALSA] virtuoso: fix DX front panel I/OClemens Ladisch
Fix the GPIO 1 mixer control to enable I/O through the front panel connector of the Xonar DX. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>