Il 26/04/24 19:22, amergnat@baylibre.com ha scritto:
From: Nicolas Belin nbelin@baylibre.com
Add a specific soundcard for mt8365-evk. It supports audio jack in/out, dmics, the amic and lineout.
Signed-off-by: Nicolas Belin nbelin@baylibre.com Signed-off-by: Alexandre Mergnat amergnat@baylibre.com
sound/soc/mediatek/mt8365/mt8365-mt6357.c | 348 ++++++++++++++++++++++++++++++ 1 file changed, 348 insertions(+)
diff --git a/sound/soc/mediatek/mt8365/mt8365-mt6357.c b/sound/soc/mediatek/mt8365/mt8365-mt6357.c new file mode 100644 index 000000000000..a65f668103da --- /dev/null +++ b/sound/soc/mediatek/mt8365/mt8365-mt6357.c @@ -0,0 +1,348 @@ +// SPDX-License-Identifier: GPL-2.0 +/*
- Mediatek MT8365 Sound Card driver
- Copyright (c) 2024 MediaTek Inc.
- Authors: Nicolas Belin nbelin@baylibre.com
- */
+#include <linux/module.h> +#include <linux/of_gpio.h> +#include <sound/soc.h> +#include <sound/pcm_params.h> +#include "mt8365-afe-common.h" +#include <linux/pinctrl/consumer.h> +#include "../common/mtk-soc-card.h" +#include "../common/mtk-soundcard-driver.h"
..snip..
+static const struct mtk_soundcard_pdata mt8365_mt6357_card = {
- .card_name = "mt8365-mt6357",
- .card_data = &(struct mtk_platform_card_data) {
.card = &mt8365_mt6357_soc_card,
- },
- .soc_probe = mt8365_mt6357_dev_probe
+};
+static const struct of_device_id mt8365_mt6357_dt_match[] = {
- {
.compatible = "mediatek,mt8365-mt6357",
.data = &mt8365_mt6357_card,
- },
- { }
Please, compress and add sentinel
{ .compatible = "mediatek,mt8365-mt6357", .data = &mt8365_mt6357_card }, { /* sentinel */ }
after which
Reviewed-by: AngeloGioacchino Del Regno angelogioacchino.delregno@collabora.com
linaro-mm-sig@lists.linaro.org