[<prev] [next>] [day] [month] [year] [list]
Message-ID: <CA+Px+wX_L3s0-m8YOwAXa1szN3v8dqaY5OYfAVJb4HLTrAt5nQ@mail.gmail.com>
Date: Mon, 17 Aug 2020 13:21:53 +0800
From: Tzung-Bi Shih <tzungbi@...gle.com>
To: Jiaxin Yu <jiaxin.yu@...iatek.com>
Cc: Mark Brown <broonie@...nel.org>,
Matthias Brugger <matthias.bgg@...il.com>,
Rob Herring <robh+dt@...nel.org>,
Takashi Iwai <tiwai@...e.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
ALSA development <alsa-devel@...a-project.org>,
linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org, howie.huang@...iatek.com,
eason.yen@...iatek.com, shane.chien@...iatek.com,
bicycle.tasi@...iatek.com
Subject: Re: [PATCH v4 1/2] ASoC: mediatek: mt6359: add codec driver
On Sun, Aug 16, 2020 at 1:20 AM Jiaxin Yu <jiaxin.yu@...iatek.com> wrote:
>
> +static int mt6359_platform_driver_probe(struct platform_device *pdev)
[snip]
> +
> + return devm_snd_soc_register_component(&pdev->dev,
> + &mt6359_soc_component_driver,
> + mt6359_dai_driver,
> + ARRAY_SIZE(mt6359_dai_driver));
> +}
> +
> +static int mt6359_platform_driver_remove(struct platform_device *pdev)
> +{
> + struct mt6359_priv *priv = dev_get_drvdata(&pdev->dev);
> + int ret;
> +
> + dev_dbg(&pdev->dev, "%s(), dev name %s\n",
> + __func__, dev_name(&pdev->dev));
> +
> + ret = regulator_disable(priv->avdd_reg);
> + if (ret) {
> + dev_err(&pdev->dev, "%s(), failed to disable regulator!\n",
> + __func__);
> + return ret;
> + }
> +
> + snd_soc_unregister_component(&pdev->dev);
You don't need to unregister the component which is already delegated to devm.
Powered by blists - more mailing lists