diff mbox series

ASoC: soc-pcm: remove snd_soc_dpcm_stream_lock_irqsave_nested()

Message ID 874j87ll7k.wl-kuninori.morimoto.gx@renesas.com
State Superseded
Headers show
Series ASoC: soc-pcm: remove snd_soc_dpcm_stream_lock_irqsave_nested() | expand

Commit Message

Kuninori Morimoto July 30, 2024, 1:31 a.m. UTC
soc-pcm.c has snd_soc_dpcm_stream_lock_irqsave_nested() /
snd_soc_dpcm_stream_unlock_irqrestore()  helper function,
but it is almost nothing help. It just makes a code complex.
Let's remove it.

Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
---
 sound/soc/soc-pcm.c | 10 ++--------
 1 file changed, 2 insertions(+), 8 deletions(-)

Comments

Mark Brown Aug. 14, 2024, 5:19 p.m. UTC | #1
On Tue, Jul 30, 2024 at 01:31:11AM +0000, Kuninori Morimoto wrote:
> soc-pcm.c has snd_soc_dpcm_stream_lock_irqsave_nested() /
> snd_soc_dpcm_stream_unlock_irqrestore()  helper function,
> but it is almost nothing help. It just makes a code complex.
> Let's remove it.

This doesn't apply against current code, please check and resend.
Mark Brown Aug. 21, 2024, 3:24 p.m. UTC | #2
On Tue, 30 Jul 2024 01:31:11 +0000, Kuninori Morimoto wrote:
> soc-pcm.c has snd_soc_dpcm_stream_lock_irqsave_nested() /
> snd_soc_dpcm_stream_unlock_irqrestore()  helper function,
> but it is almost nothing help. It just makes a code complex.
> Let's remove it.
> 
> 

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: soc-pcm: remove snd_soc_dpcm_stream_lock_irqsave_nested()
      commit: 2d3b218d383e24623070f4439a0af64d200eb740

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark
diff mbox series

Patch

diff --git a/sound/soc/soc-pcm.c b/sound/soc/soc-pcm.c
index 58381801e41d4..4571785736f76 100644
--- a/sound/soc/soc-pcm.c
+++ b/sound/soc/soc-pcm.c
@@ -49,12 +49,6 @@  static inline int _soc_pcm_ret(struct snd_soc_pcm_runtime *rtd,
 	return ret;
 }
 
-#define snd_soc_dpcm_stream_lock_irqsave_nested(rtd, stream, flags) \
-	snd_pcm_stream_lock_irqsave_nested(snd_soc_dpcm_get_substream(rtd, stream), flags)
-
-#define snd_soc_dpcm_stream_unlock_irqrestore(rtd, stream, flags) \
-	snd_pcm_stream_unlock_irqrestore(snd_soc_dpcm_get_substream(rtd, stream), flags)
-
 #define DPCM_MAX_BE_USERS	8
 
 static inline const char *soc_cpu_dai_name(struct snd_soc_pcm_runtime *rtd)
@@ -2144,7 +2138,7 @@  int dpcm_be_dai_trigger(struct snd_soc_pcm_runtime *fe, int stream,
 		be = dpcm->be;
 		be_substream = snd_soc_dpcm_get_substream(be, stream);
 
-		snd_soc_dpcm_stream_lock_irqsave_nested(be, stream, flags);
+		snd_pcm_stream_lock_irqsave_nested(be_substream, flags);
 
 		/* is this op for this BE ? */
 		if (!snd_soc_dpcm_be_can_update(fe, be, stream))
@@ -2291,7 +2285,7 @@  int dpcm_be_dai_trigger(struct snd_soc_pcm_runtime *fe, int stream,
 			break;
 		}
 next:
-		snd_soc_dpcm_stream_unlock_irqrestore(be, stream, flags);
+		snd_pcm_stream_unlock_irqrestore(be_substream, flags);
 		if (ret)
 			break;
 	}