Skip to content

Commit 7f0c98d

Browse files
committed
PSoC 6: remove debug sleep lock and hook from mbed_sdk_init
1 parent 33a7e66 commit 7f0c98d

File tree

1 file changed

+0
-31
lines changed

1 file changed

+0
-31
lines changed

targets/TARGET_Cypress/TARGET_PSOC6/mbed_overrides.c

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
#include "cyhal_hwmgr.h"
2222
#include "cybsp.h"
2323
#include "cy_mbed_post_init.h"
24-
#include "mbed_power_mgmt.h"
2524
#include "mbed_error.h"
2625
#if MBED_CONF_RTOS_PRESENT
2726
#include "rtos_idle.h"
@@ -35,22 +34,6 @@
3534
#include "cy_serial_flash_qspi.h"
3635
#endif /* defined(MBED_CONF_TARGET_XIP_ENABLE) */
3736

38-
39-
#if (defined(CY_CFG_PWR_SYS_IDLE_MODE) && (CY_CFG_PWR_SYS_IDLE_MODE == CY_CFG_PWR_MODE_ACTIVE))
40-
/*******************************************************************************
41-
* Function Name: active_idle_hook
42-
****************************************************************************//**
43-
*
44-
* Empty idle hook function to prevent the system entering sleep mode
45-
* automatically any time the system is idle.
46-
*
47-
*******************************************************************************/
48-
static void active_idle_hook(void)
49-
{
50-
/* Do nothing, so the rtos_idle_loop() performs while(1) */
51-
}
52-
#endif
53-
5437
MBED_WEAK void cy_mbed_post_bsp_init_hook(void)
5538
{
5639
/* By default, do nothing */
@@ -102,18 +85,4 @@ void mbed_sdk_init(void)
10285
/* Enable global interrupts (disabled in CM4 startup assembly) */
10386
__enable_irq();
10487
#endif
105-
106-
#if defined (CY_CFG_PWR_SYS_IDLE_MODE)
107-
/* Configure the lowest power state the system is allowed to enter
108-
* based on the System Idle Power Mode parameter value in the Device
109-
* Configurator. The default value is system deep sleep.
110-
*/
111-
#if (CY_CFG_PWR_SYS_IDLE_MODE == CY_CFG_PWR_MODE_ACTIVE)
112-
rtos_attach_idle_hook(&active_idle_hook);
113-
#elif (CY_CFG_PWR_SYS_IDLE_MODE == CY_CFG_PWR_MODE_SLEEP)
114-
sleep_manager_lock_deep_sleep();
115-
#else
116-
/* Deep sleep is default state */
117-
#endif
118-
#endif
11988
}

0 commit comments

Comments
 (0)