summaryrefslogtreecommitdiff
path: root/sound/soc/sof
diff options
context:
space:
mode:
authorMark Brown <broonie@kernel.org>2024-10-23 18:07:47 +0100
committerMark Brown <broonie@kernel.org>2024-10-23 18:07:47 +0100
commita77e6c12cd9755cff27a3ed8bafe403284d46bb8 (patch)
tree397aa5da9a13471e4e1f4bfe57a2d0759ccd24c9 /sound/soc/sof
parent9c2e48ee9aa64f609709eeb120cf728d66d4a145 (diff)
parenta6ff8572fd3fafe3f0f39e94ad8d4b6c88de7e03 (diff)
downloadlwn-a77e6c12cd9755cff27a3ed8bafe403284d46bb8.tar.gz
lwn-a77e6c12cd9755cff27a3ed8bafe403284d46bb8.zip
ASoC: remove dpcm_xxx flags
Merge series from Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>: Now, we don't need to use dpcm_playback/capture flags for DPCM since v6.11, and thus we can use playback/capture_only flags instead too for DPCM, which is same as non-DPCM. Let's remove dpcm_playback/capture flags, and use playback/capture_only flags instead. [Before] [After] dpcm_playback = 1; /* no setting is needed */ dpcm_capture = 1; dpcm_playback = 1; playback_only = 1; dpcm_capture = 0; dpcm_playback = 0; capture_only = 1; dpcm_capture = 1; And then, because no-one uses dpcm_xxx flags, we don't need to have the code for both DPCM and non-DPCM. These can be handled by same code.
Diffstat (limited to 'sound/soc/sof')
-rw-r--r--sound/soc/sof/nocodec.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sound/soc/sof/nocodec.c b/sound/soc/sof/nocodec.c
index b12b3d865ae3..c0c906a78eba 100644
--- a/sound/soc/sof/nocodec.c
+++ b/sound/soc/sof/nocodec.c
@@ -55,10 +55,9 @@ static int sof_nocodec_bes_setup(struct device *dev,
links[i].no_pcm = 1;
links[i].cpus->dai_name = drv[i].name;
links[i].platforms->name = dev_name(dev->parent);
- if (drv[i].playback.channels_min)
- links[i].dpcm_playback = 1;
- if (drv[i].capture.channels_min)
- links[i].dpcm_capture = 1;
+
+ links[i].playback_only = drv[i].playback.channels_min && !drv[i].capture.channels_min;
+ links[i].capture_only = !drv[i].playback.channels_min && drv[i].capture.channels_min;
links[i].be_hw_params_fixup = sof_pcm_dai_link_fixup;
}