Re: [PATCH] ASoC: loongson: Fix naming of machine event and DAPM widgets

Keguang Zhang <[email protected]>
Newsgroups gmane.linux.sound
Message-ID <CAJhJPsU=2CPB=LzRf_-=waVQvAajXQwzGO4ANP0spSvNyGEmPA@mail.gmail.com>
Reviewed-by: Keguang Zhang <[email protected]>

On Tue, Aug 18, 2026 at 5:21 PM Binbin Zhou <[email protected]> wrote:
>
> Rename `tegra_machine_event` to `loongson_asoc_machine_event` and
> `loongson_aosc_dapm_widgets` to `loongson_asoc_dapm_widgets` to
> accurately reflect the hardware platform. Update all references
> accordingly.
>
> No functional change is introduced.
>
> Signed-off-by: Binbin Zhou <[email protected]>
> ---
>  sound/soc/loongson/loongson_card.c | 14 +++++++-------
>  1 file changed, 7 insertions(+), 7 deletions(-)
>
> diff --git a/sound/soc/loongson/loongson_card.c b/sound/soc/loongson/loongson_card.c
> index 25cd12eab4b1..6422cc1703b6 100644
> --- a/sound/soc/loongson/loongson_card.c
> +++ b/sound/soc/loongson/loongson_card.c
> @@ -55,8 +55,8 @@ static const struct loongson_card_config ls2k0300_dl2k0300b_card_config = {
>         .add_dapm_routes = true,
>  };
>
> -static int tegra_machine_event(struct snd_soc_dapm_widget *w,
> -                              struct snd_kcontrol *k, int event)
> +static int loongson_asoc_machine_event(struct snd_soc_dapm_widget *w,
> +                                      struct snd_kcontrol *k, int event)
>  {
>         struct snd_soc_card *card = snd_soc_dapm_to_card(w->dapm);
>         struct loongson_card_data *priv = snd_soc_card_get_drvdata(card);
> @@ -72,9 +72,9 @@ static int tegra_machine_event(struct snd_soc_dapm_widget *w,
>         return 0;
>  }
>
> -static const struct snd_soc_dapm_widget loongson_aosc_dapm_widgets[] = {
> -       SND_SOC_DAPM_HP("Headphone", tegra_machine_event),
> -       SND_SOC_DAPM_SPK("Speaker", tegra_machine_event),
> +static const struct snd_soc_dapm_widget loongson_asoc_dapm_widgets[] = {
> +       SND_SOC_DAPM_HP("Headphone", loongson_asoc_machine_event),
> +       SND_SOC_DAPM_SPK("Speaker", loongson_asoc_machine_event),
>  };
>
>  /* Headphones Jack */
> @@ -314,8 +314,8 @@ static int loongson_asoc_card_probe(struct platform_device *pdev)
>         card->num_links = ARRAY_SIZE(loongson_dai_links);
>
>         if (ls_priv->cfg->add_dapm_widgets) {
> -               card->dapm_widgets = loongson_aosc_dapm_widgets;
> -               card->num_dapm_widgets = ARRAY_SIZE(loongson_aosc_dapm_widgets);
> +               card->dapm_widgets = loongson_asoc_dapm_widgets;
> +               card->num_dapm_widgets = ARRAY_SIZE(loongson_asoc_dapm_widgets);
>         }
>
>         snd_soc_card_set_drvdata(card, ls_priv);
>
> base-commit: 2792cc1b80b7674cc0751b34a964aad76630c1fa
> --
> 2.52.0
>


-- 
Best regards,

Keguang Zhang
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.