From: Baojun Xu <baojun.xu@ti.com>
To: <tiwai@suse.de>
Cc: <robh+dt@kernel.org>, <andriy.shevchenko@linux.intel.com>,
<lgirdwood@gmail.com>, <perex@perex.cz>, <shenghao-ding@ti.com>,
<navada@ti.com>, <13916275206@139.com>, <v-hampiholi@ti.com>,
<v-po@ti.com>, <linux-sound@vger.kernel.org>,
<linux-kernel@vger.kernel.org>, <liam.r.girdwood@intel.com>,
<yung-chuan.liao@linux.intel.com>, <baojun.xu@ti.com>,
<broonie@kernel.org>, <antheas.dk@gmail.com>,
<stuart.a.hayhurst@gmail.com>, <dan.carpenter@linaro.org>
Subject: [PATCH v1] ALSA: hda/tas2781: Ignore SUBSYS_ID not found for tas2563 projects
Date: Sat, 11 Jan 2025 17:57:28 +0800 [thread overview]
Message-ID: <20250111095728.1232-1-baojun.xu@ti.com> (raw)
Driver will return error if no SUBSYS_ID found in BIOS(acpi).
It will cause error in tas2563 projects, which have no SUBSYS_ID.
Change strncmp to strcmp to avoid warning for weird length.
Signed-off-by: Baojun Xu <baojun.xu@ti.com>
---
sound/pci/hda/tas2781_hda_i2c.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/pci/hda/tas2781_hda_i2c.c b/sound/pci/hda/tas2781_hda_i2c.c
index 0e42b87dadb8..61aec92f6536 100644
--- a/sound/pci/hda/tas2781_hda_i2c.c
+++ b/sound/pci/hda/tas2781_hda_i2c.c
@@ -143,7 +143,7 @@ static int tas2781_read_acpi(struct tasdevice_priv *p, const char *hid)
sub = acpi_get_subsystem_id(ACPI_HANDLE(physdev));
if (IS_ERR(sub)) {
/* No subsys id in older tas2563 projects. */
- if (!strncmp(hid, "INT8866", sizeof("INT8866")))
+ if (!strcmp(hid, "INT8866"))
goto end_2563;
dev_err(p->dev, "Failed to get SUBSYS ID.\n");
ret = PTR_ERR(sub);
--
2.43.0
next reply other threads:[~2025-01-11 9:58 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-01-11 9:57 Baojun Xu [this message]
2025-01-12 8:26 ` [PATCH v1] ALSA: hda/tas2781: Ignore SUBSYS_ID not found for tas2563 projects Takashi Iwai
2025-01-13 5:33 ` Dan Carpenter
2025-01-13 6:41 ` [EXTERNAL] " Xu, Baojun
2025-01-13 7:47 ` Takashi Iwai
-- strict thread matches above, loose matches on Subject: below --
2024-12-30 6:49 Baojun Xu
2024-12-30 10:40 ` Takashi Iwai
2025-01-13 8:37 ` Andy Shevchenko
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=20250111095728.1232-1-baojun.xu@ti.com \
--to=baojun.xu@ti.com \
--cc=13916275206@139.com \
--cc=andriy.shevchenko@linux.intel.com \
--cc=antheas.dk@gmail.com \
--cc=broonie@kernel.org \
--cc=dan.carpenter@linaro.org \
--cc=lgirdwood@gmail.com \
--cc=liam.r.girdwood@intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=navada@ti.com \
--cc=perex@perex.cz \
--cc=robh+dt@kernel.org \
--cc=shenghao-ding@ti.com \
--cc=stuart.a.hayhurst@gmail.com \
--cc=tiwai@suse.de \
--cc=v-hampiholi@ti.com \
--cc=v-po@ti.com \
--cc=yung-chuan.liao@linux.intel.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