From: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
To: Daniel Golle <daniel@makrotopia.org>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>,
Takashi Iwai <tiwai@suse.com>,
Matthias Brugger <matthias.bgg@gmail.com>,
Maso Huang <maso.huang@mediatek.com>,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org
Subject: Re: [PATCH] ASoC: mediatek: mt7986: silence error in case of -EPROBE_DEFER
Date: Mon, 11 Dec 2023 10:48:54 +0100 [thread overview]
Message-ID: <1db19550-99c2-4094-95d9-9db1c384519f@collabora.com> (raw)
In-Reply-To: <98491ec78ab671f5a14fce42d10f9745ebddb112.1702258360.git.daniel@makrotopia.org>
Il 11/12/23 02:33, Daniel Golle ha scritto:
> If probe is defered no error should be printed. Mute it.
>
> Signed-off-by: Daniel Golle <daniel@makrotopia.org>
> ---
> sound/soc/mediatek/mt7986/mt7986-wm8960.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/sound/soc/mediatek/mt7986/mt7986-wm8960.c b/sound/soc/mediatek/mt7986/mt7986-wm8960.c
> index c1390b3734101..24a4b943030d7 100644
> --- a/sound/soc/mediatek/mt7986/mt7986-wm8960.c
> +++ b/sound/soc/mediatek/mt7986/mt7986-wm8960.c
> @@ -144,7 +144,9 @@ static int mt7986_wm8960_machine_probe(struct platform_device *pdev)
>
> ret = devm_snd_soc_register_card(&pdev->dev, card);
> if (ret) {
> - dev_err(&pdev->dev, "%s snd_soc_register_card fail: %d\n", __func__, ret);
> + if (ret != -EPROBE_DEFER)
> + dev_err(&pdev->dev, "%s snd_soc_register_card fail: %d\n", __func__, ret);
This is *exactly* what dev_err_probe() does! :-)
dev_err_probe(&pdev->dev, ret, "%s snd_soc_register_card fail: %d\n", __func__);
Regards,
Angelo
prev parent reply other threads:[~2023-12-11 9:58 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-11 1:33 Daniel Golle
2023-12-11 4:07 ` Fei Shao
2023-12-11 4:08 ` Maso Huang (黃加竹)
2023-12-11 9:48 ` AngeloGioacchino Del Regno [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1db19550-99c2-4094-95d9-9db1c384519f@collabora.com \
--to=angelogioacchino.delregno@collabora.com \
--cc=broonie@kernel.org \
--cc=daniel@makrotopia.org \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-sound@vger.kernel.org \
--cc=maso.huang@mediatek.com \
--cc=matthias.bgg@gmail.com \
--cc=perex@perex.cz \
--cc=tiwai@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®