Commit 49951ae3 authored by Takashi Iwai's avatar Takashi Iwai
Browse files

Merge tag 'asoc-fix-v5.11-rc5' of...

Merge tag 'asoc-fix-v5.11-rc5' of https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound into for-linus

ASoC: Fixes for v5.11

More fixes for v5.11, almost all driver specific issues including new
device IDs - there's one error handling fix for the topology stuff too.
parents c5b5ff60 5413dfd8
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -2,9 +2,8 @@
#ifndef __DT_APQ8016_LPASS_H
#define __DT_APQ8016_LPASS_H

#define MI2S_PRIMARY	0
#define MI2S_SECONDARY	1
#define MI2S_TERTIARY	2
#define MI2S_QUATERNARY	3
#include <dt-bindings/sound/qcom,lpass.h>

/* NOTE: Use qcom,lpass.h to define any AIF ID's for LPASS */

#endif /* __DT_APQ8016_LPASS_H */
+15 −0
Original line number Diff line number Diff line
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef __DT_QCOM_LPASS_H
#define __DT_QCOM_LPASS_H

#define MI2S_PRIMARY	0
#define MI2S_SECONDARY	1
#define MI2S_TERTIARY	2
#define MI2S_QUATERNARY	3
#define MI2S_QUINARY	4

#define LPASS_DP_RX	5

#define LPASS_MCLK0	0

#endif /* __DT_QCOM_LPASS_H */
+2 −4
Original line number Diff line number Diff line
@@ -2,10 +2,8 @@
#ifndef __DT_SC7180_LPASS_H
#define __DT_SC7180_LPASS_H

#define MI2S_PRIMARY	0
#define MI2S_SECONDARY	1
#define LPASS_DP_RX	2
#include <dt-bindings/sound/qcom,lpass.h>

#define LPASS_MCLK0	0
/* NOTE: Use qcom,lpass.h to define any AIF ID's for LPASS */

#endif /* __DT_APQ8016_LPASS_H */
+16 −2
Original line number Diff line number Diff line
@@ -165,10 +165,24 @@ static int rn_acp_deinit(void __iomem *acp_base)

static const struct dmi_system_id rn_acp_quirk_table[] = {
	{
		/* Lenovo IdeaPad Flex 5 14ARE05, IdeaPad 5 15ARE05 */
		/* Lenovo IdeaPad S340-14API */
		.matches = {
			DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "LENOVO"),
			DMI_EXACT_MATCH(DMI_BOARD_NAME, "LNVNB161216"),
			DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "81NB"),
		}
	},
	{
		/* Lenovo IdeaPad Flex 5 14ARE05 */
		.matches = {
			DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "LENOVO"),
			DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "81X2"),
		}
	},
	{
		/* Lenovo IdeaPad 5 15ARE05 */
		.matches = {
			DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "LENOVO"),
			DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "81YQ"),
		}
	},
	{
+7 −15
Original line number Diff line number Diff line
@@ -595,18 +595,10 @@ static struct snd_soc_dai_driver ak4497_dai = {
	.ops = &ak4458_dai_ops,
};

static void ak4458_power_off(struct ak4458_priv *ak4458)
static void ak4458_reset(struct ak4458_priv *ak4458, bool active)
{
	if (ak4458->reset_gpiod) {
		gpiod_set_value_cansleep(ak4458->reset_gpiod, 0);
		usleep_range(1000, 2000);
	}
}

static void ak4458_power_on(struct ak4458_priv *ak4458)
{
	if (ak4458->reset_gpiod) {
		gpiod_set_value_cansleep(ak4458->reset_gpiod, 1);
		gpiod_set_value_cansleep(ak4458->reset_gpiod, active);
		usleep_range(1000, 2000);
	}
}
@@ -620,7 +612,7 @@ static int ak4458_init(struct snd_soc_component *component)
	if (ak4458->mute_gpiod)
		gpiod_set_value_cansleep(ak4458->mute_gpiod, 1);

	ak4458_power_on(ak4458);
	ak4458_reset(ak4458, false);

	ret = snd_soc_component_update_bits(component, AK4458_00_CONTROL1,
			    0x80, 0x80);   /* ACKS bit = 1; 10000000 */
@@ -650,7 +642,7 @@ static void ak4458_remove(struct snd_soc_component *component)
{
	struct ak4458_priv *ak4458 = snd_soc_component_get_drvdata(component);

	ak4458_power_off(ak4458);
	ak4458_reset(ak4458, true);
}

#ifdef CONFIG_PM
@@ -660,7 +652,7 @@ static int __maybe_unused ak4458_runtime_suspend(struct device *dev)

	regcache_cache_only(ak4458->regmap, true);

	ak4458_power_off(ak4458);
	ak4458_reset(ak4458, true);

	if (ak4458->mute_gpiod)
		gpiod_set_value_cansleep(ak4458->mute_gpiod, 0);
@@ -685,8 +677,8 @@ static int __maybe_unused ak4458_runtime_resume(struct device *dev)
	if (ak4458->mute_gpiod)
		gpiod_set_value_cansleep(ak4458->mute_gpiod, 1);

	ak4458_power_off(ak4458);
	ak4458_power_on(ak4458);
	ak4458_reset(ak4458, true);
	ak4458_reset(ak4458, false);

	regcache_cache_only(ak4458->regmap, false);
	regcache_mark_dirty(ak4458->regmap);
Loading