up_pminitialize() needs to be called from instances of up_initialize()
This commit is contained in:
parent
d3b3c71d97
commit
7b298a828d
@ -53,6 +53,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include <arch/board/board.h>
|
#include <arch/board/board.h>
|
||||||
|
|
||||||
@ -159,21 +160,21 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
/* Initialize the power management subsystem. This MCU-specific function
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
* must be called *very* early in the initialization sequence *before* any
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
* other device drivers are initialized (since they may attempt to register
|
* other device drivers are initialized (since they may attempt to register
|
||||||
* with the power management subsystem).
|
* with the power management subsystem).
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_PM
|
|
||||||
up_pminitialize();
|
up_pminitialize();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_ARCH_DMA
|
||||||
/* Initialize the DMA subsystem if the weak function up_dmainitialize has been
|
/* Initialize the DMA subsystem if the weak function up_dmainitialize has been
|
||||||
* brought into the build
|
* brought into the build
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_ARCH_DMA
|
|
||||||
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
||||||
if (up_dmainitialize)
|
if (up_dmainitialize)
|
||||||
#endif
|
#endif
|
||||||
|
@ -52,6 +52,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include <arch/board/board.h>
|
#include <arch/board/board.h>
|
||||||
|
|
||||||
@ -201,11 +202,21 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_ARCH_DMA
|
||||||
/* Initialize the DMA subsystem if the weak function stm32_dmainitialize has been
|
/* Initialize the DMA subsystem if the weak function stm32_dmainitialize has been
|
||||||
* brought into the build
|
* brought into the build
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_ARCH_DMA
|
|
||||||
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
||||||
if (up_dmainitialize)
|
if (up_dmainitialize)
|
||||||
#endif
|
#endif
|
||||||
|
@ -53,6 +53,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include "up_arch.h"
|
#include "up_arch.h"
|
||||||
#include "up_internal.h"
|
#include "up_internal.h"
|
||||||
@ -127,11 +128,21 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_ARCH_DMA
|
||||||
/* Initialize the DMA subsystem if the weak function stm32_dmainitialize has been
|
/* Initialize the DMA subsystem if the weak function stm32_dmainitialize has been
|
||||||
* brought into the build
|
* brought into the build
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_ARCH_DMA
|
|
||||||
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
||||||
if (up_dmainitialize)
|
if (up_dmainitialize)
|
||||||
#endif
|
#endif
|
||||||
|
@ -53,6 +53,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include <arch/board/board.h>
|
#include <arch/board/board.h>
|
||||||
|
|
||||||
@ -129,11 +130,21 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_ARCH_DMA
|
||||||
/* Initialize the DMA subsystem if the weak function stm32_dmainitialize has been
|
/* Initialize the DMA subsystem if the weak function stm32_dmainitialize has been
|
||||||
* brought into the build
|
* brought into the build
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_ARCH_DMA
|
|
||||||
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
||||||
if (up_dmainitialize)
|
if (up_dmainitialize)
|
||||||
#endif
|
#endif
|
||||||
|
@ -56,6 +56,7 @@
|
|||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/syslog/syslog.h>
|
#include <nuttx/syslog/syslog.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include "task/task.h"
|
#include "task/task.h"
|
||||||
#include "sched/sched.h"
|
#include "sched/sched.h"
|
||||||
@ -107,6 +108,16 @@ void up_initialize(void)
|
|||||||
|
|
||||||
nuttx_arch_init();
|
nuttx_arch_init();
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
#if CONFIG_NFILE_DESCRIPTORS > 0 && defined(CONFIG_PSEUDOTERM_SUSV1)
|
#if CONFIG_NFILE_DESCRIPTORS > 0 && defined(CONFIG_PSEUDOTERM_SUSV1)
|
||||||
/* Register the master pseudo-terminal multiplexor device */
|
/* Register the master pseudo-terminal multiplexor device */
|
||||||
|
|
||||||
|
@ -53,6 +53,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include "up_arch.h"
|
#include "up_arch.h"
|
||||||
#include "up_internal.h"
|
#include "up_internal.h"
|
||||||
@ -131,9 +132,19 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
/* Initialize the system timer interrupt */
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
#if !defined(CONFIG_SUPPRESS_INTERRUPTS) && !defined(CONFIG_SUPPRESS_TIMER_INTS)
|
#if !defined(CONFIG_SUPPRESS_INTERRUPTS) && !defined(CONFIG_SUPPRESS_TIMER_INTS)
|
||||||
|
/* Initialize the system timer interrupt */
|
||||||
|
|
||||||
up_timer_initialize();
|
up_timer_initialize();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -54,6 +54,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include "up_internal.h"
|
#include "up_internal.h"
|
||||||
|
|
||||||
@ -126,15 +127,25 @@ static void up_init_smartfs(void)
|
|||||||
|
|
||||||
void up_initialize(void)
|
void up_initialize(void)
|
||||||
{
|
{
|
||||||
|
#ifdef CONFIG_NET
|
||||||
/* The real purpose of the following is to make sure that syslog
|
/* The real purpose of the following is to make sure that syslog
|
||||||
* is drawn into the link. It is needed by up_tapdev which is linked
|
* is drawn into the link. It is needed by up_tapdev which is linked
|
||||||
* separately.
|
* separately.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_NET
|
|
||||||
syslog(LOG_INFO, "SIM: Initializing");
|
syslog(LOG_INFO, "SIM: Initializing");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
#if CONFIG_NFILE_DESCRIPTORS > 0
|
#if CONFIG_NFILE_DESCRIPTORS > 0
|
||||||
/* Register devices */
|
/* Register devices */
|
||||||
|
|
||||||
|
@ -53,6 +53,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include <arch/board/board.h>
|
#include <arch/board/board.h>
|
||||||
|
|
||||||
@ -129,11 +130,21 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef CONFIG_ARCH_DMA
|
||||||
/* Initialize the DMA subsystem if the weak function up_dmainitialize has been
|
/* Initialize the DMA subsystem if the weak function up_dmainitialize has been
|
||||||
* brought into the build
|
* brought into the build
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifdef CONFIG_ARCH_DMA
|
|
||||||
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
|
||||||
if (up_dmainitialize)
|
if (up_dmainitialize)
|
||||||
#endif
|
#endif
|
||||||
|
@ -53,6 +53,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include <arch/board/board.h>
|
#include <arch/board/board.h>
|
||||||
|
|
||||||
@ -132,9 +133,9 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_calibratedelay();
|
up_calibratedelay();
|
||||||
|
|
||||||
|
#if CONFIG_MM_REGIONS > 1
|
||||||
/* Add any extra memory fragments to the memory manager */
|
/* Add any extra memory fragments to the memory manager */
|
||||||
|
|
||||||
#if CONFIG_MM_REGIONS > 1
|
|
||||||
up_addregion();
|
up_addregion();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -142,9 +143,19 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
/* Initialize the system timer interrupt */
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
#if !defined(CONFIG_SUPPRESS_INTERRUPTS) && !defined(CONFIG_SUPPRESS_TIMER_INTS)
|
#if !defined(CONFIG_SUPPRESS_INTERRUPTS) && !defined(CONFIG_SUPPRESS_TIMER_INTS)
|
||||||
|
/* Initialize the system timer interrupt */
|
||||||
|
|
||||||
up_timer_initialize();
|
up_timer_initialize();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -52,6 +52,7 @@
|
|||||||
#include <nuttx/syslog/syslog_console.h>
|
#include <nuttx/syslog/syslog_console.h>
|
||||||
#include <nuttx/serial/pty.h>
|
#include <nuttx/serial/pty.h>
|
||||||
#include <nuttx/crypto/crypto.h>
|
#include <nuttx/crypto/crypto.h>
|
||||||
|
#include <nuttx/power/pm.h>
|
||||||
|
|
||||||
#include <arch/board/board.h>
|
#include <arch/board/board.h>
|
||||||
|
|
||||||
@ -121,9 +122,9 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_calibratedelay();
|
up_calibratedelay();
|
||||||
|
|
||||||
|
#if CONFIG_MM_REGIONS > 1
|
||||||
/* Add any extra memory fragments to the memory manager */
|
/* Add any extra memory fragments to the memory manager */
|
||||||
|
|
||||||
#if CONFIG_MM_REGIONS > 1
|
|
||||||
up_addregion();
|
up_addregion();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -131,9 +132,19 @@ void up_initialize(void)
|
|||||||
|
|
||||||
up_irqinitialize();
|
up_irqinitialize();
|
||||||
|
|
||||||
/* Initialize the system timer interrupt */
|
#ifdef CONFIG_PM
|
||||||
|
/* Initialize the power management subsystem. This MCU-specific function
|
||||||
|
* must be called *very* early in the initialization sequence *before* any
|
||||||
|
* other device drivers are initialized (since they may attempt to register
|
||||||
|
* with the power management subsystem).
|
||||||
|
*/
|
||||||
|
|
||||||
|
up_pminitialize();
|
||||||
|
#endif
|
||||||
|
|
||||||
#if !defined(CONFIG_SUPPRESS_INTERRUPTS) && !defined(CONFIG_SUPPRESS_TIMER_INTS)
|
#if !defined(CONFIG_SUPPRESS_INTERRUPTS) && !defined(CONFIG_SUPPRESS_TIMER_INTS)
|
||||||
|
/* Initialize the system timer interrupt */
|
||||||
|
|
||||||
up_timer_initialize();
|
up_timer_initialize();
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user