summaryrefslogtreecommitdiff
path: root/sound/pci/hda/patch_realtek.c
AgeCommit message (Collapse)AuthorFilesLines
2013-04-25ALSA: hda - Add the support for ALC286 codecKailang Yang1-0/+6
It's yet another ALC269-variant. Signed-off-by: Kailang Yang <kailang@realtek.com> Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-22ALSA: hda - Limit internal mic boost for a few Asus machinesDavid Henningsson1-1/+41
These are being reported as being so noisy at high mic boost levels, so they are unusable in practice. Therefore artificially limit the boosts. BugLink: https://bugs.launchpad.net/bugs/1089795 Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-18ALSA: hda - fix error return code in patch_alc662()Wei Yongjun1-1/+2
Fix to return a negative error code from the error handling case instead of 0, as returned elsewhere in this function. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-15Merge tag 'asoc-v3.10' of ↵Takashi Iwai1-1/+3
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next ASoC: Updates for v3.10 A bunch of changes here, the most interesting one subsystem wise being Morimoto-san's work to create snd_soc_component which doesn't do much for now but will be pretty important going forwards: - Add a new component object type which will form the basis of moving to a more generic handling of SoC and off-SoC components, contributed by Kuninori Morimoto. - A fairly large set of cleanups for the dmaengine integration from Lars-Peter Clausen, starting to move towards being able to have a generic driver based on the library. - Performance optimisations to DAPM from Ryo Tsutsui. - Support for mixer control sharing in DAPM from Stephen Warren. - Multiplatform ARM cleanups from Arnd Bergmann. - New CODEC drivers for AK5385 and TAS5086 from Daniel Mack.
2013-04-15ALSA: hda - Fix headset mic support for Asus X101CHDavid Henningsson1-0/+56
With this patch, a TRRS headset mic cannot be successfully detected on the Asus X101CH, and we can also distinguish between headphone and headset automatically. Buglink: https://bugs.launchpad.net/bugs/1169138 Co-authored-by: Kailang <kailang@realtek.com> Tested-by: Luis Henriques <luis.henriques@canonical.com> Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-15ALSA: hda - Implement headset jack functionality for some Dell hwDavid Henningsson1-0/+386
On some machines, there is a headset jack that can support both headphone, headsets (of both CTIA and OMTP type) and mic-in. On other machines, the headset jack supports headphone, headsets (both CTIA and OMTP), but not mic-in. This patch implements that functionality as different capture sources. Buglink: https://bugs.launchpad.net/bugs/1169143 Tested-by: David Chen <david.chen@canonical.com> Co-authored-by: Kailang <kailang@realtek.com> Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-07ALSA: hda/realtek - Add a quirk for AC700 Chromebook.Dylan Reid1-1/+17
Correct pin configs for the Acer AC700. Most importantly indicate that SPDIF is connected, it routes to HDMI out. Similar to Aspire models, chain in the DMIC fixup and allow it to be applied to this codec (ALC269VB) as well. Signed-off-by: Dylan Reid <dgreid@chromium.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-04-04ALSA: hda - Enabling Realtek ALC 671 codecRainer Koenig1-1/+3
* Added the device ID to the modalias list and assinged ALC662 patches for it * Added 4 port support for the device ID 0671 in alc662_parse_auto_config Signed-off-by: Rainer Koenig <Rainer.Koenig@ts.fujitsu.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-18ALSA: hda - Add GPIO-based LED support on HP desktop machinesTakashi Iwai1-0/+63
The new HP desktop machines have Realtek codecs and their LEDs are controlled via GPIO as for many laptop models. Add similar hooks as well as in patch_sigmatel.c for controlling LEDs. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-18ALSA: hda - Move beep attach/detach calls in hda_generic.cTakashi Iwai1-74/+32
Instead of calling snd_hda_attach_beep_device() and snd_hda_detach_beep_device() in each codec driver, move them to the generic parser. The codec driver just needs to set spec->beep_nid for activating the digital beep. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-18Merge branch 'for-linus' into for-nextTakashi Iwai1-0/+2
Back-merged for refactoring beep stuff.
2013-03-07ALSA: hda - Consolidate add_in_jack_modes and add_out_jack_modes hintsTakashi Iwai1-2/+1
There is no big merit to distinguish these two hints. Instead, just have a single flag, add_jack_modes, for creating the jack mode enum ctls for both I/O directions. The hint string parser code is left and translated as add_jack_modes just for keeping compatibility. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-07ALSA: hda - Add some model name strings for ALC260Takashi Iwai1-7/+27
In order to let user test the known workaround more easily, give a few known fixups for ALC260 to the model strings so that it can be passed via the module option. Also, move the unusual setups found in FSC S7020 fixup into a special model, fujitsu-jwse, Jonathan Woithe Special Edition. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-03-07ALSA: hda - Add support of new codec ALC233Kailang Yang1-0/+2
It's compatible with ALC282. Signed-off-by: Kailang Yang <kailang@realtek.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-25ALSA: hda - Enable beep for ASUS EeeBox EBP1501PTakashi Iwai1-0/+1
Reported-by: Harald Becker <ralda@gmx.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-18ALSA: hda - Fix the silent speaker output on Fujitsu S7020 laptopTakashi Iwai1-1/+7
In the recent update, Fujitsu S7020 laptop with ALC260 codec lost the speaker output, no matter how the amps and the pins are set. After a long debugging session, we found out that the default codec init code is harmful for this machine, and we have to reset it to ALC_INIT_NONE. Reported-and-tested-by: Jonathan Woithe <jwoithe@just42.net> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-18ALSA: hda - add quirks for mute LED on two HP machinesDavid Henningsson1-0/+19
These two machines have no mute LED string in BIOS. BugLink: https://bugs.launchpad.net/bugs/1128934 Tested-by: Tammy Yang <tammy.yang@canonical.com> Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-12ALSA: hda - update documentation for no-primary-hp fixupFernando Luis Vázquez Cao1-1/+2
The problem addressed by this fixup is not specific to Vaio Z, affecting some Vaio all-in-one desktop PCs too. Update the code comments accordingly. Signed-off-by: Fernando Luis Vazquez Cao <fernando@oss.ntt.co.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-12ALSA: hda - Workaround for silent output on Sony Vaio VGC-LN51JGB with ALC889Fernando Luis Vázquez Cao1-0/+1
Some Vaio all-in-one desktop PCs (for example VGC-LN51JGB) are affected by the same issue that caused Vaio Z laptops to become silent: the speaker pin must be connected to the first DAC even though the codec itself advertises flexible routing through any of the DACs. Use the no-primary-hp fixup for choosing the speaker pin as the primary so that the right DAC is assigned on this device. Cc: stable@vger.kernel.org Signed-off-by: Fernando Luis Vazquez Cao <fernando@oss.ntt.co.jp> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-02-05Merge branch 'for-linus' into for-nextTakashi Iwai1-0/+1
Merge pending fixes that haven't pulled into 3.8.
2013-01-28ALSA: hda - fix inverted internal mic on Acer AOA150/ZG5David Henningsson1-0/+1
This patch enables internal mic input on the machine. Cc: stable@vger.kernel.org BugLink: https://bugs.launchpad.net/bugs/1107477 Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-23ALSA: hda - Add auto-mute support to PB desktopTakashi Iwai1-1/+12
Using the new chained_before flag, we can correct the headphone jack detection capability easily over the existing ALC880 6stack model (which disables the jack detection intentionally for compatibility reason). Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=901846 Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-23Merge branch 'for-linus' into for-nextTakashi Iwai1-0/+1
Merge the 3.8 devel branch for correcting the newly added PB desktop fixup with the automute support.
2013-01-23ALSA: hda - Add a fixup for Packard-Bell desktop with ALC880Takashi Iwai1-0/+1
A Packard-Bell desktop machine gives no proper pin configuration from BIOS. It's almost equivalent with the 6stack+fp standard config, just take the existing fixup. Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=901846 Cc: <stable@vger.kernel.org> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-23ALSA: hda - Fix invalid snd_BUG_ON() in alc271_hp_gate_mic_jack()Takashi Iwai1-4/+5
The fixup function is called multiple times before parsing the pins, so snd_BUG_ON() hits when loaded. Move it to the proper place in the if block. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-23Merge branch 'topic/hda-gen-parser' into for-nextTakashi Iwai1-3816/+496
This is a merge of really big changes: the generic parser is heavily enhanced for handling all cases, based on the former Realtek codec driver code. And all codec drivers except for a few ones (CA0132, HDMI and modem) have been converted to use the new generic driver. Conflicts: sound/pci/hda/patch_realtek.c
2013-01-22ALSA: hda - Combine snd_hda_codec_flush_*_cache() to a single functionTakashi Iwai1-1/+1
Since both snd_hda_codec_flush_amp_cache() and snd_hda_codec_flush_cmd_cache() are called usually at the same time, we can simply combine them to a single function, snd_hda_codec_flush_cache(). Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-21ALSA: hda - Remove superfluous header inclusionsTakashi Iwai1-1/+0
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-19ALSA: hda - Add fixup for Acer AO725 laptopTakashi Iwai1-0/+1
Acer AO725 needs the same fixup as AO756. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=52181 Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-18ALSA: hda - Fix speaker pin of FSC Lifebook S7110 laptopTakashi Iwai1-1/+11
Some BIOS version of FSC Lifebook S7110 laptop seems to give a wrong default pin config for NID 0x15, which confuses the parser. Give a fixup to correct the value. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-18ALSA: hda - Consolidate cap_sync_hook and capture_switch_hookTakashi Iwai1-1/+2
Two hooks in hda_gen_spec, cap_sync_hook and capture_switch_hook, play very similar roles. The only differences are that the former is called more often (e.g. at init or switching capsrc) while the latter can take an on/off argument. As a more generic implementation, consolidate these two hooks, and pass snd_ctl_elem_value pointer as the second argument. If the secondary argument is non-NULL, it can take the on/off value, so the caller handles it like the former capture_switch_hook. If it's NULL, it's called in the init or capsrc switch case. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-18ALSA: hda - Fix mute led for another HP machineDavid Henningsson1-0/+1
This machine also has the "HP_Mute_LED_0_A" string in DMI information. Cc: <stable@vger.kernel.org> BugLink: https://bugs.launchpad.net/bugs/1096789 Tested-by: Tammy Yang <tammy.yang@canonical.com> Signed-off-by: David Henningsson <david.henningsson@canonical.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-15ALSA: hda - Add prefer_hp_amp flag to hda_gen_specTakashi Iwai1-2/+5
Add a new flag to indicate whether HP amp is turned on as default for speaker or line-outs, and enable this for ALC260 codec, as many machines with this codec require the HP amp even for speakers. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Generic mute LED implementation for HP laptopsTakashi Iwai1-28/+48
As David Henningsson recently suggested, some HP laptops use an unused mic pin for controlling a mute LED, and this information is provided via DMI string "HP_Mute_LED_X_Y" string. This patch adds the generic support for such cases, as we've already done in patch_sigmatel.c. This is applied generically to all devices with ID 0x103c. But as we don't know whether the device 103c:1586 really contains HP_Mute_LED_X_Y DMI string, still keep the static setup for this device using the mic2 pin 0x19. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Fix the timing for some fixupsTakashi Iwai1-3/+3
Some fixups such as setting the flags influencing on the parser behavior should be applied before actually parsing the tree. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Add a fixup for FSC S7020 laptopTakashi Iwai1-0/+17
Try to recover from the regression: set the HP amp for the speaker and add the hp jack mode enum as default. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Add a new fixup type to override pinctl valuesTakashi Iwai1-9/+9
Add a new fixup type, HDA_FIXUP_PINCTLS, for overriding the pinctl values of the given pins. It takes the same array of struct pintbl like HDA_FIXUP_PINS, but each entry contains the pinctl value instead of the pin default config value. This patch also replaces the corresponding codes in patch_realtek.c. Without this change, the direct call of verbs may be overridden again by the later call of pinctl restoration by the driver. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Read the cached pinctl value in fixupsTakashi Iwai1-6/+3
... instead of reading the value from the codec at each time. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Drop aliases for old fixupsTakashi Iwai1-269/+252
Now the whole codebase has been changed from the earlier kernels, it makes little sense to keep these aliases. Simply replace with the official names. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Add snd_hda_gen_free() and snd_hda_gen_check_power_status()Takashi Iwai1-11/+1
Just to remove duplicated codes. Also fixed EXPORT_SYMBOL() in hda_generic.c. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Add spec->vmaster_mute_enum flag to generic parserTakashi Iwai1-2/+6
Add a flag to indicate whether the vmaster mute hook enum is exposed or not. Conexant codecs may want not to expose the control depending on the model. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Add snd_hda_codec_flush_*_cache() aliasesTakashi Iwai1-1/+1
It makes easier to understand although these are identical with snd_hda_codec_resume_*() functions. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Flush dirty amp caches before writing inv_dmic fixTakashi Iwai1-0/+3
The inverted dmic fix overwrites the right channel amp value, but it would work only when the amp values have been already actually written. Put snd_hda_codec_resume_amp() before the amp write for flushing caches. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Use generic parser codes for Realtek driverTakashi Iwai1-3634/+126
The next migration step is to use the common code in generic driver for Realtek driver. This is no drastic change and there should be no real functional changes, as the generic parser code comes from Realtek driver originally. As Realtek driver requires the generic parser code, it needs a reverse-selection of CONFIG_SND_HDA_GENERIC kconfig. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Remove redundant argument from alc_mux_select()Takashi Iwai1-5/+5
The argument "force" is always false in the recent code. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - More generic auto-mic switching for Realtek codecsTakashi Iwai1-65/+78
This patch extends the capability of the auto-mic feature. Instead of limiting the automatic input-source selection only to the mics (internal, external and dock mics), allow it for generic inputs, e.g. switching between the rear line-in and the front mic. The logic is to check the attribute and location of input pins, and enable the automatic selection feature only if all such pins are in different locations (e.g. internal, front, rear, etc) and line-in or mic pins. That is, if multiple input pins are assigned to a single location, the feature isn't enabled because we don't know the priority. (You may wonder why this restriction doesn't exist for the headphone automute. The reason is that the output case is different from the input: the input source is an exclusive selection while the output can be multiplexed.) Note that, for avoiding regressions, the line-in auto switching feature isn't activated as default. It has to be set explicitly via spec->line_in_auto_switch flag in a fixup code. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Fix split stereo dmic codeTakashi Iwai1-22/+36
The previous commit passed an utterly wrong value for checking the split inv dmic pin. This patch fixes it and also tries to remove inv_dmic_split_idx field. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda - Move fixup code into struct hda_codecTakashi Iwai1-7/+3
Since the fixup code is used commonly, it's worth to move it to the common place, struct hda_codec, instead of keeping in hda_gen_spec. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Add conexant-style inverted dmic handlingTakashi Iwai1-1/+34
To make the parser more generic, a few codes to handle the inverted stereo dmic in a way Conexant parser does is added in this patch. The caller should set spec->inv_dmic_split flag appropriately. Signed-off-by: Takashi Iwai <tiwai@suse.de>
2013-01-12ALSA: hda/realtek - Allow multiple individual capture volume/switch controlsTakashi Iwai1-18/+131
So far we create only "Capture Volume" and "Capture Switch" controls for binding all possible amps, but we'd prefer creating individual capture volume and switch controls per input in some cases (e.g. conexant parser does it). Add a new flag, spec->multi_cap_vol, to follow that policy. Signed-off-by: Takashi Iwai <tiwai@suse.de>