diff --git a/Devices/btt-panda-touch/Source/module.cpp b/Devices/btt-panda-touch/Source/module.cpp index 3bd6afb7..f0b27828 100644 --- a/Devices/btt-panda-touch/Source/module.cpp +++ b/Devices/btt-panda-touch/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "btt-panda-touch", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-2432s024c/Source/module.cpp b/Devices/cyd-2432s024c/Source/module.cpp index 6898097e..cd632d31 100644 --- a/Devices/cyd-2432s024c/Source/module.cpp +++ b/Devices/cyd-2432s024c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-2432s024c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-2432s028r/Source/module.cpp b/Devices/cyd-2432s028r/Source/module.cpp index 449be9cf..d5642eee 100644 --- a/Devices/cyd-2432s028r/Source/module.cpp +++ b/Devices/cyd-2432s028r/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-2432s028r", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-2432s028rv3/Source/module.cpp b/Devices/cyd-2432s028rv3/Source/module.cpp index 9723e37c..e6633689 100644 --- a/Devices/cyd-2432s028rv3/Source/module.cpp +++ b/Devices/cyd-2432s028rv3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-2432s028rv3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-2432s032c/Source/module.cpp b/Devices/cyd-2432s032c/Source/module.cpp index 87e8f63e..239c5c0f 100644 --- a/Devices/cyd-2432s032c/Source/module.cpp +++ b/Devices/cyd-2432s032c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-2432s032c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-4848s040c/Source/module.cpp b/Devices/cyd-4848s040c/Source/module.cpp index f9d28174..44b6b327 100644 --- a/Devices/cyd-4848s040c/Source/module.cpp +++ b/Devices/cyd-4848s040c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-4848s040c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-8048s043c/Source/module.cpp b/Devices/cyd-8048s043c/Source/module.cpp index 13d35d5f..58e04116 100644 --- a/Devices/cyd-8048s043c/Source/module.cpp +++ b/Devices/cyd-8048s043c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-8048s043c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-e32r28t/Source/module.cpp b/Devices/cyd-e32r28t/Source/module.cpp index fa32e809..615d412c 100644 --- a/Devices/cyd-e32r28t/Source/module.cpp +++ b/Devices/cyd-e32r28t/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-e32r28t", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/cyd-e32r32p/Source/module.cpp b/Devices/cyd-e32r32p/Source/module.cpp index 57fc73db..62e4d293 100644 --- a/Devices/cyd-e32r32p/Source/module.cpp +++ b/Devices/cyd-e32r32p/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "cyd-e32r32p", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/elecrow-crowpanel-advance-35/Source/module.cpp b/Devices/elecrow-crowpanel-advance-35/Source/module.cpp index c9a1756b..34048139 100644 --- a/Devices/elecrow-crowpanel-advance-35/Source/module.cpp +++ b/Devices/elecrow-crowpanel-advance-35/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "elecrow-crowpanel-advance-35", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/elecrow-crowpanel-advance-50/Source/module.cpp b/Devices/elecrow-crowpanel-advance-50/Source/module.cpp index b8e4f0f7..ec449848 100644 --- a/Devices/elecrow-crowpanel-advance-50/Source/module.cpp +++ b/Devices/elecrow-crowpanel-advance-50/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "elecrow-crowpanel-advance-50", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/elecrow-crowpanel-basic-28/Source/module.cpp b/Devices/elecrow-crowpanel-basic-28/Source/module.cpp index 8c284b32..eed3d132 100644 --- a/Devices/elecrow-crowpanel-basic-28/Source/module.cpp +++ b/Devices/elecrow-crowpanel-basic-28/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "elecrow-crowpanel-basic-28", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/elecrow-crowpanel-basic-35/Source/module.cpp b/Devices/elecrow-crowpanel-basic-35/Source/module.cpp index 5bf88d8f..0af55e09 100644 --- a/Devices/elecrow-crowpanel-basic-35/Source/module.cpp +++ b/Devices/elecrow-crowpanel-basic-35/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "elecrow-crowpanel-basic-35", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/elecrow-crowpanel-basic-50/Source/module.cpp b/Devices/elecrow-crowpanel-basic-50/Source/module.cpp index 8ae5c1f6..e38e0036 100644 --- a/Devices/elecrow-crowpanel-basic-50/Source/module.cpp +++ b/Devices/elecrow-crowpanel-basic-50/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "elecrow-crowpanel-basic-50", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/generic-esp32/Source/module.cpp b/Devices/generic-esp32/Source/module.cpp index e30198aa..d21e2365 100644 --- a/Devices/generic-esp32/Source/module.cpp +++ b/Devices/generic-esp32/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "generic-esp32", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/generic-esp32c6/Source/module.cpp b/Devices/generic-esp32c6/Source/module.cpp index c22545ca..231208d4 100644 --- a/Devices/generic-esp32c6/Source/module.cpp +++ b/Devices/generic-esp32c6/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "generic-esp32c6", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/generic-esp32p4/Source/module.cpp b/Devices/generic-esp32p4/Source/module.cpp index 9dbf7c20..82290049 100644 --- a/Devices/generic-esp32p4/Source/module.cpp +++ b/Devices/generic-esp32p4/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "generic-esp32p4", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/generic-esp32s3/Source/module.cpp b/Devices/generic-esp32s3/Source/module.cpp index d28a5d0e..7efaed5e 100644 --- a/Devices/generic-esp32s3/Source/module.cpp +++ b/Devices/generic-esp32s3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "generic-esp32s3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/guition-jc1060p470ciwy/Source/module.cpp b/Devices/guition-jc1060p470ciwy/Source/module.cpp index 00b4e076..71a565f2 100644 --- a/Devices/guition-jc1060p470ciwy/Source/module.cpp +++ b/Devices/guition-jc1060p470ciwy/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "guition-jc1060p470ciwy", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/guition-jc2432w328c/Source/module.cpp b/Devices/guition-jc2432w328c/Source/module.cpp index ef9ac9eb..e33a90c0 100644 --- a/Devices/guition-jc2432w328c/Source/module.cpp +++ b/Devices/guition-jc2432w328c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "guition-jc2432w328c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/guition-jc3248w535c/Source/module.cpp b/Devices/guition-jc3248w535c/Source/module.cpp index e99aad6b..f9c90650 100644 --- a/Devices/guition-jc3248w535c/Source/module.cpp +++ b/Devices/guition-jc3248w535c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "guition-jc3248w535c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/guition-jc8048w550c/Source/module.cpp b/Devices/guition-jc8048w550c/Source/module.cpp index 0549e5f9..a4406fb7 100644 --- a/Devices/guition-jc8048w550c/Source/module.cpp +++ b/Devices/guition-jc8048w550c/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "guition-jc8048w550c", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/heltec-wifi-lora-32-v3/Source/module.cpp b/Devices/heltec-wifi-lora-32-v3/Source/module.cpp index 0294e375..ecb336ab 100644 --- a/Devices/heltec-wifi-lora-32-v3/Source/module.cpp +++ b/Devices/heltec-wifi-lora-32-v3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "heltec-wifi-lora-32-v3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/lilygo-tdeck/Source/module.cpp b/Devices/lilygo-tdeck/Source/module.cpp index cf804c19..298c614e 100644 --- a/Devices/lilygo-tdeck/Source/module.cpp +++ b/Devices/lilygo-tdeck/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "lilygo-tdeck", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/lilygo-tdisplay-s3/Source/module.cpp b/Devices/lilygo-tdisplay-s3/Source/module.cpp index 91233e41..fa3624ba 100644 --- a/Devices/lilygo-tdisplay-s3/Source/module.cpp +++ b/Devices/lilygo-tdisplay-s3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "lilygo-tdisplay-s3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/lilygo-tdisplay/Source/module.cpp b/Devices/lilygo-tdisplay/Source/module.cpp index 000b0acf..e0db7dcc 100644 --- a/Devices/lilygo-tdisplay/Source/module.cpp +++ b/Devices/lilygo-tdisplay/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "lilygo-tdisplay", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/lilygo-tdongle-s3/Source/module.cpp b/Devices/lilygo-tdongle-s3/Source/module.cpp index b3387eb7..b1ef5fb3 100644 --- a/Devices/lilygo-tdongle-s3/Source/module.cpp +++ b/Devices/lilygo-tdongle-s3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "lilygo-tdongle-s3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/lilygo-tlora-pager/Source/module.cpp b/Devices/lilygo-tlora-pager/Source/module.cpp index d840cd7b..23a4de5e 100644 --- a/Devices/lilygo-tlora-pager/Source/module.cpp +++ b/Devices/lilygo-tlora-pager/Source/module.cpp @@ -25,7 +25,8 @@ struct Module device_module = { .name = "lilygo-tlora-pager", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-cardputer-adv/Source/module.cpp b/Devices/m5stack-cardputer-adv/Source/module.cpp index 656d9766..e49f44b4 100644 --- a/Devices/m5stack-cardputer-adv/Source/module.cpp +++ b/Devices/m5stack-cardputer-adv/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-cardputer-adv", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-cardputer/Source/module.cpp b/Devices/m5stack-cardputer/Source/module.cpp index 66b2f7cf..4cb38034 100644 --- a/Devices/m5stack-cardputer/Source/module.cpp +++ b/Devices/m5stack-cardputer/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-cardputer", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-core2/Source/module.cpp b/Devices/m5stack-core2/Source/module.cpp index b8166a5c..abe98186 100644 --- a/Devices/m5stack-core2/Source/module.cpp +++ b/Devices/m5stack-core2/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-core2", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-cores3/Source/module.cpp b/Devices/m5stack-cores3/Source/module.cpp index 1fdd059b..393fbf3f 100644 --- a/Devices/m5stack-cores3/Source/module.cpp +++ b/Devices/m5stack-cores3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-cores3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-papers3/Source/module.cpp b/Devices/m5stack-papers3/Source/module.cpp index 507ff816..7334626b 100644 --- a/Devices/m5stack-papers3/Source/module.cpp +++ b/Devices/m5stack-papers3/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-papers3", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-stickc-plus/Source/module.cpp b/Devices/m5stack-stickc-plus/Source/module.cpp index 8e4face5..9fab289f 100644 --- a/Devices/m5stack-stickc-plus/Source/module.cpp +++ b/Devices/m5stack-stickc-plus/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-stickc-plus", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-stickc-plus2/Source/module.cpp b/Devices/m5stack-stickc-plus2/Source/module.cpp index f8ee926d..9374ef77 100644 --- a/Devices/m5stack-stickc-plus2/Source/module.cpp +++ b/Devices/m5stack-stickc-plus2/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-stickc-plus2", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/m5stack-tab5/Source/module.cpp b/Devices/m5stack-tab5/Source/module.cpp index a0d99011..fc9e2675 100644 --- a/Devices/m5stack-tab5/Source/module.cpp +++ b/Devices/m5stack-tab5/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "m5stack-tab5", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/simulator/Source/module.cpp b/Devices/simulator/Source/module.cpp index c52deb06..8ae3a55e 100644 --- a/Devices/simulator/Source/module.cpp +++ b/Devices/simulator/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "simulator", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/unphone/Source/module.cpp b/Devices/unphone/Source/module.cpp index e1929eed..19de7394 100644 --- a/Devices/unphone/Source/module.cpp +++ b/Devices/unphone/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "unphone", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/waveshare-esp32-s3-geek/Source/module.cpp b/Devices/waveshare-esp32-s3-geek/Source/module.cpp index 682dcd3c..5eef7d46 100644 --- a/Devices/waveshare-esp32-s3-geek/Source/module.cpp +++ b/Devices/waveshare-esp32-s3-geek/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "waveshare-esp32-s3-geek", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/waveshare-s3-lcd-13/Source/module.cpp b/Devices/waveshare-s3-lcd-13/Source/module.cpp index 2071dc4b..ca7a21c6 100644 --- a/Devices/waveshare-s3-lcd-13/Source/module.cpp +++ b/Devices/waveshare-s3-lcd-13/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "waveshare-s3-lcd-13", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/waveshare-s3-touch-lcd-128/Source/module.cpp b/Devices/waveshare-s3-touch-lcd-128/Source/module.cpp index 90dc8667..a5b15030 100644 --- a/Devices/waveshare-s3-touch-lcd-128/Source/module.cpp +++ b/Devices/waveshare-s3-touch-lcd-128/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "waveshare-s3-touch-lcd-128", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/waveshare-s3-touch-lcd-147/Source/module.cpp b/Devices/waveshare-s3-touch-lcd-147/Source/module.cpp index 86dba168..b53792e3 100644 --- a/Devices/waveshare-s3-touch-lcd-147/Source/module.cpp +++ b/Devices/waveshare-s3-touch-lcd-147/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "waveshare-s3-touch-lcd-147", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/waveshare-s3-touch-lcd-43/Source/module.cpp b/Devices/waveshare-s3-touch-lcd-43/Source/module.cpp index a6c203ba..2019004c 100644 --- a/Devices/waveshare-s3-touch-lcd-43/Source/module.cpp +++ b/Devices/waveshare-s3-touch-lcd-43/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "waveshare-s3-touch-lcd-43", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Devices/wireless-tag-wt32-sc01-plus/Source/module.cpp b/Devices/wireless-tag-wt32-sc01-plus/Source/module.cpp index 85e806fc..ff0aa0ab 100644 --- a/Devices/wireless-tag-wt32-sc01-plus/Source/module.cpp +++ b/Devices/wireless-tag-wt32-sc01-plus/Source/module.cpp @@ -17,7 +17,8 @@ struct Module device_module = { .name = "wireless-tag-wt32-sc01-plus", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Modules/hal-device-module/Source/module.cpp b/Modules/hal-device-module/Source/module.cpp index 49d65107..bf36c6b7 100644 --- a/Modules/hal-device-module/Source/module.cpp +++ b/Modules/hal-device-module/Source/module.cpp @@ -25,7 +25,8 @@ struct Module hal_device_module = { .name = "hal-device", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Modules/lvgl-module/Source/module.c b/Modules/lvgl-module/Source/module.c index 6a4b0afd..b8bcd9c7 100644 --- a/Modules/lvgl-module/Source/module.c +++ b/Modules/lvgl-module/Source/module.c @@ -64,5 +64,6 @@ struct Module lvgl_module = { .name = "lvgl", .start = start, .stop = stop, - .symbols = (const struct ModuleSymbol*)lvgl_module_symbols + .symbols = (const struct ModuleSymbol*)lvgl_module_symbols, + .internal = NULL }; diff --git a/Platforms/PlatformEsp32/Source/module.cpp b/Platforms/PlatformEsp32/Source/module.cpp index 0170152d..0671803f 100644 --- a/Platforms/PlatformEsp32/Source/module.cpp +++ b/Platforms/PlatformEsp32/Source/module.cpp @@ -31,7 +31,8 @@ struct Module platform_module = { .name = "platform-esp32", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/Platforms/PlatformPosix/Source/module.cpp b/Platforms/PlatformPosix/Source/module.cpp index c696aa51..0dec030c 100644 --- a/Platforms/PlatformPosix/Source/module.cpp +++ b/Platforms/PlatformPosix/Source/module.cpp @@ -18,7 +18,8 @@ struct Module platform_module = { .name = "platform-posix", .start = start, .stop = stop, - .symbols = nullptr + .symbols = nullptr, + .internal = nullptr }; } diff --git a/TactilityKernel/Include/tactility/module.h b/TactilityKernel/Include/tactility/module.h index 5e44dfe4..539baa19 100644 --- a/TactilityKernel/Include/tactility/module.h +++ b/TactilityKernel/Include/tactility/module.h @@ -59,9 +59,7 @@ struct Module { */ const struct ModuleSymbol* symbols; - struct { - bool started; - } internal; + void* internal; }; /** diff --git a/TactilityKernel/Source/kernel_init.cpp b/TactilityKernel/Source/kernel_init.cpp index ee492ed3..58aca07e 100644 --- a/TactilityKernel/Source/kernel_init.cpp +++ b/TactilityKernel/Source/kernel_init.cpp @@ -23,7 +23,8 @@ struct Module root_module = { .name = "kernel", .start = start, .stop = stop, - .symbols = (const struct ModuleSymbol*)KERNEL_SYMBOLS + .symbols = (const struct ModuleSymbol*)KERNEL_SYMBOLS, + .internal = nullptr }; error_t kernel_init(struct Module* platform_module, struct Module* device_module, struct CompatibleDevice devicetree_devices[]) { diff --git a/TactilityKernel/Source/module.cpp b/TactilityKernel/Source/module.cpp index ff1def98..6ae1e312 100644 --- a/TactilityKernel/Source/module.cpp +++ b/TactilityKernel/Source/module.cpp @@ -3,9 +3,14 @@ #include #include #include +#include #define TAG "module" +struct ModuleInternal { + bool started; +}; + struct ModuleLedger { std::vector modules; struct Mutex mutex = { 0 }; @@ -19,11 +24,14 @@ static ModuleLedger ledger; extern "C" { error_t module_construct(struct Module* module) { - module->internal.started = false; + module->internal = new (std::nothrow) ModuleInternal { .started = false }; + if (module->internal == nullptr) return ERROR_OUT_OF_MEMORY; return ERROR_NONE; } error_t module_destruct(struct Module* module) { + delete static_cast(module->internal); + module->internal = nullptr; return ERROR_NONE; } @@ -44,28 +52,30 @@ error_t module_remove(struct Module* module) { error_t module_start(struct Module* module) { LOG_I(TAG, "start %s", module->name); - if (module->internal.started) return ERROR_NONE; + auto* internal = static_cast(module->internal); + if (internal->started) return ERROR_NONE; error_t error = module->start(); - module->internal.started = (error == ERROR_NONE); + internal->started = (error == ERROR_NONE); return error; } bool module_is_started(struct Module* module) { - return module->internal.started; + return static_cast(module->internal)->started; } error_t module_stop(struct Module* module) { LOG_I(TAG, "stop %s", module->name); - if (!module->internal.started) return ERROR_NONE; + auto* internal = static_cast(module->internal); + if (!internal->started) return ERROR_NONE; error_t error = module->stop(); if (error != ERROR_NONE) { return error; } - module->internal.started = false; + internal->started = false; return error; } diff --git a/Tests/TactilityKernel/ModuleTest.cpp b/Tests/TactilityKernel/ModuleTest.cpp index d4f00f8e..e5ec5a50 100644 --- a/Tests/TactilityKernel/ModuleTest.cpp +++ b/Tests/TactilityKernel/ModuleTest.cpp @@ -23,7 +23,7 @@ TEST_CASE("Module construction and destruction") { .start = test_start, .stop = test_stop, .symbols = nullptr, - .internal = {.started = false} + .internal = nullptr }; // Test successful construction @@ -40,7 +40,7 @@ TEST_CASE("Module registration") { .start = test_start, .stop = test_stop, .symbols = nullptr, - .internal = {.started = false} + .internal = nullptr }; // module_add should succeed @@ -61,7 +61,7 @@ TEST_CASE("Module lifecycle") { .start = test_start, .stop = test_stop, .symbols = nullptr, - .internal = {.started = false} + .internal = nullptr }; // 1. Successful start (no parent required anymore) @@ -117,7 +117,7 @@ TEST_CASE("Global symbol resolution") { .start = test_start, .stop = test_stop, .symbols = test_symbols, - .internal = {.started = false} + .internal = nullptr }; uintptr_t addr;