[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220930103836.104113-2-chenzhongjin@huawei.com>
Date: Fri, 30 Sep 2022 18:38:33 +0800
From: Chen Zhongjin <chenzhongjin@...wei.com>
To: <linux-kernel@...r.kernel.org>, <alsa-devel@...a-project.org>
CC: <perex@...ex.cz>, <tiwai@...e.com>, <jayakumar.alsa@...il.com>,
<chenzhongjin@...wei.com>, <wangjianli@...rlc.com>
Subject: [PATCH -next 1/4] ALSA: rawmidi: Remove unused variable 'dest_frames'
Reported by Clang [-Wunused-but-set-variable]
'commit 08fdced60ca0 ("ALSA: rawmidi: Add framing mode")'
This commit introduced the variable 'dest_frames'.
However this variable was never used except iterates itself.
It seems that it's some undeleted debug code. Remove it for code
cleaning.
Signed-off-by: Chen Zhongjin <chenzhongjin@...wei.com>
---
sound/core/rawmidi.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/sound/core/rawmidi.c b/sound/core/rawmidi.c
index 6963d5a487b3..3cd944386e51 100644
--- a/sound/core/rawmidi.c
+++ b/sound/core/rawmidi.c
@@ -1050,7 +1050,6 @@ static int receive_with_tstamp_framing(struct snd_rawmidi_substream *substream,
struct snd_rawmidi_runtime *runtime = substream->runtime;
struct snd_rawmidi_framing_tstamp *dest_ptr;
struct snd_rawmidi_framing_tstamp frame = { .tv_sec = tstamp->tv_sec, .tv_nsec = tstamp->tv_nsec };
- int dest_frames = 0;
int orig_count = src_count;
int frame_size = sizeof(struct snd_rawmidi_framing_tstamp);
@@ -1077,7 +1076,6 @@ static int receive_with_tstamp_framing(struct snd_rawmidi_substream *substream,
runtime->avail += frame_size;
runtime->hw_ptr += frame_size;
runtime->hw_ptr %= runtime->buffer_size;
- dest_frames++;
}
return orig_count - src_count;
}
--
2.17.1
Powered by blists - more mailing lists