From: Takashi Iwai <tiwai@suse.de>
To: med.jebabli@gmail.com
Cc: regressions@lists.linux.dev,
Cristian Castellano <cristian.castellano@icloud.com>,
stable@vger.kernel.org, Takashi Iwai <tiwai@suse.com>,
Jaroslav Kysela <perex@perex.cz>,
linux-sound@vger.kernel.org, linux-kernel@vger.kernel.org,
Thorsten Leemhuis <regressions@leemhuis.info>,
Shenghao Ding <shenghao-ding@ti.com>, Kevin Lu <kevin-lu@ti.com>,
Baojun Xu <baojun.xu@ti.com>, Sen Wang <sen@ti.com>
Subject: Re: [PATCH] ALSA: hda/tas2781: Only accept CRC-less V1 data if all entries are valid
Date: Wed, 04 Nov 2026 08:22:15 +0100 [thread overview]
Message-ID: <87pkwlukm0.wl-tiwai@suse.de> (raw)
In-Reply-To: <20261103-tas2781-v1-nocrc-fix-v1-1-a769c27f21ce@gmail.com>
On Tue, 03 Nov 2026 10:27:12 +0100,
Mohamed Yassine Jebabli via B4 Relay wrote:
>
> From: Mohamed Yassine Jebabli <med.jebabli@gmail.com>
>
> Commit 408249089c48 ("ALSA: hda/tas2781: Accept V1 calibration data
> without CRC") only checked the first device entry. On machines where
> the BIOS populates fewer entries than p->ndev, the remaining all-zero
> entries are applied and tas2781_cali_preproc() divides by zero on
> playback open.
>
> Accept CRC-less V1 data only if every expected entry is non-zero and
> self-consistent (R0 * 1/R0 close to 1.0), otherwise reject it as
> before.
>
> Fixes: 408249089c48 ("ALSA: hda/tas2781: Accept V1 calibration data without CRC")
> Reported-by: Cristian Castellano <cristian.castellano@icloud.com>
> Closes: https://lore.kernel.org/all/4e500063-d985-46b6-a0a1-3feaa77c4b2f@leemhuis.info/
> Cc: stable@vger.kernel.org
> Signed-off-by: Mohamed Yassine Jebabli <med.jebabli@gmail.com>
> ---
> Cristian, could you test this on the Yoga Pro 9 16IRP8? With the fix,
> the driver should log "V1 CRC error" again and fall back to default
> parameters, as it did before 408249089c48. If it still logs
> "accepting", p->ndev is 2 on your machine and the root cause is
> elsewhere, so please send the full "dmesg | grep -i tas2781".
>
> Takashi's re_cal check in tas2781_cali_preproc() is complementary
> and still worth applying as a safeguard.
As the code looks safe enough, I applied now.
Let me know if the problem still happens.
I'm going to submit my zero-check patch as a further hardening, too.
thanks,
Takashi
next prev parent reply other threads:[~2026-11-04 7:22 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-03 9:27 Mohamed Yassine Jebabli via B4 Relay
2026-11-04 7:22 ` Takashi Iwai [this message]
2026-11-04 15:55 ` Gergo Koteles
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=87pkwlukm0.wl-tiwai@suse.de \
--to=tiwai@suse.de \
--cc=baojun.xu@ti.com \
--cc=cristian.castellano@icloud.com \
--cc=kevin-lu@ti.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=med.jebabli@gmail.com \
--cc=perex@perex.cz \
--cc=regressions@leemhuis.info \
--cc=regressions@lists.linux.dev \
--cc=sen@ti.com \
--cc=shenghao-ding@ti.com \
--cc=stable@vger.kernel.org \
--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®