Skip to content

Commit

Permalink
audio: remove unnecessary inclusion of lib/memory.h
Browse files Browse the repository at this point in the history
Remove unnecessary incluce statements for lib/memory.h in large number
of files in audio. Some are pure bad copy and paste, while in some
cases the module has in the past used SHARED_DATA macro, but this has
been since been removed. The SHARED_DATA use might be removed later,
so add a comment to files where lib/memory.h is only included for
this one macro.

Signed-off-by: Kai Vehmanen <kai.vehmanen@linux.intel.com>
  • Loading branch information
kv2019i committed Oct 9, 2024
1 parent 95373db commit ec8cf20
Show file tree
Hide file tree
Showing 46 changed files with 10 additions and 46 deletions.
1 change: 0 additions & 1 deletion src/audio/aria/aria.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <rtos/alloc.h>
#include <rtos/cache.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/notifier.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/asrc/asrc.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/math/numbers.h>
#include <sof/trace/trace.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/asrc/asrc_ipc3.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
#include <sof/audio/ipc-config.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/trace/trace.h>
#include <sof/common.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/asrc/asrc_ipc4.c
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
#include <sof/audio/ipc-config.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/trace/trace.h>
#include <sof/common.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/base_fw.c
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
//

#include <sof/audio/component.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/ut.h>
#include <sof/tlv.h>
#include <ipc4/base_fw.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/buffers/comp_buffer.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include <rtos/interrupt.h>
#include <rtos/alloc.h>
#include <rtos/cache.h>
#include <sof/lib/memory.h>
#include <sof/lib/notifier.h>
#include <sof/list.h>
#include <rtos/spinlock.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/component.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/cache.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/list.h>
#include <rtos/sof.h>
#include <rtos/string.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/copier/copier.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
#include <rtos/alloc.h>
#include <rtos/cache.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <rtos/string.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/copier/copier_ipcgtw.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
#include <sof/audio/component_ext.h>
#include <sof/trace/trace.h>
#include <sof/lib/uuid.h>
#include <sof/lib/memory.h>
#include <sof/ut.h>
#include <rtos/init.h>
#include "copier.h"
Expand Down
1 change: 0 additions & 1 deletion src/audio/crossover/crossover.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/math/iir_df2t.h>
#include <sof/list.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/dai-legacy.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include <rtos/cache.h>
#include <rtos/init.h>
#include <sof/lib/dai.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/notifier.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/dai-zephyr.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
#include <rtos/cache.h>
#include <rtos/init.h>
#include <sof/lib/dai.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/notifier.h>
#include <sof/lib/uuid.h>
#include <sof/lib/dma.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/dcblock/dcblock.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/platform.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/drc/drc.c
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <sof/audio/ipc-config.h>
#include <sof/audio/pipeline.h>
#include <sof/ipc/msg.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/math/numbers.h>
#include <sof/trace/trace.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/eq_fir/eq_fir.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/fir_config.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/eq_iir/eq_iir.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/platform.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/eq_iir/eq_iir_generic.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/iir_df1.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/eq_iir/eq_iir_ipc3.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/iir_df1.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/eq_iir/eq_iir_ipc4.c
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/iir_df1.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/google/google_hotword_detect.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/notifier.h>
#include <rtos/wait.h>
#include <sof/lib/uuid.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/google/google_rtc_audio_processing.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/notifier.h>
#include <sof/lib/uuid.h>
#include <rtos/wait.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/host-legacy.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#include <rtos/init.h>
#include <sof/lib/dma.h>
#include <sof/lib/mailbox.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/notifier.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/host-zephyr.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
#include <rtos/init.h>
#include <sof/lib/dma.h>
#include <sof/lib/mailbox.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/igo_nr/igo_nr.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#include <rtos/panic.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/platform.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/kpb.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include <rtos/alloc.h>
#include <rtos/clk.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/pm_runtime.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/mfcc/mfcc.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include <sof/common.h>
#include <rtos/panic.h>
#include <sof/ipc/msg.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/platform.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/mixer/mixer.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/mixin_mixout/mixin_mixout.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/multiband_drc/multiband_drc.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
#include <sof/audio/ipc-config.h>
#include <sof/audio/pipeline.h>
#include <sof/ipc/msg.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/math/numbers.h>
#include <module/crossover/crossover_common.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/mux/mux.c
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/pipeline/pipeline-params.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
#include <sof/audio/buffer.h>
#include <sof/audio/component_ext.h>
#include <sof/audio/pipeline.h>
#include <sof/lib/memory.h>
#include <sof/lib/mm_heap.h>
#include <sof/compiler_attributes.h>
#include <sof/list.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/rtnr/rtnr.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/platform.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/selector/selector.c
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <rtos/string.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/src/src_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/src/src_ipc3.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/src/src_ipc4.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/tdfb/tdfb.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <sof/audio/module_adapter/module/generic.h>
#include <sof/audio/pipeline.h>
#include <sof/ipc/msg.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/math/fir_generic.h>
#include <sof/math/fir_hifi2ep.h>
Expand Down
2 changes: 1 addition & 1 deletion src/audio/tone.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/memory.h> /* for SHARED_DATA */
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/trig.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/up_down_mixer/up_down_mixer.c
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
#include <rtos/alloc.h>
#include <rtos/cache.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <sof/lib/notifier.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/volume/volume.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/cpu.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/volume/volume_ipc3.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/cpu.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/audio/volume/volume_ipc4.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/cpu.h>
#include <sof/lib/memory.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
#include <sof/math/numbers.h>
Expand Down
1 change: 0 additions & 1 deletion src/idc/idc.c
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include <rtos/alloc.h>
#include <rtos/clk.h>
#include <sof/lib/cpu.h>
#include <sof/lib/memory.h>
#include <sof/lib/notifier.h>
#include <sof/lib/pm_runtime.h>
#include <sof/lib/uuid.h>
Expand Down
1 change: 0 additions & 1 deletion src/include/sof/audio/module_adapter/module/generic.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@

#include <sof/audio/component.h>
#include <sof/ut.h>
#include <sof/lib/memory.h>
#include <sof/audio/sink_api.h>
#include <sof/audio/source_api.h>
#include "module_interface.h"
Expand Down
1 change: 0 additions & 1 deletion src/include/sof/audio/pipeline.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@

#include <sof/lib/cpu.h>
#include <sof/lib/mailbox.h>
#include <sof/lib/memory.h>
#include <sof/list.h>
#include <rtos/task.h>
#include <rtos/sof.h>
Expand Down
1 change: 0 additions & 1 deletion src/samples/audio/detect_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include <sof/ipc/msg.h>
#include <rtos/alloc.h>
#include <rtos/init.h>
#include <sof/lib/memory.h>
#include <rtos/wait.h>
#include <sof/lib/uuid.h>
#include <sof/list.h>
Expand Down

0 comments on commit ec8cf20

Please sign in to comment.