From bb460d076f6d777297f4b567caeee7d74d82cf8d Mon Sep 17 00:00:00 2001 From: Andrew Scheller Date: Tue, 13 Jun 2023 16:49:51 +0100 Subject: [PATCH] Add missing "default defines" (#1426) To match the documented PICO_CONFIG default values --- src/rp2_common/pico_flash/include/pico/flash.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/rp2_common/pico_flash/include/pico/flash.h b/src/rp2_common/pico_flash/include/pico/flash.h index a08b72af..320221ec 100644 --- a/src/rp2_common/pico_flash/include/pico/flash.h +++ b/src/rp2_common/pico_flash/include/pico/flash.h @@ -95,7 +95,14 @@ int flash_safe_execute(void (*func)(void *), void *param, uint32_t enter_exit_ti #endif // PICO_CONFIG: PICO_FLASH_ASSUME_CORE0_SAFE, Assume that core 0 will never be accessing flash and so doesn't need to be considered during flash_safe_execute, type=bool, default=0, group=pico_flash +#ifndef PICO_FLASH_ASSUME_CORE0_SAFE +#define PICO_FLASH_ASSUME_CORE0_SAFE 0 +#endif + // PICO_CONFIG: PICO_FLASH_ASSUME_CORE1_SAFE, Assume that core 1 will never be accessing flash and so doesn't need to be considered during flash_safe_execute, type=bool, default=0, group=pico_flash +#ifndef PICO_FLASH_ASSUME_CORE1_SAFE +#define PICO_FLASH_ASSUME_CORE1_SAFE 0 +#endif // PICO_CONFIG: PICO_FLASH_SAFE_EXECUTE_SUPPORT_FREERTOS_SMP, Support using FreeRTOS SMP to make the other core safe during flash_safe_execute, type=bool, default=1 when using FreeRTOS SMP, group=pico_flash #ifndef PICO_FLASH_SAFE_EXECUTE_SUPPORT_FREERTOS_SMP