17 Sep, 2014

10 commits

  • commit f4821e8e8e957fe4c601a49b9a97b7399d5f7ab1 upstream.

    Debugging showed Realtek RT5642 doesn't support autoincrementing writes so
    driver should set the use_single_rw flag for regmap.

    Signed-off-by: Jarkko Nikula
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Jarkko Nikula
     
  • commit 9301503af016eb537ccce76adec0c1bb5c84871e upstream.

    This mode is unsupported, as the DMA controller can't do zero-padding
    of samples.

    Signed-off-by: Daniel Mack
    Reported-by: Johannes Stezenbach
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Daniel Mack
     
  • commit 4548728981de259d7d37d0ae968a777b09794168 upstream.

    There is a small memory leak if probe() fails.

    Fixes: 2023c90c3a2c ('ASoC: pxa: pxa-ssp: add DT bindings')
    Signed-off-by: Dan Carpenter
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Dan Carpenter
     
  • commit 4adeb0ccf86a5af1825bbfe290dee9e60a5ab870 upstream.

    max98090.c doesn't free the threaded interrupt it requests. This causes
    an oops when doing "cat /proc/interrupts" after snd-soc-max98090.ko is
    unloaded.

    Fix this by requesting the interrupt by using devm_request_threaded_irq().

    Signed-off-by: Jarkko Nikula
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Jarkko Nikula
     
  • commit 3ad80b828b2533f37c221e2df155774efd6ed814 upstream.

    Fix a long standing bug in the read register routing of adau1701.
    The bytes arrive in the buffer in big-endian, so the result has to be
    shifted before and-ing the bytes in the loop.

    Signed-off-by: Daniel Mack
    Acked-by: Lars-Peter Clausen
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Daniel Mack
     
  • commit d3d4e5247b013008a39e4d5f69ce4c60ed57f997 upstream.

    We should save/restore relevant I2S registers regardless of
    the dai->active flag, otherwise some settings are being lost
    after system suspend/resume cycle. E.g. I2S slave mode set only
    during dai initialization is not preserved and the device ends
    up in master mode after system resume.

    Signed-off-by: Sylwester Nawrocki
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Sylwester Nawrocki
     
  • commit 30443408fd7201fd1911b09daccf92fae3cc700d upstream.

    The third parameter for snd_pcm_format_set_silence needs the number
    of samples instead of sample bytes.

    Signed-off-by: Scott Jiang
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Scott Jiang
     
  • commit 0a37c6efec4a2fdc2563c5a8faa472b814deee80 upstream.

    Since MODULE_LICENSE is missing the module load fails,
    so add this for module.

    Signed-off-by: Praveen Diwakar
    Signed-off-by: Vinod Koul
    Reviewed-by: Charles Keepax
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Praveen Diwakar
     
  • commit 7ed9de76ff342cbd717a9cf897044b99272cb8f8 upstream.

    we need to release dapm widget list after dpcm_path_get in
    soc_dpcm_runtime_update. otherwise, there will be potential memory
    leak. add dpcm_path_put to fix it.

    Signed-off-by: Qiao Zhou
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Qiao Zhou
     
  • commit b38314179c9ccb789e6fe967cff171fa817e8978 upstream.

    wm1811_micd_stop takes the accdet_lock mutex, and is called from two
    places, one of which is already holding the accdet_lock. This obviously
    causes a lock up.

    This patch fixes this issue by removing the lock from wm1811_micd_stop
    and ensuring that it is always locked externally.

    Signed-off-by: Charles Keepax
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Charles Keepax
     

04 Sep, 2014

6 commits

  • commit f3ee07d8b6e061bf34a7167c3f564e8da4360a99 upstream.

    ALC269 & co have many vendor-specific setups with COEF verbs.
    However, some verbs seem specific to some codec versions and they
    result in the codec stalling. Typically, such a case can be avoided
    by checking the return value from reading a COEF. If the return value
    is -1, it implies that the COEF is invalid, thus it shouldn't be
    written.

    This patch adds the invalid COEF checks in appropriate places
    accessing ALC269 and its variants. The patch actually fixes the
    resume problem on Acer AO725 laptop.

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=52181
    Tested-by: Francesco Muzio
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     
  • commit f475371aa65de84fa483a998ab7594531026b9d9 upstream.

    On some HP laptops, the mute led is controlled by codec gpio.

    When some machine resume from s3/s4, the codec gpio data will be
    cleared to 0 by BIOS:
    Before suspend:
    IO[3]: enable=1, dir=1, wake=0, sticky=0, data=1, unsol=0
    After resume:
    IO[3]: enable=1, dir=1, wake=0, sticky=0, data=0, unsol=0

    To skip the AFG node to enter D3 can't fix this problem.

    A workaround is to restore the gpio data when the system resume
    back from s3/s4. It is safe even on the machines without this
    problem.

    BugLink: https://bugs.launchpad.net/bugs/1358116
    Tested-by: Franz Hsieh
    Signed-off-by: Hui Wang
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Hui Wang
     
  • commit 53da5ebfef66ea6e478ad9c6add3781472b79475 upstream.

    The BOSS ME-25 turns out not to have any useful descriptors in its MIDI
    interface, so its needs a quirk entry after all.

    Reported-and-tested-by: Kees van Veen
    Fixes: 8e5ced83dd1c ("ALSA: usb-audio: remove superfluous Roland quirks")
    Signed-off-by: Clemens Ladisch
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Clemens Ladisch
     
  • commit e24aa0a4c5ac92a171d9dd74a8d3dbf652990d36 upstream.

    CA0132 driver tries to reload the firmware at resume. Usually this
    works since the firmware loader core caches the firmware contents by
    itself. However, if the driver failed to load the firmwares
    (e.g. missing files), reloading the firmware at resume goes through
    the actual file loading code path, and triggers a kernel WARNING like:

    WARNING: CPU: 10 PID:11371 at drivers/base/firmware_class.c:1105 _request_firmware+0x9ab/0x9d0()

    For avoiding this situation, this patch makes CA0132 skipping the f/w
    loading at resume when it failed at probe time.

    Reported-and-tested-by: Janek Kozicki
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     
  • commit f42bb22243d2ae264d721b055f836059fe35321f upstream.

    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
    Tested-by: corubba
    Signed-off-by: Clemens Ladisch
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Clemens Ladisch
     
  • commit 7440850c20b69658f322119d20a94dc914127cc7 upstream.

    ON the machine, two pin complex (0xb and 0xe) are both routed to
    the same external right-side mic jack, this makes the jack can't work.

    To fix this problem, set the 0xe to "not connected".

    BugLink: https://bugs.launchpad.net/bugs/1350148
    Tested-by: Franz Hsieh
    Signed-off-by: Hui Wang
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Hui Wang
     

26 Aug, 2014

1 commit


29 Jul, 2014

1 commit

  • commit 4da63c6fc426023d1a20e45508c47d7d68c6a53d upstream.

    When the initialization of Intel HDMI controller fails due to missing
    i915 kernel symbols (e.g. HD-audio is built in while i915 is module),
    the driver discontinues the probe. However, since the probe was done
    asynchronously, the driver object still remains, thus the relevant PM
    ops are still called at suspend/resume. This results in the bad access
    to the incomplete audio card object, eventually leads to Oops or stall
    at PM.

    This patch adds the missing checks of chip->init_failed flag at each
    PM callback in order to fix the problem above.

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=79561
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     

18 Jul, 2014

2 commits

  • commit b7a7723513dc89f83d6df13206df55d4dc26e825 upstream.

    This (widely used) construction:

    if(printk_ratelimit())
    dev_dbg()

    Causes the ratelimiting to spam the kernel log with the "callbacks suppressed"
    message below, even while the dev_dbg it is supposed to rate limit wouldn't
    print anything because DEBUG is not defined for this device.

    [ 533.803964] retire_playback_urb: 852 callbacks suppressed
    [ 538.807930] retire_playback_urb: 852 callbacks suppressed
    [ 543.811897] retire_playback_urb: 852 callbacks suppressed
    [ 548.815745] retire_playback_urb: 852 callbacks suppressed
    [ 553.819826] retire_playback_urb: 852 callbacks suppressed

    So use dev_dbg_ratelimited() instead of this construction.

    Signed-off-by: Sander Eikelenboom
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Sander Eikelenboom
     
  • commit a5065eb6da55b226661456e6a7435f605df98111 upstream.

    BugLink: http://bugs.launchpad.net/bugs/1305133

    Malfunctioning or slow devices can cause a flood of dmesg SPAM.

    I've ignored checkpatch.pl complaints about the use of printk_ratelimit() in favour
    of prior art in sound/usb/pcm.c.

    WARNING: Prefer printk_ratelimited or pr__ratelimited to printk_ratelimit
    + if (printk_ratelimit() &&

    Cc: Jaroslav Kysela
    Cc: Takashi Iwai
    Cc: Eldad Zack
    Cc: Daniel Mack
    Cc: Clemens Ladisch
    Signed-off-by: Tim Gardner
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Tim Gardner
     

17 Jul, 2014

1 commit

  • commit 92a586bdc06de6629dae1b357dac221253f55ff8 upstream.

    When a USB-audio device is disconnected while PCM is still running, we
    still see some race: the disconnect callback calls
    snd_usb_endpoint_free() that calls release_urbs() and then kfree()
    while a PCM stream would be closed at the same time and calls
    stop_endpoints() that leads to wait_clear_urbs(). That is, the EP
    object might be deallocated while a PCM stream is syncing with
    wait_clear_urbs() with the same EP.

    Basically calling multiple wait_clear_urbs() would work fine, also
    calling wait_clear_urbs() and release_urbs() would work, too, as
    wait_clear_urbs() just reads some fields in ep. The problem is the
    succeeding kfree() in snd_pcm_endpoint_free().

    This patch moves out the EP deallocation into the later point, the
    destructor callback. At this stage, all PCMs must have been already
    closed, so it's safe to free the objects.

    Reported-by: Alan Stern
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     

02 Jul, 2014

10 commits

  • commit 94908a39ce971f25c3695c334d88eec4d2837428 upstream.

    Channel map positions FLH, FCH, FRH duplicate positions TFL, TFC, TFR.
    Both are the speakers above the front speakers (CEA uses "high" and USB
    audio uses "top" nomenclature).

    Since the USB audio code has used the TFx positions since v3.8
    (04324ccc75f96, "ALSA: usb-audio: add channel map support") but the HDMI
    code only just started using FxH in a5b7d510b2220cccb ("ALSA: hda -
    hdmi: Fix channel maps with less common speakers") which is not yet in
    any released kernel, standardize on TFx instead.

    Signed-off-by: Anssi Hannula
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Anssi Hannula
     
  • commit 883a1d49f0d77d30012f114b2e19fc141beb3e8e upstream.

    The ALSA control code expects that the range of assigned indices to a control is
    continuous and does not overflow. Currently there are no checks to enforce this.
    If a control with a overflowing index range is created that control becomes
    effectively inaccessible and unremovable since snd_ctl_find_id() will not be
    able to find it. This patch adds a check that makes sure that controls with a
    overflowing index range can not be created.

    Signed-off-by: Lars-Peter Clausen
    Acked-by: Jaroslav Kysela
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Lars-Peter Clausen
     
  • commit ac902c112d90a89e59916f751c2745f4dbdbb4bd upstream.

    Each control gets automatically assigned its numids when the control is created.
    The allocation is done by incrementing the numid by the amount of allocated
    numids per allocation. This means that excessive creation and destruction of
    controls (e.g. via SNDRV_CTL_IOCTL_ELEM_ADD/REMOVE) can cause the id to
    eventually overflow. Currently when this happens for the control that caused the
    overflow kctl->id.numid + kctl->count will also over flow causing it to be
    smaller than kctl->id.numid. Most of the code assumes that this is something
    that can not happen, so we need to make sure that it won't happen

    Signed-off-by: Lars-Peter Clausen
    Acked-by: Jaroslav Kysela
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Lars-Peter Clausen
     
  • commit fd9f26e4eca5d08a27d12c0933fceef76ed9663d upstream.

    A control that is visible on the card->controls list can be freed at any time.
    This means we must not access any of its memory while not holding the
    controls_rw_lock. Otherwise we risk a use after free access.

    Signed-off-by: Lars-Peter Clausen
    Acked-by: Jaroslav Kysela
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Lars-Peter Clausen
     
  • commit 82262a46627bebb0febcc26664746c25cef08563 upstream.

    There are two issues with the current implementation for replacing user
    controls. The first is that the code does not check if the control is actually a
    user control and neither does it check if the control is owned by the process
    that tries to remove it. That allows userspace applications to remove arbitrary
    controls, which can cause a user after free if a for example a driver does not
    expect a control to be removed from under its feed.

    The second issue is that on one hand when a control is replaced the
    user_ctl_count limit is not checked and on the other hand the user_ctl_count is
    increased (even though the number of user controls does not change). This allows
    userspace, once the user_ctl_count limit as been reached, to repeatedly replace
    a control until user_ctl_count overflows. Once that happens new controls can be
    added effectively bypassing the user_ctl_count limit.

    Both issues can be fixed by instead of open-coding the removal of the control
    that is to be replaced to use snd_ctl_remove_user_ctl(). This function does
    proper permission checks as well as decrements user_ctl_count after the control
    has been removed.

    Note that by using snd_ctl_remove_user_ctl() the check which returns -EBUSY at
    beginning of the function if the control already exists is removed. This is not
    a problem though since the check is quite useless, because the lock that is
    protecting the control list is released between the check and before adding the
    new control to the list, which means that it is possible that a different
    control with the same settings is added to the list after the check. Luckily
    there is another check that is done while holding the lock in snd_ctl_add(), so
    we'll rely on that to make sure that the same control is not added twice.

    Signed-off-by: Lars-Peter Clausen
    Acked-by: Jaroslav Kysela
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Lars-Peter Clausen
     
  • commit 07f4d9d74a04aa7c72c5dae0ef97565f28f17b92 upstream.

    The user-control put and get handlers as well as the tlv do not protect against
    concurrent access from multiple threads. Since the state of the control is not
    updated atomically it is possible that either two write operations or a write
    and a read operation race against each other. Both can lead to arbitrary memory
    disclosure. This patch introduces a new lock that protects user-controls from
    concurrent access. Since applications typically access controls sequentially
    than in parallel a single lock per card should be fine.

    Signed-off-by: Lars-Peter Clausen
    Acked-by: Jaroslav Kysela
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Lars-Peter Clausen
     
  • commit 2041d56464a067461d7cc21734a0f024587ed2ff upstream.

    According to the bug reporter (Данило Шеган), the external mic
    starts to work and has proper jack detection if only pin 0x19
    is marked properly as an external headset mic.

    AlsaInfo at https://bugs.launchpad.net/ubuntu/+source/pulseaudio/+bug/1328587/+attachment/4128991/+files/AlsaInfo.txt

    BugLink: https://bugs.launchpad.net/bugs/1328587
    Signed-off-by: David Henningsson
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    David Henningsson
     
  • commit b6c5fbad16aa5026f508093a8d651c25e1cb6179 upstream.

    New codec support for ALC891.

    Signed-off-by: Kailang Yang
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Kailang Yang
     
  • commit e6c111fac4464e3f4bf7b3802b517dafc80f8e0f upstream.

    For some unknown reason the parameters for snd_soc_test_bits() were in wrong
    order:
    It was:
    snd_soc_test_bits(codec, val, mask, reg); /* WRONG!!! */
    while it should be:
    snd_soc_test_bits(codec, reg, mask, val);

    Signed-off-by: Peter Ujfalusi
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Peter Ujfalusi
     
  • commit 25b4ab430f8e166c9b63f4db28e7e812d5a59396 upstream.

    Reset needs to wait 20ms before other codec IO is performed. This wait
    was not being performed. Fix this by making sure the reset register is not
    restored with the cache, but use the manual reset method in resume with
    the wait.

    Signed-off-by: Liam Girdwood
    Signed-off-by: Jarkko Nikula
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Liam Girdwood
     

20 Jun, 2014

3 commits

  • commit 192a98e280e560510a62aca8cfa83b4ae7c095bb upstream.

    The conversion to a fixup table for Replacer model with ALC260 in
    commit 20f7d928 took the wrong widget NID for COEF setups. Namely,
    NID 0x1a should have been used instead of NID 0x20, which is the
    common node for all Realtek codecs but ALC260.

    Fixes: 20f7d928fa6e ('ALSA: hda/realtek - Replace ALC260 model=replacer with the auto-parser')
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     
  • commit e30cf2d2bed3aed74a651c64de323ba26e4ff7d0 upstream.

    Correcion of wrong fixup entries add in commit ca8f0424 to replace
    static model quirk for PB V7900 laptop (will model).

    [note: the removal of ALC260_FIXUP_HP_PIN_0F chain is also needed as a
    part of the fix; otherwise the pin is set up wrongly as a headphone,
    and user-space (PulseAudio) may be wrongly trying to detect the jack
    state -- tiwai]

    Fixes: ca8f04247eaa ('ALSA: hda/realtek - Add the fixup codes for ALC260 model=will')
    Signed-off-by: Ronan Marquet
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Ronan Marquet
     
  • commit 598e306184d26fa1d546334f2eb370b4d94a4ad3 upstream.

    ASUS A8JN with AD1986A codec seems following the normal EAPD in the
    normal order (0 = off, 1 = on) unlike other machines with AD1986A.
    Apply the workaround used for Toshiba laptop that showed the same
    problem.

    Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=75041
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     

09 Jun, 2014

3 commits

  • commit 44330ab516c15dda8a1e660eeaf0003f84e43e3f upstream.

    The register CLASS_D_CONTROL_1 is marked as volatile because it contains
    a bit, DAC_MUTE, which is also mirrored in the ADC_DAC_CONTROL_1
    register. This causes problems for the "Speaker Switch" control, which
    will report an error if the CODEC is suspended because it relies on a
    volatile register.

    To resolve this issue mark CLASS_D_CONTROL_1 as non-volatile and
    manually keep the register cache in sync by updating both bits when
    changing the mute status.

    Reported-by: Shawn Guo
    Signed-off-by: Charles Keepax
    Tested-by: Shawn Guo
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Charles Keepax
     
  • commit 77f07800cb456bed6e5c345e6e4e83e8eda62437 upstream.

    The recent Intel H97/Z97 chipsets need the similar setups like other
    Intel chipsets for snooping, etc. Especially without snooping, the
    audio playback stutters or gets corrupted. This fix patch just adds
    the corresponding PCI ID entry with the proper flags.

    Reported-and-tested-by: Arthur Borsboom
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Takashi Iwai
     
  • commit f06ab794af7055d0949b09885f79f8b493deec64 upstream.

    Since commit 1df5a06a ("ALSA: hda - hdmi: Fix programmed active channel
    count") channel count is no longer being set if monitor_present is 0.
    This is because setting the count was moved after the CA value is
    determined, which is only after the monitor_present check in
    hdmi_setup_audio_infoframe().

    Unfortunately, in some cases, such as with a non-spec-compliant codec or
    with a problematic video driver, monitor_present is always 0. As a
    specific example, this seems to happen with gen1 ATV (SiI1390 codec),
    causing left-channel-only stereo playback (multi-channel playback has
    apparently never worked with this codec despite it reporting 8 channels,
    reason unknown).

    Simply setting converter channel count without setting the pin infoframe
    and channel mapping as well does not theoretically make much sense as
    this will just mean they are out-of-sync and multichannel playback will
    have a wrong channel mapping.

    However, adding back just setting the converter channel count even in
    no-monitor case is the safest change which at least fixes the stereo
    playback regression on SiI1390 codec. Do that.

    Signed-off-by: Anssi Hannula
    Reported-by: Stephan Raue
    Tested-by: Stephan Raue
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Anssi Hannula
     

06 Jun, 2014

1 commit

  • commit 7040b6d1febfdbd9c1595efb751d492cd2503f96 upstream.

    The TEAC UD-H01 firmware sends wrong feedback frequency values, thus
    causing the PC to send the samples at a wrong rate, which results in
    clicks and crackles in the output.

    Add a workaround to detect and fix the corruption.

    Signed-off-by: Clemens Ladisch
    [mick37@gmx.de: use sender->udh01_fb_quirk rather than
    ep->udh01_fb_quirk in snd_usb_handle_sync_urb()]
    Reported-and-tested-by: Mick
    Reported-and-tested-by: Andrea Messa
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Clemens Ladisch
     

15 May, 2014

2 commits

  • commit 2697e4fb9209dfe1d1b24c92d254158f63d4bc8e upstream.

    Commit 9e1fda4ae158 ("ASoC: dapm: Implement mixer input auto-disable")
    is trying to free the widget it allocated by snd_soc_dapm_new_control()
    call in dapm_kcontrol_data_alloc() by adding kfree(data->widget) to
    dapm_kcontrol_free().

    This is causing a widget double free with auto-disabled DAPM kcontrols
    in sound card unregistration because widgets are already freed before
    dapm_kcontrol_free() is called.

    Reason for that is all widgets are added into dapm->card->widgets list
    in snd_soc_dapm_new_control() and freed in dapm_free_widgets() during
    execution of snd_soc_dapm_free().

    Now snd_soc_dapm_free() calls for different DAPM contexts happens before
    snd_card_free() call from where the call chain to dapm_kcontrol_free()
    begins:

    soc_cleanup_card_resources()
    soc_remove_dai_links()
    soc_remove_link_dais()
    snd_soc_dapm_free(&cpu_dai->dapm)
    soc_remove_link_components()
    soc_remove_platform()
    snd_soc_dapm_free(&platform->dapm)
    soc_remove_codec()
    snd_soc_dapm_free(&codec->dapm)
    snd_soc_dapm_free(&card->dapm)
    snd_card_free()
    snd_card_do_free()
    snd_device_free_all()
    snd_device_free()
    snd_ctl_dev_free()
    snd_ctl_remove()
    snd_ctl_free_one()
    dapm_kcontrol_free()

    This wasn't making harm with ordinary DAPM kcontrols since data->widget is NULL for
    them.

    Fixes: 9e1fda4ae158 (ASoC: dapm: Implement mixer input auto-disable)
    Signed-off-by: Jarkko Nikula
    Acked-by: Lars-Peter Clausen
    Signed-off-by: Mark Brown
    Signed-off-by: Jiri Slaby

    Jarkko Nikula
     
  • commit 8dc9abb93dde94e7f2bc719032fe16f5713df05c upstream.

    Signed-off-by: Kailang Yang
    Signed-off-by: Takashi Iwai
    Signed-off-by: Jiri Slaby

    Kailang Yang