Skip to content
  1. Dec 20, 2021
    • Trevor Wu's avatar
      ASoC: mediatek: mt8195: correct default value · 30e693ee
      Trevor Wu authored
      mt8195_cg_patch is used to reset the default value of audio cg, so the
      register value could be consistent with CCF reference count.
      Nevertheless, AUDIO_TOP_CON1[1:0] is used to control an internal mux,
      and it's expected to keep the default value 0.
      
      This patch corrects the default value in case an unexpected behavior
      happens in the future.
      
      Fixes: 6746cc85
      
       ("ASoC: mediatek: mt8195: add platform driver")
      Signed-off-by: default avatarTrevor Wu <trevor.wu@mediatek.com>
      Link: https://lore.kernel.org/r/20211216022424.28470-1-trevor.wu@mediatek.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      30e693ee
  2. Dec 15, 2021
  3. Dec 14, 2021
  4. Dec 06, 2021
  5. Dec 01, 2021
  6. Nov 30, 2021
    • Hui Wang's avatar
      ASoC: SOF: Intel: Retry codec probing if it fails · 046aede2
      Hui Wang authored
      
      
      On the latest Lenovo Thinkstation laptops, we often experience the
      speaker failure after rebooting, check the dmesg, we could see:
       sof-audio-pci-intel-tgl 0000:00:1f.3: codec #0 probe error, ret: -5
      
      The analogue codec on the machine is ALC287, then we designed a
      testcase to reboot and check the codec probing result repeatedly, we
      found the analogue codec probing always failed at least once within
      several minutes to several hours (roughly 1 reboot per min). This
      issue happens on all laptops of this Thinkstation model, but with
      legacy HDA driver, we couldn't reproduce this issue on those laptops.
      And so far, this issue is not reproduced on machines which don't
      belong to this model.
      
      We tried to make the hda_dsp_ctrl_init_chip() same as
      hda_intel_init_chip() which is the controller init routine in the
      legacy HDA driver, but it didn't help.
      
      We found when issue happens, the resp is -1, and if we let driver
      re-run send_cmd() and get_response(), it will get the correct response
      10ec0287, then driver continues the rest work, finally boot to the
      desktop and all audio function work well.
      
      Here adding codec probing retries to 3 times, it could fix the issue
      on this Thinkstation model, and it doesn't bring impact to other
      machines.
      
      Reviewed-by: default avatarBard Liao <bard.liao@intel.com>
      Reviewed-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
      Signed-off-by: default avatarHui Wang <hui.wang@canonical.com>
      Signed-off-by: default avatarKai Vehmanen <kai.vehmanen@linux.intel.com>
      Link: https://lore.kernel.org/r/20211130090606.529348-1-kai.vehmanen@linux.intel.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      046aede2
    • Dan Carpenter's avatar
      ASoC: amd: fix uninitialized variable in snd_acp6x_probe() · d5c137f4
      Dan Carpenter authored
      The "index" is potentially used without being initialized on the error
      path.
      
      Fixes: fc329c1d
      
       ("ASoC: amd: add platform devices for acp6x pdm driver and dmic driver")
      Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
      Link: https://lore.kernel.org/r/20211130125633.GA24941@kili
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      d5c137f4
    • Nicolas Frattaroli's avatar
      ASoC: rockchip: i2s_tdm: Dup static DAI template · 53689f7f
      Nicolas Frattaroli authored
      Previously, the DAI template was used directly, which lead to
      fun bugs such as "why is my channels_max changing?" when one
      instantiated more than one i2s_tdm IP block in a device tree.
      
      This change makes it so that we instead duplicate the template
      struct, and then use that.
      
      Fixes: 081068fd
      
       ("ASoC: rockchip: add support for i2s-tdm controller")
      Signed-off-by: default avatarNicolas Frattaroli <frattaroli.nicolas@gmail.com>
      Link: https://lore.kernel.org/r/20211125084900.417102-1-frattaroli.nicolas@gmail.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      53689f7f
  7. Nov 27, 2021
    • Mark Brown's avatar
      Suspend related fixes on Tegra · 8a724d5f
      Mark Brown authored
      Merge series from Sameer Pujar <spujar@nvidia.com>:
      
      	This series addresses following problems:
      	 * The runtime PM is not balanced in MVC driver, whenever
      	   mute or volume mixer controls are set.
      	 * Some of the AHUB devices (SFC, MVC, Mixer, AMX and ADX)
      	   use late system sleep. Suspend failure is seen on Jetson
      	   TX2 platform.
      8a724d5f
  8. Nov 26, 2021
    • Rob Clark's avatar
      ASoC: rt5682s: Fix crash due to out of scope stack vars · 750dc2f6
      Rob Clark authored
      Move the declaration of temporary arrays to somewhere that won't go out
      of scope before the devm_clk_hw_register() call, lest we be at the whim
      of the compiler for whether those stack variables get overwritten.
      
      Fixes a crash seen with gcc version 11.2.1 20210728 (Red Hat 11.2.1-1)
      
      Fixes: bdd229ab
      
       ("ASoC: rt5682s: Add driver for ALC5682I-VS codec")
      Signed-off-by: default avatarRob Clark <robdclark@chromium.org>
      Reviewed-by: default avatarStephen Boyd <swboyd@chromium.org>
      Link: https://lore.kernel.org/r/20211118010453.843286-2-robdclark@gmail.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      750dc2f6
    • Rob Clark's avatar
      ASoC: rt5682: Fix crash due to out of scope stack vars · 4999d703
      Rob Clark authored
      Move the declaration of temporary arrays to somewhere that won't go out
      of scope before the devm_clk_hw_register() call, lest we be at the whim
      of the compiler for whether those stack variables get overwritten.
      
      Fixes a crash seen with gcc version 11.2.1 20210728 (Red Hat 11.2.1-1)
      
      Fixes: edbd24ea
      
       ("ASoC: rt5682: Drop usage of __clk_get_name()")
      Signed-off-by: default avatarRob Clark <robdclark@chromium.org>
      Reviewed-by: default avatarStephen Boyd <swboyd@chromium.org>
      Link: https://lore.kernel.org/r/20211118010453.843286-1-robdclark@gmail.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      4999d703
    • Sameer Pujar's avatar
      ASoC: tegra: Use normal system sleep for ADX · cf36de4f
      Sameer Pujar authored
      The driver currently subscribes for a late system sleep call.
      The initcall_debug log shows that suspend call for ADX device
      happens after the parent device (AHUB). This seems to cause
      suspend failure on Jetson TX2 platform. Also there is no use
      of having late system sleep specifically for ADX device. Fix
      the order by using normal system sleep.
      
      Fixes: a99ab6f3
      
       ("ASoC: tegra: Add Tegra210 based ADX driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSameer Pujar <spujar@nvidia.com>
      Link: https://lore.kernel.org/r/1637676459-31191-7-git-send-email-spujar@nvidia.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      cf36de4f
    • Sameer Pujar's avatar
      ASoC: tegra: Use normal system sleep for AMX · 638c31d5
      Sameer Pujar authored
      The driver currently subscribes for a late system sleep call.
      The initcall_debug log shows that suspend call for AMX device
      happens after the parent device (AHUB). This seems to cause
      suspend failure on Jetson TX2 platform. Also there is no use
      of having late system sleep specifically for AMX device. Fix
      the order by using normal system sleep.
      
      Fixes: 77f7df34
      
       ("ASoC: tegra: Add Tegra210 based AMX driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSameer Pujar <spujar@nvidia.com>
      Link: https://lore.kernel.org/r/1637676459-31191-6-git-send-email-spujar@nvidia.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      638c31d5
    • Sameer Pujar's avatar
      ASoC: tegra: Use normal system sleep for Mixer · b78400e4
      Sameer Pujar authored
      The driver currently subscribes for a late system sleep call.
      The initcall_debug log shows that suspend call for Mixer device
      happens after the parent device (AHUB). This seems to cause
      suspend failure on Jetson TX2 platform. Also there is no use
      of having late system sleep specifically for Mixer device. Fix
      the order by using normal system sleep.
      
      Fixes: 05bb3d5e
      
       ("ASoC: tegra: Add Tegra210 based Mixer driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSameer Pujar <spujar@nvidia.com>
      Link: https://lore.kernel.org/r/1637676459-31191-5-git-send-email-spujar@nvidia.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      b78400e4
    • Sameer Pujar's avatar
      ASoC: tegra: Use normal system sleep for MVC · c83d263a
      Sameer Pujar authored
      The driver currently subscribes for a late system sleep call.
      The initcall_debug log shows that suspend call for MVC device
      happens after the parent device (AHUB). This seems to cause
      suspend failure on Jetson TX2 platform. Also there is no use
      of having late system sleep specifically for MVC device. Fix
      the order by using normal system sleep.
      
      Fixes: e539891f
      
       ("ASoC: tegra: Add Tegra210 based MVC driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSameer Pujar <spujar@nvidia.com>
      Link: https://lore.kernel.org/r/1637676459-31191-4-git-send-email-spujar@nvidia.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      c83d263a
    • Sameer Pujar's avatar
      ASoC: tegra: Use normal system sleep for SFC · af120d07
      Sameer Pujar authored
      The driver currently subscribes for a late system sleep call.
      The initcall_debug log shows that suspend call for SFC device
      happens after the parent device (AHUB). This seems to cause
      suspend failure on Jetson TX2 platform. Also there is no use
      of having late system sleep specifically for SFC device. Fix
      the order by using normal system sleep.
      
      Fixes: b2f74ec5
      
       ("ASoC: tegra: Add Tegra210 based SFC driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSameer Pujar <spujar@nvidia.com>
      Link: https://lore.kernel.org/r/1637676459-31191-3-git-send-email-spujar@nvidia.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      af120d07
    • Sameer Pujar's avatar
      ASoC: tegra: Balance runtime PM count · 70408f75
      Sameer Pujar authored
      After successful application of volume/mute settings via mixer control
      put calls, the control returns without balancing the runtime PM count.
      This makes device to be always runtime active. Fix this by allowing
      control to reach pm_runtime_put() call.
      
      Fixes: e539891f
      
       ("ASoC: tegra: Add Tegra210 based MVC driver")
      Cc: stable@vger.kernel.org
      Signed-off-by: default avatarSameer Pujar <spujar@nvidia.com>
      Link: https://lore.kernel.org/r/1637676459-31191-2-git-send-email-spujar@nvidia.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      70408f75
  9. Nov 25, 2021
  10. Nov 24, 2021
  11. Nov 23, 2021
  12. Nov 22, 2021
    • Nicolas Frattaroli's avatar
      ASoC: rk817: Add module alias for rk817-codec · 428ee30a
      Nicolas Frattaroli authored
      Without a module alias, autoloading the driver does not occurr
      when it is built as a module.
      
      By adding a module alias, the driver now probes fine automatically
      and therefore analog audio output works as it should.
      
      Fixes: 0d6a04da
      
       ("ASoC: Add Rockchip rk817 audio CODEC support")
      Signed-off-by: default avatarNicolas Frattaroli <frattaroli.nicolas@gmail.com>
      Link: https://lore.kernel.org/r/20211121150521.159543-1-frattaroli.nicolas@gmail.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      428ee30a
    • Hans de Goede's avatar
      ASoC: soc-acpi: Set mach->id field on comp_ids matches · 28c916ad
      Hans de Goede authored
      Commit dac7cbd5 ("ASoC: Intel: soc-acpi-byt: shrink tables using
      compatible IDs") and commit 959ae821 ("ASoC: Intel: soc-acpi-cht:
      shrink tables using compatible IDs") simplified the match tables in
      soc-acpi-intel-byt-match.c and soc-acpi-intel-cht-match.c by merging
      identical entries using the new .comp_ids snd_soc_acpi_mach field to
      point a single entry to multiple ACPI HIDs and clearing the previously
      unique per entry .id field.
      
      But various machine drivers from sound/soc/intel/boards rely on mach->id
      in one or more ways, e.g. some drivers contain the following snippets:
      
      	adev = acpi_dev_get_first_match_dev(mach->id, NULL, -1);
      
      	pkg_found = snd_soc_acpi_find_package_from_hid(mach->id, ...
      
      	if (!strncmp(snd_soc_cards[i].codec_id, mach->id, 8)) { ...
      
      All of which are broken by the match table shrinking.
      
      Make the snd_soc_acpi_mach.id field non const (the storage for the tables
      already is non const) and on a comps_ids match copy the matching HID to
      the id field to fix this.
      
      Fixes: dac7cbd5 ("ASoC: Intel: soc-acpi-byt: shrink tables using compatible IDs")
      Fixes: 959ae821
      
       ("ASoC: Intel: soc-acpi-cht: shrink tables using compatible IDs")
      Suggested-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
      Cc: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
      Cc: Brent Lu <brent.lu@intel.com>
      Signed-off-by: default avatarHans de Goede <hdegoede@redhat.com>
      Reviewed-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
      Link: https://lore.kernel.org/r/20211118153014.349222-1-hdegoede@redhat.com
      Signed-off-by: default avatarMark Brown <broonie@kernel.org>
      28c916ad
  13. Nov 19, 2021