public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Richard Fitzgerald <rf@opensource.cirrus.com>
To: <broonie@kernel.org>
Cc: <linux-kernel@vger.kernel.org>, <linux-sound@vger.kernel.org>,
	<patches@opensource.cirrus.com>,
	Richard Fitzgerald <rf@opensource.cirrus.com>,
	Dheeraj Reddy Jonnalagadda <dheeraj.linuxdev@gmail.com>
Subject: [PATCH] firmware: cs_dsp: Delete redundant assignments in cs_dsp_test_bin.c
Date: Thu, 19 Dec 2024 15:57:19 +0000	[thread overview]
Message-ID: <20241219155719.84276-1-rf@opensource.cirrus.com> (raw)

Delete two redundant assignments in cs_dsp_test_bin.c.

Unfortunately none of W=1 or the static analysis tools I ran
flagged these.

Fixes: dd0b6b1f29b9 ("firmware: cs_dsp: Add KUnit testing of bin file download")
Reported-by: Dheeraj Reddy Jonnalagadda <dheeraj.linuxdev@gmail.com>
Closes: https://scan7.scan.coverity.com/#/project-view/52337/11354?selectedIssue=1602511
Closes: https://scan7.scan.coverity.com/#/project-view/52337/11354?selectedIssue=1602490
Signed-off-by: Richard Fitzgerald <rf@opensource.cirrus.com>
---
 drivers/firmware/cirrus/test/cs_dsp_test_bin.c | 6 ------
 1 file changed, 6 deletions(-)

diff --git a/drivers/firmware/cirrus/test/cs_dsp_test_bin.c b/drivers/firmware/cirrus/test/cs_dsp_test_bin.c
index bbff6caee285..1e161bbc5b4a 100644
--- a/drivers/firmware/cirrus/test/cs_dsp_test_bin.c
+++ b/drivers/firmware/cirrus/test/cs_dsp_test_bin.c
@@ -500,9 +500,6 @@ static void bin_patch_one_word_multiple_algs(struct kunit *test)
 
 	/* Add one payload per algorithm */
 	for (i = 0; i < ARRAY_SIZE(bin_test_mock_algs); ++i) {
-		alg_base_words = cs_dsp_mock_xm_header_get_alg_base_in_words(priv,
-								bin_test_mock_algs[i].id,
-								param->mem_type);
 		reg_inc_per_word = cs_dsp_mock_reg_addr_inc_per_unpacked_word(priv);
 
 		cs_dsp_mock_bin_add_patch(priv->local->bin_builder,
@@ -566,9 +563,6 @@ static void bin_patch_one_word_multiple_algs_unordered(struct kunit *test)
 	/* Add one payload per algorithm */
 	for (i = 0; i < ARRAY_SIZE(bin_test_mock_algs); ++i) {
 		alg_idx = alg_order[i];
-		alg_base_words = cs_dsp_mock_xm_header_get_alg_base_in_words(priv,
-								bin_test_mock_algs[alg_idx].id,
-								param->mem_type);
 		reg_inc_per_word = cs_dsp_mock_reg_addr_inc_per_unpacked_word(priv);
 
 		cs_dsp_mock_bin_add_patch(priv->local->bin_builder,
-- 
2.43.0


             reply	other threads:[~2024-12-19 15:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-19 15:57 Richard Fitzgerald [this message]
2024-12-19 18:54 ` [PATCH] firmware: cs_dsp: Delete redundant assignments in cs_dsp_test_bin.c 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=20241219155719.84276-1-rf@opensource.cirrus.com \
    --to=rf@opensource.cirrus.com \
    --cc=broonie@kernel.org \
    --cc=dheeraj.linuxdev@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=patches@opensource.cirrus.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