module_base: remove CRTP template pattern to reduce flash bloat (#26476)

* module_base: claude rewrite to remove CRTP bloat

* module_base: apply to all drivers/modules

* format

* fix build errors

* fix missing syntax

* remove reference to module.h in files that need module_base.h

* remove old ModuleBase<T>

* add module_base.cpp to px4_protected_layers.cmake

* fix IridiumSBD can_stop()

* fix IridiumSBD.cpp

* clang-tidy: downcast static cast

* get_instance() template accessor, revert clang-tidy global

* rename module_base.h to module.h

* revert changes in zenoh/Kconfig.topics
This commit is contained in:
Jacob Dahl
2026-02-19 15:17:17 +13:00
committed by GitHub
parent 657854ae1b
commit ce3e62841f
227 changed files with 1741 additions and 1496 deletions
@@ -3,6 +3,7 @@
add_library(px4_layer
${KERNEL_SRCS}
${PX4_SOURCE_DIR}/platforms/common/Serial.cpp
${PX4_SOURCE_DIR}/platforms/common/module_base.cpp
SerialImpl.cpp
)
@@ -5,6 +5,7 @@ add_library(px4_layer
board_dma_alloc.c
board_fat_dma_alloc.c
tasks.cpp
${PX4_SOURCE_DIR}/platforms/common/module_base.cpp
console_buffer_usr.cpp
${PX4_SOURCE_DIR}/platforms/posix/src/px4/common/print_load.cpp
${PX4_SOURCE_DIR}/platforms/posix/src/px4/common/cpuload.cpp
@@ -45,6 +46,7 @@ target_link_libraries(px4_layer
add_library(px4_kernel_layer
${KERNEL_SRCS}
${PX4_SOURCE_DIR}/platforms/common/module_base.cpp
SerialImpl.cpp
)