]> git.itanic.dy.fi Git - linux-stable/commitdiff
gpiolib: of: Add quirk for mt2701-cs42448 ASoC sound
authorLinus Walleij <linus.walleij@linaro.org>
Fri, 6 Oct 2023 13:46:24 +0000 (15:46 +0200)
committerMark Brown <broonie@kernel.org>
Mon, 9 Oct 2023 13:27:43 +0000 (14:27 +0100)
These gpio names are due to old DT bindings not following the
"-gpio"/"-gpios" conventions. Handle it using a quirk so the
driver can just look up the GPIOs.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
Link: https://lore.kernel.org/r/20231006-descriptors-asoc-mediatek-v1-1-07fe79f337f5@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/gpio/gpiolib-of.c

index 531faabead0f40feb60e583f33b7e0bbfa70e0e3..d9525d95e818d77d5800119a9e90071b572ef484 100644 (file)
@@ -512,6 +512,10 @@ static struct gpio_desc *of_find_gpio_rename(struct device_node *np,
 #if IS_ENABLED(CONFIG_SND_SOC_CS42L56)
                { "reset",      "cirrus,gpio-nreset",   "cirrus,cs42l56" },
 #endif
+#if IS_ENABLED(CONFIG_SND_SOC_MT2701_CS42448)
+               { "i2s1-in-sel-gpio1",  NULL,   "mediatek,mt2701-cs42448-machine" },
+               { "i2s1-in-sel-gpio2",  NULL,   "mediatek,mt2701-cs42448-machine" },
+#endif
 #if IS_ENABLED(CONFIG_SND_SOC_TLV320AIC3X)
                { "reset",      "gpio-reset",   "ti,tlv320aic3x" },
                { "reset",      "gpio-reset",   "ti,tlv320aic33" },