-
Notifications
You must be signed in to change notification settings - Fork 309
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tools: Testbench: Convert file component to module adapter #8811
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,35 @@ | ||
// SPDX-License-Identifier: BSD-3-Clause | ||
// | ||
// Copyright(c) 2018 Intel Corporation. All rights reserved. | ||
// Copyright(c) 2018-2024 Intel Corporation. All rights reserved. | ||
|
||
#include <stdint.h> | ||
#include <stddef.h> | ||
#include <time.h> | ||
#include <stdio.h> | ||
#include <stdlib.h> | ||
#include <rtos/string.h> | ||
#include <math.h> | ||
#include <rtos/sof.h> | ||
#include <rtos/task.h> | ||
#include <rtos/alloc.h> | ||
#include <sof/lib/notifier.h> | ||
#include <sof/audio/component_ext.h> | ||
#include <sof/audio/pipeline.h> | ||
#include <sof/ipc/driver.h> | ||
#include <sof/ipc/topology.h> | ||
#include <sof/lib/agent.h> | ||
#include <sof/lib/dai.h> | ||
#include <sof/lib/dma.h> | ||
#include <sof/lib/notifier.h> | ||
#include <sof/schedule/edf_schedule.h> | ||
#include <sof/schedule/ll_schedule.h> | ||
#include <sof/schedule/ll_schedule_domain.h> | ||
#include <sof/schedule/schedule.h> | ||
#include <rtos/alloc.h> | ||
#include <rtos/sof.h> | ||
#include <rtos/string.h> | ||
#include <rtos/task.h> | ||
#include <rtos/wait.h> | ||
#include <sof/audio/pipeline.h> | ||
#include <sof/audio/component_ext.h> | ||
#include <tplg_parser/topology.h> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm following a rule for alphabetic sort for 4 levels, 3 levels, 2 levels, standard C headers last. I got such suggestion some time ago in review. Though these could go to other cosmetic changes patch. |
||
#include <math.h> | ||
#include <stddef.h> | ||
#include <stdint.h> | ||
#include <stdio.h> | ||
#include <stdlib.h> | ||
#include <time.h> | ||
|
||
#include "testbench/common_test.h" | ||
#include "testbench/trace.h" | ||
#include <tplg_parser/topology.h> | ||
#include "testbench/file.h" | ||
|
||
#if defined __XCC__ | ||
#include <xtensa/tie/xt_timer.h> | ||
|
@@ -43,7 +45,6 @@ int tb_setup(struct sof *sof, struct testbench_prm *tp) | |
|
||
/* init components */ | ||
sys_comp_init(sof); | ||
sys_comp_file_init(); | ||
sys_comp_selector_init(); | ||
|
||
/* Module adapter components */ | ||
|
@@ -53,6 +54,7 @@ int tb_setup(struct sof *sof, struct testbench_prm *tp) | |
sys_comp_module_drc_interface_init(); | ||
sys_comp_module_eq_fir_interface_init(); | ||
sys_comp_module_eq_iir_interface_init(); | ||
sys_comp_module_file_interface_init(); | ||
sys_comp_module_google_rtc_audio_processing_interface_init(); | ||
sys_comp_module_igo_nr_interface_init(); | ||
sys_comp_module_multiband_drc_interface_init(); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would suggest put reserved to the bottom of struct definition.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I did it this way since currently module adapter defaults to process type IPC unless I add exception handling to module adapter. The extra IPC data for file component is passed in the end of this struct.
I think I will try to another approach with CONFIG_LIBRARY exceptions added for SOF_COMP_FILEREAD and SOF_COMP_FILEWRITE. Not sure which is better.
Also this will be bit different with IPC4. I'm keeping this draft until I know better.