All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chandra Mohan Sundar <chandramohan.explore@gmail.com>
To: perex@perex.cz, tiwai@suse.com, phasta@kernel.org,
	linux-sound@vger.kernel.org, shuah@kernel.org
Cc: Chandra Mohan Sundar <chandramohan.explore@gmail.com>,
	linux-kernel-mentees@lists.linux.dev
Subject: [PATCH] ALSA: cs4281: Send the PCM period elapsed notification properly
Date: Sat,  6 Sep 2025 21:51:54 +0530	[thread overview]
Message-ID: <20250906162158.564899-1-chandramohan.explore@gmail.com> (raw)

As part of spin lock code cleanup using guard(), a new
variable (period_elapsed) was introduced. However this variable
is never set, causing period elapsed notification to be not sent.

Set the value of period_elapsed appropiately.

This issue was reported by static coverity analyzer.

Fixes: 7a5127c2c8a5a ("ALSA: cs4281: Use guard() for spin locks")
Signed-off-by: Chandra Mohan Sundar <chandramohan.explore@gmail.com>
---
 sound/pci/cs4281.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/sound/pci/cs4281.c b/sound/pci/cs4281.c
index c519fb9cdd1e..d00b2c9fb1e3 100644
--- a/sound/pci/cs4281.c
+++ b/sound/pci/cs4281.c
@@ -1752,6 +1752,7 @@ static irqreturn_t snd_cs4281_interrupt(int irq, void *dev_id)
 					chip->spurious_dtc_irq++;
 					continue;
 				}
+				period_elapsed = true;
 			}
 			if (period_elapsed)
 				snd_pcm_period_elapsed(cdma->substream);
-- 
2.43.0


             reply	other threads:[~2025-09-06 16:22 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-09-06 16:21 Chandra Mohan Sundar [this message]
2025-09-06 17:56 ` [PATCH] ALSA: cs4281: Send the PCM period elapsed notification properly Takashi Iwai

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=20250906162158.564899-1-chandramohan.explore@gmail.com \
    --to=chandramohan.explore@gmail.com \
    --cc=linux-kernel-mentees@lists.linux.dev \
    --cc=linux-sound@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=phasta@kernel.org \
    --cc=shuah@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.