Merged nuttx/boards into master
This commit is contained in:
commit
86c604f7cf
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/cloudctrl/src/stm32_autoleds.c
|
||||
*
|
||||
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Darcy Gong <darcy.gong@gmail.com>
|
||||
*
|
||||
@ -145,8 +145,10 @@ static void led_setonoff(unsigned int bits);
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -284,7 +286,8 @@ static void led_setonoff(unsigned int bits)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -339,7 +342,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/efm32-g8xx-stk/src/efm32_userleds.c
|
||||
*
|
||||
* Copyright (C) 2014-2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2014-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -88,8 +88,10 @@ static gpio_pinset_t g_ledcfg[BOARD_NLEDS] =
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -118,7 +120,8 @@ static struct pm_callback_s g_ledscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -173,7 +176,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/fire-stm32v2/src/stm32_autoleds.c
|
||||
*
|
||||
* Copyright (C) 2012-2013, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012-2013, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -149,8 +149,10 @@ static void led_setonoff(unsigned int bits);
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -265,7 +267,8 @@ static void led_setonoff(unsigned int bits)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -320,7 +323,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/mikroe_stm32f4/src/stm32_idle.c
|
||||
*
|
||||
* Copyright (C) 2012-2013 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012-2013, 2016 Gregory Nutt. All rights reserved.
|
||||
* Authors: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Diego Sanchez <dsanchez@nx-engineering.com>
|
||||
*
|
||||
@ -84,6 +84,8 @@
|
||||
# define CONFIG_PM_ALARM_NSEC 0
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
@ -117,7 +119,7 @@ static void up_idlepm(void)
|
||||
|
||||
/* Decide, which power saving level can be obtained */
|
||||
|
||||
newstate = pm_checkstate();
|
||||
newstate = pm_checkstate(PM_IDLE_DOMAIN);
|
||||
|
||||
/* Check for state changes */
|
||||
|
||||
@ -129,12 +131,12 @@ static void up_idlepm(void)
|
||||
|
||||
/* Force the global state change */
|
||||
|
||||
ret = pm_changestate(newstate);
|
||||
ret = pm_changestate(PM_IDLE_DOMAIN, newstate);
|
||||
if (ret < 0)
|
||||
{
|
||||
/* The new state change failed, revert to the preceding state */
|
||||
|
||||
(void)pm_changestate(oldstate);
|
||||
(void)pm_changestate(PM_IDLE_DOMAIN, oldstate);
|
||||
|
||||
/* No state change... */
|
||||
|
||||
@ -190,7 +192,7 @@ static void up_idlepm(void)
|
||||
#endif
|
||||
/* Resume normal operation */
|
||||
|
||||
pm_changestate(PM_NORMAL);
|
||||
pm_changestate(PM_IDLE_DOMAIN, PM_NORMAL);
|
||||
newstate = PM_NORMAL;
|
||||
}
|
||||
break;
|
||||
@ -236,7 +238,7 @@ static void up_alarmcb(void)
|
||||
* PM_STANDBY period. So just go to sleep.
|
||||
*/
|
||||
|
||||
pm_changestate(PM_SLEEP);
|
||||
pm_changestate(PM_IDLE_DOMAIN, PM_SLEEP);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/nucleo-f4x1re/src/stm32_userleds.c
|
||||
*
|
||||
* Copyright (C) 2014-2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2014-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -81,8 +81,10 @@
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -111,7 +113,8 @@ static struct pm_callback_s g_ledscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -166,7 +169,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/nucleo-l476rg/src/stm32_userleds.c
|
||||
*
|
||||
* Copyright (C) 2014-2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2014-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -81,8 +81,10 @@
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -111,7 +113,8 @@ static struct pm_callback_s g_ledscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -166,7 +169,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/shenzhou/src/stm32_autoleds.c
|
||||
*
|
||||
* Copyright (C) 2012-2013, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012-2013, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -144,8 +144,10 @@ static void led_setonoff(unsigned int bits);
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -281,7 +283,8 @@ static void led_setonoff(unsigned int bits)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -336,7 +339,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
############################################################################
|
||||
# configs/spark/src/Makefile
|
||||
#
|
||||
# Copyright (C) 2013 Gregory Nutt. All rights reserved.
|
||||
# Copyright (C) 2013, 2016 Gregory Nutt. All rights reserved.
|
||||
# Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
# Librae <librae8226@gmail.com>
|
||||
#
|
||||
@ -57,6 +57,10 @@ ifeq ($(CONFIG_USBDEV),y)
|
||||
CSRCS += stm32_usbdev.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_BOARDCTL_USBDEVCTRL),y)
|
||||
CSRCS += stm32_usbmsc.c
|
||||
endif
|
||||
|
||||
ifeq ($(CONFIG_USBDEV_COMPOSITE),y)
|
||||
CSRCS += stm32_composite.c
|
||||
endif
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* config/spark/src/stm32_appinit.c
|
||||
*
|
||||
* Copyright (C) 2012-2013 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012-2013, 2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
* David_s5 <david_s5@nscdg.com>
|
||||
*
|
||||
@ -299,19 +299,3 @@ int board_app_initialize(void)
|
||||
g_app_initialzed = true;
|
||||
return OK;
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
* Name: board_usbmsc_initialize
|
||||
*
|
||||
* Description:
|
||||
* Perform architecture specific initialization as needed to establish
|
||||
* the mass storage device that will be exported by the USB MSC device.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_BOARDCTL_USBDEVCTRL
|
||||
int board_usbmsc_initialize(int port)
|
||||
{
|
||||
return board_app_initialize();
|
||||
}
|
||||
#endif
|
69
configs/spark/src/stm32_usbmsc.c
Normal file
69
configs/spark/src/stm32_usbmsc.c
Normal file
@ -0,0 +1,69 @@
|
||||
/****************************************************************************
|
||||
* configs/spark/src/stm32_usbmsc.c
|
||||
*
|
||||
* Copyright (C) 2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions
|
||||
* are met:
|
||||
*
|
||||
* 1. Redistributions of source code must retain the above copyright
|
||||
* notice, this list of conditions and the following disclaimer.
|
||||
* 2. Redistributions in binary form must reproduce the above copyright
|
||||
* notice, this list of conditions and the following disclaimer in
|
||||
* the documentation and/or other materials provided with the
|
||||
* distribution.
|
||||
* 3. Neither the name NuttX nor the names of its contributors may be
|
||||
* used to endorse or promote products derived from this software
|
||||
* without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
|
||||
* FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
|
||||
* COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
|
||||
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
|
||||
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
|
||||
* OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
|
||||
* AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
|
||||
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
|
||||
* ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
||||
* POSSIBILITY OF SUCH DAMAGE.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Included Files
|
||||
****************************************************************************/
|
||||
|
||||
#include <nuttx/config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
#include "nuttx/board.h"
|
||||
|
||||
#include "spark.h"
|
||||
|
||||
#if defined(CONFIG_USBMSC) && !defined(CONFIG_USBMSC_COMPOSITE) && \
|
||||
defined(CONFIG_BOARDCTL_USBDEVCTRL)
|
||||
|
||||
/****************************************************************************
|
||||
* Public Functions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Name: board_usbmsc_initialize
|
||||
*
|
||||
* Description:
|
||||
* Perform architecture specific initialization as needed to establish
|
||||
* the mass storage device that will be exported by the USB MSC device.
|
||||
*
|
||||
****************************************************************************/
|
||||
|
||||
int board_usbmsc_initialize(int port)
|
||||
{
|
||||
return board_app_initialize();
|
||||
}
|
||||
|
||||
#endif /* CONFIG_USBMSC && !CONFIG_USBMSC_COMPOSITE && CONFIG_BOARDCTL_USBDEVCTRL */
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -847,6 +850,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
|
||||
#
|
||||
@ -931,7 +936,6 @@ CONFIG_EXAMPLES_BUTTONS_NAME7="UP"
|
||||
# CONFIG_EXAMPLES_TIFF is not set
|
||||
# CONFIG_EXAMPLES_TOUCHSCREEN is not set
|
||||
# CONFIG_EXAMPLES_WEBSERVER is not set
|
||||
# CONFIG_EXAMPLES_USBSERIAL is not set
|
||||
# CONFIG_EXAMPLES_USBTERM is not set
|
||||
# CONFIG_EXAMPLES_WATCHDOG is not set
|
||||
|
||||
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -536,7 +539,14 @@ CONFIG_ARCH_HAVE_IRQBUTTONS=y
|
||||
#
|
||||
# CONFIG_STM3210E_LCD is not set
|
||||
CONFIG_LIB_BOARDCTL=y
|
||||
# CONFIG_BOARDCTL_RESET is not set
|
||||
# CONFIG_BOARDCTL_UNIQUEID is not set
|
||||
CONFIG_BOARDCTL_USBDEVCTRL=y
|
||||
# CONFIG_BOARDCTL_TSCTEST is not set
|
||||
# CONFIG_BOARDCTL_ADCTEST is not set
|
||||
# CONFIG_BOARDCTL_PWMTEST is not set
|
||||
# CONFIG_BOARDCTL_GRAPHICS is not set
|
||||
# CONFIG_BOARDCTL_IOCTL is not set
|
||||
|
||||
#
|
||||
# RTOS Features
|
||||
@ -847,8 +857,8 @@ CONFIG_CDCACM_EPBULKOUT_HSSIZE=512
|
||||
CONFIG_CDCACM_EPBULKIN=2
|
||||
CONFIG_CDCACM_EPBULKIN_FSSIZE=64
|
||||
CONFIG_CDCACM_EPBULKIN_HSSIZE=512
|
||||
CONFIG_CDCACM_NWRREQS=4
|
||||
CONFIG_CDCACM_NRDREQS=4
|
||||
CONFIG_CDCACM_NWRREQS=4
|
||||
CONFIG_CDCACM_BULKIN_REQLEN=96
|
||||
CONFIG_CDCACM_RXBUFSIZE=256
|
||||
CONFIG_CDCACM_TXBUFSIZE=256
|
||||
@ -996,6 +1006,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
# CONFIG_NETDB_HOSTFILE is not set
|
||||
|
||||
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -541,6 +544,7 @@ CONFIG_NSH_MMCSDSLOTNO=0
|
||||
CONFIG_LIB_BOARDCTL=y
|
||||
# CONFIG_BOARDCTL_RESET is not set
|
||||
# CONFIG_BOARDCTL_UNIQUEID is not set
|
||||
# CONFIG_BOARDCTL_USBDEVCTRL is not set
|
||||
# CONFIG_BOARDCTL_TSCTEST is not set
|
||||
# CONFIG_BOARDCTL_ADCTEST is not set
|
||||
# CONFIG_BOARDCTL_PWMTEST is not set
|
||||
@ -960,6 +964,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
# CONFIG_NETDB_HOSTFILE is not set
|
||||
|
||||
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -1123,6 +1126,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
# CONFIG_NETDB_HOSTFILE is not set
|
||||
|
||||
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -1026,6 +1029,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
|
||||
#
|
||||
@ -1111,7 +1116,6 @@ CONFIG_EXAMPLES_NX_TOOLBAR_HEIGHT=16
|
||||
# CONFIG_EXAMPLES_TIFF is not set
|
||||
# CONFIG_EXAMPLES_TOUCHSCREEN is not set
|
||||
# CONFIG_EXAMPLES_WEBSERVER is not set
|
||||
# CONFIG_EXAMPLES_USBSERIAL is not set
|
||||
# CONFIG_EXAMPLES_USBTERM is not set
|
||||
# CONFIG_EXAMPLES_WATCHDOG is not set
|
||||
|
||||
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -1034,6 +1037,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
|
||||
#
|
||||
|
@ -80,6 +80,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -98,6 +99,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -125,6 +127,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -757,6 +760,24 @@ CONFIG_LCD_RPORTRAIT=y
|
||||
# CONFIG_EEPROM is not set
|
||||
# CONFIG_PIPES is not set
|
||||
CONFIG_PM=y
|
||||
CONFIG_PM_SLICEMS=100
|
||||
CONFIG_PM_NDOMAINS=1
|
||||
CONFIG_PM_MEMORY=2
|
||||
CONFIG_PM_COEFN=1
|
||||
CONFIG_PM_COEF1=1
|
||||
CONFIG_PM_COEF2=1
|
||||
CONFIG_PM_COEF3=1
|
||||
CONFIG_PM_COEF4=1
|
||||
CONFIG_PM_COEF5=1
|
||||
CONFIG_PM_IDLEENTER_THRESH=1
|
||||
CONFIG_PM_IDLEEXIT_THRESH=2
|
||||
CONFIG_PM_IDLEENTER_COUNT=30
|
||||
CONFIG_PM_STANDBYENTER_THRESH=1
|
||||
CONFIG_PM_STANDBYEXIT_THRESH=2
|
||||
CONFIG_PM_STANDBYENTER_COUNT=50
|
||||
CONFIG_PM_SLEEPENTER_THRESH=1
|
||||
CONFIG_PM_SLEEPEXIT_THRESH=2
|
||||
CONFIG_PM_SLEEPENTER_COUNT=70
|
||||
# CONFIG_POWER is not set
|
||||
# CONFIG_SENSORS is not set
|
||||
# CONFIG_SERCOMM_CONSOLE is not set
|
||||
@ -1036,6 +1057,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
|
||||
#
|
||||
|
@ -49,10 +49,6 @@
|
||||
|
||||
#ifdef CONFIG_ARCH_BUTTONS
|
||||
|
||||
/****************************************************************************
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm3210e-eval/src/stm32_idle.c
|
||||
*
|
||||
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Authors: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Diego Sanchez <dsanchez@nx-engineering.com>
|
||||
*
|
||||
@ -119,6 +119,8 @@
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
@ -281,7 +283,7 @@ static void stm32_idlepm(void)
|
||||
{
|
||||
/* Let the PM system decide, which power saving level can be obtained */
|
||||
|
||||
newstate = pm_checkstate();
|
||||
newstate = pm_checkstate(PM_IDLE_DOMAIN);
|
||||
}
|
||||
|
||||
/* Check for state changes */
|
||||
@ -294,12 +296,12 @@ static void stm32_idlepm(void)
|
||||
|
||||
/* Force the global state change */
|
||||
|
||||
ret = pm_changestate(newstate);
|
||||
ret = pm_changestate(PM_IDLE_DOMAIN, newstate);
|
||||
if (ret < 0)
|
||||
{
|
||||
/* The new state change failed, revert to the preceding state */
|
||||
|
||||
(void)pm_changestate(oldstate);
|
||||
(void)pm_changestate(PM_IDLE_DOMAIN, oldstate);
|
||||
|
||||
/* No state change... */
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/**************************************************************************************
|
||||
* configs/stm3210e-eval/src/stm32_lcd.c
|
||||
*
|
||||
* Copyright (C) 2011-2012 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2011-2012, 2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* With power management enhancements by:
|
||||
@ -410,8 +410,10 @@ static int stm3210e_setcontrast(struct lcd_dev_s *dev, unsigned int contrast);
|
||||
/* LCD Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void stm3210e_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int stm3210e_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void stm3210e_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int stm3210e_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/* Initialization */
|
||||
@ -1153,7 +1155,8 @@ static int stm3210e_setcontrast(struct lcd_dev_s *dev, unsigned int contrast)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void stm3210e_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void stm3210e_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
#ifdef CONFIG_STM3210E_LCD_PWM
|
||||
uint32_t frac;
|
||||
@ -1290,7 +1293,8 @@ static void stm3210e_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstat
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int stm3210e_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int stm3210e_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LCD driver. We always
|
||||
* accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm3210e_eval/src/stm32_leds.c
|
||||
*
|
||||
* Copyright (C) 2009-2013, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2009-2013, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -144,8 +144,10 @@ static void led_setonoff(unsigned int bits);
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -277,7 +279,8 @@ static void led_setonoff(unsigned int bits)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -332,7 +335,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm3210e-eval/src/stm32_pmbuttons.c
|
||||
*
|
||||
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Authors: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Diego Sanchez <dsanchez@nx-engineering.com>
|
||||
*
|
||||
@ -111,6 +111,8 @@
|
||||
# define CONFIG_PM_BUTTON_ACTIVITY 10
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/* Miscellaneous Definitions ************************************************/
|
||||
|
||||
#ifndef MIN
|
||||
@ -221,7 +223,7 @@ static void button_handler(int id, int irq)
|
||||
* special happened.
|
||||
*/
|
||||
|
||||
pm_activity(CONFIG_PM_BUTTON_ACTIVITY);
|
||||
pm_activity(PM_IDLE_DOMAIN, CONFIG_PM_BUTTON_ACTIVITY);
|
||||
}
|
||||
|
||||
#if MIN_BUTTON < 1
|
||||
|
@ -76,6 +76,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_DM320 is not set
|
||||
# CONFIG_ARCH_CHIP_EFM32 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX1 is not set
|
||||
# CONFIG_ARCH_CHIP_IMX6 is not set
|
||||
# CONFIG_ARCH_CHIP_KINETIS is not set
|
||||
# CONFIG_ARCH_CHIP_KL is not set
|
||||
# CONFIG_ARCH_CHIP_LM is not set
|
||||
@ -94,6 +95,7 @@ CONFIG_ARCH="arm"
|
||||
# CONFIG_ARCH_CHIP_SAMV7 is not set
|
||||
CONFIG_ARCH_CHIP_STM32=y
|
||||
# CONFIG_ARCH_CHIP_STM32F7 is not set
|
||||
# CONFIG_ARCH_CHIP_STM32L4 is not set
|
||||
# CONFIG_ARCH_CHIP_STR71X is not set
|
||||
# CONFIG_ARCH_CHIP_TMS570 is not set
|
||||
# CONFIG_ARCH_CHIP_MOXART is not set
|
||||
@ -121,6 +123,7 @@ CONFIG_ARCH_HAVE_CMNVECTOR=y
|
||||
# CONFIG_ARMV7M_LAZYFPU is not set
|
||||
# CONFIG_ARCH_HAVE_FPU is not set
|
||||
# CONFIG_ARCH_HAVE_DPFPU is not set
|
||||
# CONFIG_ARCH_HAVE_TRUSTZONE is not set
|
||||
CONFIG_ARM_HAVE_MPU_UNIFIED=y
|
||||
# CONFIG_ARM_MPU is not set
|
||||
|
||||
@ -529,7 +532,14 @@ CONFIG_ARCH_HAVE_IRQBUTTONS=y
|
||||
#
|
||||
# CONFIG_STM3210E_LCD is not set
|
||||
CONFIG_LIB_BOARDCTL=y
|
||||
# CONFIG_BOARDCTL_RESET is not set
|
||||
# CONFIG_BOARDCTL_UNIQUEID is not set
|
||||
CONFIG_BOARDCTL_USBDEVCTRL=y
|
||||
# CONFIG_BOARDCTL_TSCTEST is not set
|
||||
# CONFIG_BOARDCTL_ADCTEST is not set
|
||||
# CONFIG_BOARDCTL_PWMTEST is not set
|
||||
# CONFIG_BOARDCTL_GRAPHICS is not set
|
||||
# CONFIG_BOARDCTL_IOCTL is not set
|
||||
|
||||
#
|
||||
# RTOS Features
|
||||
@ -926,6 +936,8 @@ CONFIG_ARCH_LOWPUTC=y
|
||||
CONFIG_LIB_SENDFILE_BUFSIZE=512
|
||||
# CONFIG_ARCH_ROMGETC is not set
|
||||
# CONFIG_ARCH_OPTIMIZED_FUNCTIONS is not set
|
||||
CONFIG_ARCH_HAVE_TLS=y
|
||||
# CONFIG_TLS is not set
|
||||
# CONFIG_LIBC_NETDB is not set
|
||||
# CONFIG_NETDB_HOSTFILE is not set
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm32f429i-disco/src/stm32_idle.c
|
||||
*
|
||||
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Authors: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Diego Sanchez <dsanchez@nx-engineering.com>
|
||||
*
|
||||
@ -84,6 +84,8 @@
|
||||
# define CONFIG_PM_ALARM_NSEC 0
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
@ -117,7 +119,7 @@ static void stm32_idlepm(void)
|
||||
|
||||
/* Decide, which power saving level can be obtained */
|
||||
|
||||
newstate = pm_checkstate();
|
||||
newstate = pm_checkstate(PM_IDLE_DOMAIN);
|
||||
|
||||
/* Check for state changes */
|
||||
|
||||
@ -129,12 +131,12 @@ static void stm32_idlepm(void)
|
||||
|
||||
/* Force the global state change */
|
||||
|
||||
ret = pm_changestate(newstate);
|
||||
ret = pm_changestate(PM_IDLE_DOMAIN, newstate);
|
||||
if (ret < 0)
|
||||
{
|
||||
/* The new state change failed, revert to the preceding state */
|
||||
|
||||
(void)pm_changestate(oldstate);
|
||||
(void)pm_changestate(PM_IDLE_DOMAIN, oldstate);
|
||||
|
||||
/* No state change... */
|
||||
|
||||
@ -190,7 +192,7 @@ static void stm32_idlepm(void)
|
||||
#endif
|
||||
/* Resume normal operation */
|
||||
|
||||
pm_changestate(PM_NORMAL);
|
||||
pm_changestate(PM_IDLE_DOMAIN, PM_NORMAL);
|
||||
newstate = PM_NORMAL;
|
||||
}
|
||||
break;
|
||||
@ -236,7 +238,7 @@ static void stm32_alarmcb(void)
|
||||
* PM_STANDBY period. So just go to sleep.
|
||||
*/
|
||||
|
||||
pm_changestate(PM_SLEEP);
|
||||
pm_changestate(PM_IDLE_DOMAIN, PM_SLEEP);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm32f429i-disco/src/stm32_userleds.c
|
||||
*
|
||||
* Copyright (C) 2011, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2011, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -87,8 +87,10 @@ static uint32_t g_ledcfg[BOARD_NLEDS] =
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
|
||||
@ -118,7 +120,8 @@ static struct pm_callback_s g_ledscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -173,7 +176,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm32f4discovery/src/stm32_idle.c
|
||||
*
|
||||
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Authors: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Diego Sanchez <dsanchez@nx-engineering.com>
|
||||
*
|
||||
@ -84,6 +84,8 @@
|
||||
# define CONFIG_PM_ALARM_NSEC 0
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/****************************************************************************
|
||||
* Private Data
|
||||
****************************************************************************/
|
||||
@ -114,7 +116,7 @@ static void stm32_idlepm(void)
|
||||
|
||||
/* Decide, which power saving level can be obtained */
|
||||
|
||||
newstate = pm_checkstate();
|
||||
newstate = pm_checkstate(PM_IDLE_DOMAIN);
|
||||
|
||||
/* Check for state changes */
|
||||
|
||||
@ -126,12 +128,12 @@ static void stm32_idlepm(void)
|
||||
|
||||
/* Force the global state change */
|
||||
|
||||
ret = pm_changestate(newstate);
|
||||
ret = pm_changestate(PM_IDLE_DOMAIN, newstate);
|
||||
if (ret < 0)
|
||||
{
|
||||
/* The new state change failed, revert to the preceding state */
|
||||
|
||||
(void)pm_changestate(oldstate);
|
||||
(void)pm_changestate(PM_IDLE_DOMAIN, oldstate);
|
||||
|
||||
/* No state change... */
|
||||
|
||||
@ -187,7 +189,7 @@ static void stm32_idlepm(void)
|
||||
#endif
|
||||
/* Resume normal operation */
|
||||
|
||||
pm_changestate(PM_NORMAL);
|
||||
pm_changestate(PM_IDLE_DOMAIN, PM_NORMAL);
|
||||
newstate = PM_NORMAL;
|
||||
}
|
||||
break;
|
||||
@ -233,7 +235,7 @@ static void up_alarmcb(void)
|
||||
* PM_STANDBY period. So just go to sleep.
|
||||
*/
|
||||
|
||||
pm_changestate(PM_SLEEP);
|
||||
pm_changestate(PM_IDLE_DOMAIN, PM_SLEEP);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm32f4discovery/src/stm32_pm_buttons.c
|
||||
*
|
||||
* Copyright (C) 2012, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2012, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Authors: Gregory Nutt <gnutt@nuttx.org>
|
||||
* Diego Sanchez <dsanchez@nx-engineering.com>
|
||||
*
|
||||
@ -73,6 +73,8 @@
|
||||
# define CONFIG_PM_BUTTON_ACTIVITY 10
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/****************************************************************************
|
||||
* Private Types
|
||||
****************************************************************************/
|
||||
@ -111,7 +113,7 @@ static int button_handler(int irq, FAR void *context)
|
||||
* special happened.
|
||||
*/
|
||||
|
||||
pm_activity(CONFIG_PM_BUTTON_ACTIVITY);
|
||||
pm_activity(PM_IDLE_DOMAIN, CONFIG_PM_BUTTON_ACTIVITY);
|
||||
return OK;
|
||||
}
|
||||
#endif /* CONFIG_ARCH_IRQBUTTONS */
|
||||
|
@ -1,7 +1,7 @@
|
||||
/****************************************************************************
|
||||
* configs/stm32f4discovery/src/stm32_userleds.c
|
||||
*
|
||||
* Copyright (C) 2011, 2015 Gregory Nutt. All rights reserved.
|
||||
* Copyright (C) 2011, 2015-2016 Gregory Nutt. All rights reserved.
|
||||
* Author: Gregory Nutt <gnutt@nuttx.org>
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
@ -88,8 +88,10 @@ static uint32_t g_ledcfg[BOARD_NLEDS] =
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
|
||||
@ -119,7 +121,8 @@ static struct pm_callback_s g_ledscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -174,7 +177,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
@ -131,12 +131,12 @@
|
||||
|
||||
/* CLK48 will come from PLLSAI1 (implicitly Q) */
|
||||
|
||||
#define STM32L4_USE_CLK48
|
||||
#define STM32L4_USE_CLK48 1
|
||||
#define STM32L4_CLK48_SEL RCC_CCIPR_CLK48SEL_PLLSAI1
|
||||
|
||||
/* enable the LSE oscillator, used automatically trim the MSI, and for RTC */
|
||||
|
||||
#define STM32L4_USE_LSE
|
||||
#define STM32L4_USE_LSE 1
|
||||
|
||||
/* AHB clock (HCLK) is SYSCLK (80MHz) */
|
||||
|
||||
|
@ -54,10 +54,12 @@
|
||||
* Pre-processor Definitions
|
||||
****************************************************************************/
|
||||
|
||||
#ifndef CONFIG_PM_BUTTON_ACTIVITY
|
||||
#ifndef CONFIG_PM_BUTTON_ACTIVITY
|
||||
# define CONFIG_PM_BUTTON_ACTIVITY 10
|
||||
#endif
|
||||
|
||||
#define PM_IDLE_DOMAIN 0 /* Revisit */
|
||||
|
||||
/****************************************************************************
|
||||
* Private Function Prototypes
|
||||
****************************************************************************/
|
||||
@ -65,8 +67,10 @@
|
||||
/* Button Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void button_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int button_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void button_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int button_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -111,7 +115,8 @@ static struct pm_callback_s g_buttonscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void button_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void button_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -173,6 +178,7 @@ static void button_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
#ifdef CONFIG_ARCH_IRQBUTTONS
|
||||
static int button_handler(int irq, FAR void *context)
|
||||
{
|
||||
#ifdef CONFIG_PM
|
||||
/* At this point the MCU should have already awakened. The state
|
||||
* change will be handled in the IDLE loop when the system is re-awakened
|
||||
* The button interrupt handler should be totally ignorant of the PM
|
||||
@ -180,8 +186,7 @@ static int button_handler(int irq, FAR void *context)
|
||||
* special happened.
|
||||
*/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
pm_activity(CONFIG_PM_BUTTON_ACTIVITY);
|
||||
pm_activity(PM_IDLE_DOMAIN, CONFIG_PM_BUTTON_ACTIVITY);
|
||||
#endif
|
||||
return OK;
|
||||
}
|
||||
@ -201,7 +206,8 @@ static int button_handler(int irq, FAR void *context)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int button_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int button_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the Buttons driver.
|
||||
* We always accept the state change by returning OK.
|
||||
@ -281,14 +287,14 @@ uint8_t board_buttons(void)
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
/* if the user pressed any buttons, notify power management system we are
|
||||
* active
|
||||
*/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
if ( 0 != ret )
|
||||
if (0 != ret)
|
||||
{
|
||||
pm_activity(CONFIG_PM_BUTTON_ACTIVITY);
|
||||
pm_activity(PM_IDLE_DOMAIN, CONFIG_PM_BUTTON_ACTIVITY);
|
||||
}
|
||||
#endif
|
||||
|
||||
|
@ -141,8 +141,8 @@ void stm32l4_board_clockconfig(void)
|
||||
|
||||
/* Set the PLL dividers and multipliers to configure the SAI1 PLL */
|
||||
|
||||
regval = (STM32L4_PLLSAI1CFG_PLLN | STM32L4_PLLSAI1CFG_PLLP
|
||||
| STM32L4_PLLSAI1CFG_PLLQ | STM32L4_PLLSAI1CFG_PLLR);
|
||||
regval = (STM32L4_PLLSAI1CFG_PLLN | STM32L4_PLLSAI1CFG_PLLP |
|
||||
STM32L4_PLLSAI1CFG_PLLQ | STM32L4_PLLSAI1CFG_PLLR);
|
||||
regval |= RCC_PLLSAI1CFG_PLLQEN;
|
||||
putreg32(regval, STM32L4_RCC_PLLSAI1CFG);
|
||||
|
||||
@ -165,8 +165,8 @@ void stm32l4_board_clockconfig(void)
|
||||
/* Enable the SAI2 PLL */
|
||||
/* Set the PLL dividers and multipliers to configure the SAI2 PLL */
|
||||
|
||||
regval = (STM32L4_PLLSAI2CFG_PLLN | STM32L4_PLLSAI2CFG_PLLP
|
||||
| STM32L4_PLLSAI2CFG_PLLR);
|
||||
regval = (STM32L4_PLLSAI2CFG_PLLN | STM32L4_PLLSAI2CFG_PLLP |
|
||||
STM32L4_PLLSAI2CFG_PLLR);
|
||||
putreg32(regval, STM32L4_RCC_PLLSAI2CFG);
|
||||
|
||||
/* Enable the SAI1 PLL */
|
||||
@ -184,7 +184,8 @@ void stm32l4_board_clockconfig(void)
|
||||
/* Enable FLASH prefetch, instruction cache, data cache, and 5 wait states */
|
||||
|
||||
#ifdef CONFIG_STM32L4_FLASH_PREFETCH
|
||||
regval = (FLASH_ACR_LATENCY_4 | FLASH_ACR_ICEN | FLASH_ACR_DCEN | FLASH_ACR_PRFTEN);
|
||||
regval = (FLASH_ACR_LATENCY_4 | FLASH_ACR_ICEN | FLASH_ACR_DCEN |
|
||||
FLASH_ACR_PRFTEN);
|
||||
#else
|
||||
regval = (FLASH_ACR_LATENCY_4 | FLASH_ACR_ICEN | FLASH_ACR_DCEN);
|
||||
#endif
|
||||
@ -217,6 +218,7 @@ void stm32l4_board_clockconfig(void)
|
||||
* TODO: There is another case where the LSE needs to
|
||||
* be enabled: if the MCO1 pin selects LSE as source.
|
||||
*/
|
||||
|
||||
stm32l4_pwr_enableclk(true);
|
||||
stm32l4_rcc_enablelse();
|
||||
#endif
|
||||
|
@ -77,8 +77,10 @@
|
||||
/* LED Power Management */
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, enum pm_state_e pmstate);
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate);
|
||||
#endif
|
||||
|
||||
/****************************************************************************
|
||||
@ -107,7 +109,8 @@ static struct pm_callback_s g_ledscb =
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static void led_pm_notify(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
switch (pmstate)
|
||||
{
|
||||
@ -169,7 +172,8 @@ static void led_pm_notify(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
****************************************************************************/
|
||||
|
||||
#ifdef CONFIG_PM
|
||||
static int led_pm_prepare(struct pm_callback_s *cb , enum pm_state_e pmstate)
|
||||
static int led_pm_prepare(struct pm_callback_s *cb, int domain,
|
||||
enum pm_state_e pmstate)
|
||||
{
|
||||
/* No preparation to change power modes is required by the LEDs driver.
|
||||
* We always accept the state change by returning OK.
|
||||
|
Loading…
Reference in New Issue
Block a user