From: Richard Fitzgerald <rf@opensource.cirrus.com>
To: Harshit Mogalapalli <harshit.m.mogalapalli@oracle.com>,
David Rhodes <david.rhodes@cirrus.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>, Jaroslav Kysela <perex@perex.cz>,
Takashi Iwai <tiwai@suse.com>,
Stuart Henderson <stuarth@opensource.cirrus.com>,
Piotr Stankiewicz <piotrs@opensource.cirrus.com>,
Qi Zhou <qi.zhou@cirrus.com>,
linux-sound@vger.kernel.org, patches@opensource.cirrus.com,
linux-kernel@vger.kernel.org
Cc: dan.carpenter@linaro.org, kernel-janitors@vger.kernel.org,
error27@gmail.com
Subject: Re: [PATCH] ASoC: cs48l32: Fix a signedness bug in cs48l32_hw_params()
Date: Fri, 6 Jun 2025 11:00:41 +0100 [thread overview]
Message-ID: <f18e207f-94fb-4197-a96a-45231129956c@opensource.cirrus.com> (raw)
In-Reply-To: <20250603214813.197346-1-harshit.m.mogalapalli@oracle.com>
On 03/06/2025 10:48 pm, Harshit Mogalapalli wrote:
> There is a type promotion that can happen when freq(u32) variable is
> comapared with sclk_target(integer), when sclk_target is a negative
> value it promotes to a large postive integer which might not be a
> problem in this particular case as the condition evaluates to false
> when that happens, but bail out early when sclk_target has negative
> error codes.
>
> cs48l32_sclk_rates[i].freq >= sclk_target
>
> Fix this by adding a negative error check when
> snd_soc_tdm_params_to_bclk() fails
>
> Fixes: e2bcbf99d045 ("ASoC: cs48l32: Add driver for Cirrus Logic CS48L32 audio DSP")
> Signed-off-by: Harshit Mogalapalli <harshit.m.mogalapalli@oracle.com>
Reviewed-by: Richard Fitzgerald <rf@opensource.cirrus.com>
next prev parent reply other threads:[~2025-06-06 10:01 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-03 21:48 Harshit Mogalapalli
2025-06-06 10:00 ` Richard Fitzgerald [this message]
2025-06-09 13:40 ` 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=f18e207f-94fb-4197-a96a-45231129956c@opensource.cirrus.com \
--to=rf@opensource.cirrus.com \
--cc=broonie@kernel.org \
--cc=dan.carpenter@linaro.org \
--cc=david.rhodes@cirrus.com \
--cc=error27@gmail.com \
--cc=harshit.m.mogalapalli@oracle.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-sound@vger.kernel.org \
--cc=patches@opensource.cirrus.com \
--cc=perex@perex.cz \
--cc=piotrs@opensource.cirrus.com \
--cc=qi.zhou@cirrus.com \
--cc=stuarth@opensource.cirrus.com \
--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®