]> git.baikalelectronics.ru Git - kernel.git/commitdiff
ALSA: hda: cs35l41: Add calls to newly added test key function
authorCharles Keepax <ckeepax@opensource.cirrus.com>
Mon, 17 Jan 2022 16:08:26 +0000 (16:08 +0000)
committerTakashi Iwai <tiwai@suse.de>
Tue, 18 Jan 2022 13:07:13 +0000 (14:07 +0100)
The test key now needs to be manually held when calling
cs35l41_register_errata_patch, after patch:

Add the missing function calls to this driver.

Fixes: 47e5b0f47eb0 ("ASoC: cs35l41: Add support for hibernate memory retention mode")
Signed-off-by: Charles Keepax <ckeepax@opensource.cirrus.com>
Signed-off-by: Lucas Tanure <tanureal@opensource.cirrus.com>
Link: https://lore.kernel.org/r/20220117160830.709403-2-tanureal@opensource.cirrus.com
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/pci/hda/cs35l41_hda.c

index c47c5f0b4e59ce965adf01fe030ae9ac494b9d31..509a380f9be7fe1402eacc248c155ba224b7f071 100644 (file)
@@ -463,6 +463,10 @@ int cs35l41_hda_probe(struct device *dev, const char *device_name, int id, int i
                goto err;
        }
 
+       ret = cs35l41_test_key_unlock(cs35l41->dev, cs35l41->regmap);
+       if (ret)
+               goto err;
+
        ret = cs35l41_register_errata_patch(cs35l41->dev, cs35l41->regmap, reg_revid);
        if (ret)
                goto err;
@@ -473,6 +477,10 @@ int cs35l41_hda_probe(struct device *dev, const char *device_name, int id, int i
                goto err;
        }
 
+       ret = cs35l41_test_key_lock(cs35l41->dev, cs35l41->regmap);
+       if (ret)
+               goto err;
+
        ret = cs35l41_hda_apply_properties(cs35l41, acpi_hw_cfg);
        if (ret)
                goto err;