From 10a5bdb82955126dc7404098387afbfa6f27e39f Mon Sep 17 00:00:00 2001 From: Rander Wang Date: Tue, 18 Jan 2022 09:19:52 +0800 Subject: [PATCH] ipc4: change frame_fmt and valid_sample_fmt for gateway First we reused ipc3 pcm conversion function by by setting frame_fmt to S24_4LE, but later found that we need different conversion for copier with gateways support. Now frame_fmt will be set by default config. Signed-off-by: Rander Wang --- src/include/sof/audio/audio_stream.h | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/src/include/sof/audio/audio_stream.h b/src/include/sof/audio/audio_stream.h index 56e2934ea..3037cf35a 100644 --- a/src/include/sof/audio/audio_stream.h +++ b/src/include/sof/audio/audio_stream.h @@ -624,13 +624,9 @@ static inline void audio_stream_fmt_conversion(enum ipc4_bit_depth depth, *valid_fmt = (valid >> 3) - 2; /* really 24_3LE */ - if (valid == 24) { - if (depth == 24) { - *frame_fmt = SOF_IPC_FRAME_S24_3LE; - *valid_fmt = SOF_IPC_FRAME_S24_3LE; - } else { - *frame_fmt = SOF_IPC_FRAME_S24_4LE; - } + if (valid == 24 && depth == 24) { + *frame_fmt = SOF_IPC_FRAME_S24_3LE; + *valid_fmt = SOF_IPC_FRAME_S24_3LE; } if (type == IPC4_TYPE_FLOAT && depth == 32) {