smart_amp: fix code and re-enable it on stub builds

Removes the misplaced code in smart_amp.c for the fix, then
re-enables CONFIG_COMP_SMART_AMP on building stub images.

Signed-off-by: Pin-chih Lin <johnylin@google.com>
This commit is contained in:
Pin-chih Lin 2023-11-01 08:48:47 +08:00 committed by Kai Vehmanen
parent d294036fd5
commit d4d0a0ca13
2 changed files with 3 additions and 9 deletions

View File

@ -9,9 +9,5 @@ CONFIG_WAVES_CODEC=y
CONFIG_DTS_CODEC=y
CONFIG_COMP_IGO_NR=y
CONFIG_COMP_RTNR=y
# temporarily disabled until it compiles:
# sof/src/audio/smart_amp/smart_amp.c:748:9: error:
# no member named 'in_channels' in 'struct smart_amp_data'
# sad->in_channels = audio_stream_get_channels(&source_buffer->stream);
CONFIG_COMP_SMART_AMP=n
CONFIG_COMP_SMART_AMP=y
CONFIG_MAXIM_DSM=y

View File

@ -741,12 +741,10 @@ static int smart_amp_prepare(struct comp_dev *dev)
struct comp_buffer *source_buffer = container_of(blist, struct comp_buffer,
sink_list);
if (source_buffer->source->ipc_config.type == SOF_COMP_DEMUX) {
if (source_buffer->source->ipc_config.type == SOF_COMP_DEMUX)
sad->feedback_buf = source_buffer;
} else {
else
sad->source_buf = source_buffer;
sad->in_channels = audio_stream_get_channels(&source_buffer->stream);
}
}
/* sink buffer */