Pull trivial branch from Jiri Kosina:
"Usual stuff -- comment/printk typo fixes, documentation updates, dead
code elimination."
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (39 commits)
HOWTO: fix double words typo
x86 mtrr: fix comment typo in mtrr_bp_init
propagate name change to comments in kernel source
doc: Update the name of profiling based on sysfs
treewide: Fix typos in various drivers
treewide: Fix typos in various Kconfig
wireless: mwifiex: Fix typo in wireless/mwifiex driver
messages: i2o: Fix typo in messages/i2o
scripts/kernel-doc: check that non-void fcts describe their return value
Kernel-doc: Convention: Use a "Return" section to describe return values
radeon: Fix typo and copy/paste error in comments
doc: Remove unnecessary declarations from Documentation/accounting/getdelays.c
various: Fix spelling of "asynchronous" in comments.
Fix misspellings of "whether" in comments.
eisa: Fix spelling of "asynchronous".
various: Fix spelling of "registered" in comments.
doc: fix quite a few typos within Documentation
target: iscsi: fix comment typos in target/iscsi drivers
treewide: fix typo of "suport" in various comments and Kconfig
treewide: fix typo of "suppport" in various comments
...
The runtime_idle callback is the right place to check the suspend
capability, but currently we do it wrongly in the runtime_suspend
callback. This leads to a kernel error message like:
pci_pm_runtime_suspend(): azx_runtime_suspend+0x0/0x50 [snd_hda_intel] returns -11
and the runtime PM core would even repeat the attempts.
Reported-and-tested-by: Borislav Petkov <bp@alien8.de>
Cc: <stable@vger.kernel.org> [v3.7]
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Acer Aspire One 522 has the infamous digital mic unit that needs the
phase inversion fixup for stereo.
Bugzilla: https://bugzilla.novell.com/show_bug.cgi?id=715737
Cc: <stable@vger.kernel.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The HD-audio driver artificially calls the suspend and the resume code
path in the VGA switcheroo state changes. When a machine goes to
suspend, it tries to suspend the device again, and it stalls at
snd_power_wait().
This patch adds checks whether the devices were already in (forced)
suspend in PM callbacks for avoiding the doubly suspend.
Reported-by: Daniel J Blueman <daniel@quora.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When the HD-audio controller is disabled (e.g. via vga switcheroo) but
the driver is still accessing it, it spews floods of "spurious
response" kernel messages. It's because CORB/RIRB WP reads 0xff, and
the driver tries to fill up until this number.
This patch changes the CORB/RIRB WP reads to word instead of byte, and
add the check of the read value. If it's 0xffff, the controller is
supposed to be disabled, so the further action will be skipped.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Reducing the time on HDA link reset can help to reduce the driver loading
time. So we replace msleep with usleep_range to get more accurate time
control and change the value to a smaller one. And a 100ms timeout is set
for both entering and exiting the link reset.
Signed-off-by: Xingchao Wang <xingchao.wang@intel.com>
Signed-off-by: Mengdong Lin <mengdong.lin@intel.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add support for new codec VT1808, which is similiar with VT1705CF.
Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Add support for new codec VT1705CF.
When power on/off Audio output converter of VT1705CF, the stream tag
will be cleared. But driver caches the value. So when power on Audio
output converter, the update_conv_power_state() will restore the saved
stream tag of it.
Signed-off-by: Lydia Wang <lydiawang@viatech.com.cn>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Remove the leftover __devinit* in comments.
They have been commented out because they couldn't fit with __dev*
although they should have matched.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Since __devinit* have been removed completely, DELAYED_INIT*_MARK in
hda_intel.c became NOP. Let's rip them off.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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>
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>
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>
Cc: Thibaut Varene <T-Bone@parisc-linux.org>
Cc: linux-parisc@vger.kernel.org
Signed-off-by: Takashi Iwai <tiwai@suse.de>
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>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
When printing, use a prefix of the PCI domain, bus, device and function
as in other drivers, to differentiate multiple devices.
Important for reporting and debugging. A future step is to tidy this up with
dev_printk et al.
v2: Move conversion specifier into call site, preventing build issues
v3: Refactor for Takashi's for-next branch
Signed-off-by: Daniel J Blueman <daniel@quora.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The recent fix for vga switcheroo race in commit 128960a9 opened yet
another race. At the time the audio driver starts probing, user may
turn off D-GPU off. But at this moment, the audio driver still
doesn't register the vga switcheroo client, thus the switching isn't
notified. Then the hardware gets off out of sudden, resulting in
invalid reads and lots of "spurious response" error messages.
For solving this situation, the following changes have been done in
this patch:
- Move again vga switcheroo registration to the very early stage of
the probing; this also requires to set pci drvdata properly before
registration
- Introduce the completion to synchronize the driver probe at vga
switcheroo callbacks; this assures that the whole probing finished
before executing the callbacks
Reported-by: Daniel J Blueman <daniel@quora.org>
Tested-by: Daniel J Blueman <daniel@quora.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
With HDSPM_TOGGLE_SETTING in place, these functions are no longer
required. Removing them makes the code DRY and considerably shorter.
Signed-off-by: Adrian Knoth <adi@drcomp.erfurt.thur.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
HDSPM_TOGGLE_SETTING and its corresponding functions allow to change
settings in the control register. Instead of using the specialised
functions, use the generic code to make the code DRY.
Signed-off-by: Adrian Knoth <adi@drcomp.erfurt.thur.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The driver contains at least six similar functions that change only a
single bit in the control register, only the bit position varies.
This patch implements a generic function to toggle a certain bit
position that will be used to replace the old code.
Signed-off-by: Adrian Knoth <adi@drcomp.erfurt.thur.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The current Realtek driver reconfigures the max PCM channels
dynamically according to the value of Channel Mode enum if the
multi-io retasking is available. It works fine for multi-io pins.
But when multiple speaker pins are available, the channels of speakers
also have to obey to the channel mode, which isn't nice.
(That is, when you select "2ch" in Channel Mode so that the line-in
and mic jack behave as input, you can't play surrounds properly from
the built-in speaker.)
This patch fixes the problem by taking the channel number for multiple
speakers into account in the channel-mode setup code.
Also it fixes the wrongly set up max_channels value in the case of
multi-io extension.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Very quiet release for ASoC really:
- Standardisation of the logging.
- DT and dmaengine support for Atmel.
- Support for Wolfson ADSP cores.
- New drivers for Freescale/iVeia P1022 and Maxim MAX98090.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iQIcBAABAgAGBQJQutrLAAoJELSic+t+oim9NVUP/3Y1YJjUADTy3w1d6L7zKaQb
dGVg2cdDBNgXCrIuyb3zUA9yNGrR1c7gzDGjTuiBrJKx917/DrF08pmgHAUv5e9B
+//xoy2lSwYgnPiWY7p6092+pYNI1hs4PDkV3zucrkkgQovIZOlebUM3MOrSf50+
abe9uPA11EyqPtmy8HrhtL2iJ3kUOq1y6YNbrDQaaWTL/lwBPS+LzxFAIE36LjN6
fIUOb8jtSE0rjOVo+jmuytdCnlugaEFfQzOebKMVYpB9LNv6hqISai/baaKFO1Fc
Jtkjv2xGuUuxP0kY6Fkbjabut7mS8oiVZfGmNUKbYoKStsk1t//xjay/2F0HsNgg
O7PsK6y1HD/iB87YNaO8Go/6lLSszeQ2WU7Fvynv/CTOpjO/8gjaQz3zDi3HsF5O
gyh/WYnj9jwnUJkaMDeEyjKBbKDxLuBeXBETVhNIWNgCwnj48TSYQwmGhtefNnS1
AM/CUrfXVsgCxPn8z/ep/hbkat8+PHENuPR9v81mUyQvVX9jTALVIYioTdxkc8Ul
y0p5UmgM/TsmnINGVUeFp5LkmfdyOhUhBtwovDhzDjR4RC1/otty1/9l4VHqw1ym
ETwqu7pl7bb9aDNsOEV9Z21kOMuTDbApHIT6crptNBllUvR0jDYfD4xOAs3zQLO5
JWOX2fPUHzFusINuA6fS
=2irt
-----END PGP SIGNATURE-----
Merge tag 'asoc-3.8' of git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-next
ASoC: Updates for v3.8
Very quiet release for ASoC really:
- Standardisation of the logging.
- DT and dmaengine support for Atmel.
- Support for Wolfson ADSP cores.
- New drivers for Freescale/iVeia P1022 and Maxim MAX98090.
The same type of code is being used in multiple places in various
codec drivers, so put it as a core library.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
This is a preliminary patch for introducing a protection to access
races of snd_array instances. Call snd_array_init() appropriately
at the initialization time and don't call it twice.
Also the allocations of codec-spec structs are cleaned up by helper
functions in patch_sigmatel.c and patch_analog.c.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
I forgot this again... codec->in_pm is in #ifdef CONFIG_PM
Reported-by: Markus Trippelsdorf <markus@trippelsdorf.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The internal mic on MBP81 gives only the right channel, and the left
channel is static. Add a verb to fix the ADC2 channel mode to expand
mono right to stereo.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=50781
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We forgot to apply the fixup verbs in cs_init().
But adding the fixup verbs will break mbp101 fixup that has been fixed
recently again, since the mbp101 fixup contains the wrong verbs to
override. So these bogus verbs must be removed, too.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
As the recent firmware code tries to reread and cache the firmware by
itself, it's even better to keep the struct firmware data instead of
keeping a local copy. Also, it makes little sense to disable the fw
loader for this driver, so added the explicit dependency, too.
Last, but not least, allocate the firmware data loaded via ioctl in
vmalloc'ed buffer instead, as the firmware size isn't that small.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The new firmware code tries to re-read the formerly read firmware
files before suspend. Thus it's wiser to keep the "patch" firmware in
the driver for avoiding this unnecessary re-reading.
Of course, this will consume a bit of memory for unused stuff, but
the patch fw is supposed to be fairly small, so it's more benefit in
the end.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
It makes no longer sense to keep the old hwdep user-space firmware
loading, which has been deprecated since ages ago.
Just add a hard dependency on CONFIG_FW_LOADER and drop the useless
code.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Since we keep the pin default config values anyway internally, we
don't have to set the values in the codec. This patch removes the
code writing the pincfg values.
As a gratis bonus, we can remove also the code restoring the original
pincfg values at PM resume or module free. This will give us more
benefit, as it can reduce the unnecessary power-up of codecs.
This won't change the driver functionality. The only difference would
be that the codec proc file will show the original pincfg values
instead of the actually referred values. The actually referred values
can be determined from sysfs *_pin_configs files.
(Also hda-emu was updated to follow this change.)
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The free callback is called at the state where no extra verbs are
executed, thus calling *_shutup() is useless, as it's checking the
shutdown flag. Remove such superfluous calls.
Signed-off-by: Takashi Iwai <tiwai@suse.de>
If this array is not cleared, the jack related code later might
fail to create "Internal Speaker Phantom Jack" on Dell Inspiron 3420 and
Dell Vostro 2420.
BugLink: https://bugs.launchpad.net/bugs/1076840
Cc: stable@vger.kernel.org (3.6+)
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We found a new codec ID 292, and that just a simple quirk would enable
sound output/input on this ALC292 chip.
BugLink: https://bugs.launchpad.net/bugs/1081466
Cc: stable@vger.kernel.org
Tested-by: Acelan Kao <acelan.kao@canonical.com>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
We've got a report that the runtime PM may make the codec the
unresponsive on AMD platforms. Since the feature has been tested only
on the recent Intel platforms, it's safer to limit the support to such
devices for now.
This patch adds a new DCAPS bit flag indicating the runtime PM
support, and mark it for Intel controllers.
Reported-and-tested-by: Julian Wollrath <jwollrath@web.de>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
The Acer Aspire AO756 has an analog built-in mic on nid 0x1b and an
external mic on nid 0x19. The BIOS doesn't set this up.
The mic detect on this Acer Aspire netbook and Acer C7 ChromeBook is
only valid when the headphone is plugged. The detect circuit relies on
the tip detect switch being closed on the jack. Tell hda_jack to ignore
the mic sense unless the headphones are plugged.
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
Introduce the concept of a "gated" jack. The gated jack's pin sense
is
only valid when the "gating" jack is plugged. This requires checking
the gating jack when the gated jack changes and re-checking the gated
jack when the gating jack is plugged/unplugged.
This allows handling of devices where the mic jack detect floats when
the headphone jack is unplugged.
[Rewritten for fixing the possible snd_array reallocation, covering
the missing callback calls and jack sync operations, as well as some
code cleanups -- tiwai]
Signed-off-by: Dylan Reid <dgreid@chromium.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
"Asynchronous" is misspelled in some comments. No code changes.
Signed-off-by: Adam Buchbinder <adam.buchbinder@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>