summaryrefslogtreecommitdiff
path: root/sound
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2024-07-30 05:05:30 +0300
committerTakashi Iwai <tiwai@suse.de>2024-08-01 13:50:13 +0300
commita48fee68a8fa35fc1a9b924c06d3e023d067ff41 (patch)
tree6085c09bd406efd8ac3449e19ea89dbfce73a9dc /sound
parente1a642aba479e861e3d552b0548d1274d6a1c122 (diff)
downloadlinux-a48fee68a8fa35fc1a9b924c06d3e023d067ff41.tar.xz
ALSA: pcm_timer: use snd_pcm_direction_name()
We already have snd_pcm_direction_name(). Let's use it. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Link: https://patch.msgid.link/87plqvk51y.wl-kuninori.morimoto.gx@renesas.com Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/core/pcm_timer.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sound/core/pcm_timer.c b/sound/core/pcm_timer.c
index c43484b22b34..ab0e5bd70f8f 100644
--- a/sound/core/pcm_timer.c
+++ b/sound/core/pcm_timer.c
@@ -108,8 +108,7 @@ void snd_pcm_timer_init(struct snd_pcm_substream *substream)
if (snd_timer_new(substream->pcm->card, "PCM", &tid, &timer) < 0)
return;
sprintf(timer->name, "PCM %s %i-%i-%i",
- substream->stream == SNDRV_PCM_STREAM_CAPTURE ?
- "capture" : "playback",
+ snd_pcm_direction_name(substream->stream),
tid.card, tid.device, tid.subdevice);
timer->hw = snd_pcm_timer;
if (snd_device_register(timer->card, timer) < 0) {