From: Takashi Iwai <tiwai@suse.de>
To: Mark Brown <broonie@kernel.org>
Cc: Ravulapati Vishnu vardhan rao
<Vishnuvardhanrao.Ravulapati@amd.com>,
alsa-devel@alsa-project.org,
Akshu Agrawal <akshu.agrawal@amd.com>
Subject: [PATCH 2/2] ASoC: amd: Return -ENODEV for non-existing ACPI call
Date: Fri, 27 Nov 2020 15:31:59 +0100 [thread overview]
Message-ID: <20201127143200.16272-3-tiwai@suse.de> (raw)
In-Reply-To: <20201127143200.16272-1-tiwai@suse.de>
AMD Renoir driver tries to identify the presence of DMIC by evaluating
ACPI _WOV entry, and it returns -EINVAL when the ACPI call failed.
This ended up an error message like
snd_rn_pci_acp3x: probe of 0000:04:00.5 failed with error -22
although the system is correctly set up.
For avoiding such a superfluous error message, change the return value
to -ENODEV. Then the driver core just skips to the next one without
complaining.
BugLink: https://bugzilla.kernel.org/show_bug.cgi?id=210359
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
sound/soc/amd/renoir/rn-pci-acp3x.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/amd/renoir/rn-pci-acp3x.c b/sound/soc/amd/renoir/rn-pci-acp3x.c
index b943e59fc302..877350f38a68 100644
--- a/sound/soc/amd/renoir/rn-pci-acp3x.c
+++ b/sound/soc/amd/renoir/rn-pci-acp3x.c
@@ -224,7 +224,7 @@ static int snd_rn_acp_probe(struct pci_dev *pci,
handle = ACPI_HANDLE(&pci->dev);
ret = acpi_evaluate_integer(handle, "_WOV", NULL, &dmic_status);
if (ACPI_FAILURE(ret)) {
- ret = -EINVAL;
+ ret = -ENODEV;
goto de_init;
}
if (!dmic_status) {
--
2.26.2
next prev parent reply other threads:[~2020-11-27 14:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-11-27 14:31 [PATCH 0/2] ASoC: amd: Minor fixes for error handling Takashi Iwai
2020-11-27 14:31 ` [PATCH 1/2] ASoC: amd: Downgrade print level for invalid ACP mode Takashi Iwai
2020-11-27 14:31 ` Takashi Iwai [this message]
2020-11-30 16:55 ` [PATCH 0/2] ASoC: amd: Minor fixes for error handling Mark Brown
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=20201127143200.16272-3-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=Vishnuvardhanrao.Ravulapati@amd.com \
--cc=akshu.agrawal@amd.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).