fsl_smc.h 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456
  1. /*
  2. * Copyright (c) 2015, Freescale Semiconductor, Inc.
  3. * Copyright 2016-2017 NXP
  4. *
  5. * Redistribution and use in source and binary forms, with or without modification,
  6. * are permitted provided that the following conditions are met:
  7. *
  8. * o Redistributions of source code must retain the above copyright notice, this list
  9. * of conditions and the following disclaimer.
  10. *
  11. * o Redistributions in binary form must reproduce the above copyright notice, this
  12. * list of conditions and the following disclaimer in the documentation and/or
  13. * other materials provided with the distribution.
  14. *
  15. * o Neither the name of the copyright holder nor the names of its
  16. * contributors may be used to endorse or promote products derived from this
  17. * software without specific prior written permission.
  18. *
  19. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
  20. * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
  21. * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
  22. * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
  23. * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
  24. * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  25. * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
  26. * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  27. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
  28. * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  29. */
  30. #ifndef _FSL_SMC_H_
  31. #define _FSL_SMC_H_
  32. #include "fsl_common.h"
  33. /*! @addtogroup smc */
  34. /*! @{ */
  35. /*******************************************************************************
  36. * Definitions
  37. ******************************************************************************/
  38. /*! @name Driver version */
  39. /*@{*/
  40. /*! @brief SMC driver version 2.0.3. */
  41. #define FSL_SMC_DRIVER_VERSION (MAKE_VERSION(2, 0, 3))
  42. /*@}*/
  43. /*!
  44. * @brief Power Modes Protection
  45. */
  46. typedef enum _smc_power_mode_protection
  47. {
  48. #if (defined(FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE)
  49. kSMC_AllowPowerModeVlls = SMC_PMPROT_AVLLS_MASK, /*!< Allow Very-low-leakage Stop Mode. */
  50. #endif
  51. #if (defined(FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE)
  52. kSMC_AllowPowerModeLls = SMC_PMPROT_ALLS_MASK, /*!< Allow Low-leakage Stop Mode. */
  53. #endif /* FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE */
  54. kSMC_AllowPowerModeVlp = SMC_PMPROT_AVLP_MASK, /*!< Allow Very-Low-power Mode. */
  55. #if (defined(FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE) && FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE)
  56. kSMC_AllowPowerModeHsrun = SMC_PMPROT_AHSRUN_MASK, /*!< Allow High-speed Run mode. */
  57. #endif /* FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE */
  58. kSMC_AllowPowerModeAll = (0U
  59. #if (defined(FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE)
  60. |
  61. SMC_PMPROT_AVLLS_MASK
  62. #endif
  63. #if (defined(FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE)
  64. |
  65. SMC_PMPROT_ALLS_MASK
  66. #endif /* FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE */
  67. |
  68. SMC_PMPROT_AVLP_MASK
  69. #if (defined(FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE) && FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE)
  70. |
  71. kSMC_AllowPowerModeHsrun
  72. #endif /* FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE */
  73. ) /*!< Allow all power mode. */
  74. } smc_power_mode_protection_t;
  75. /*!
  76. * @brief Power Modes in PMSTAT
  77. */
  78. typedef enum _smc_power_state
  79. {
  80. kSMC_PowerStateRun = 0x01U << 0U, /*!< 0000_0001 - Current power mode is RUN */
  81. kSMC_PowerStateStop = 0x01U << 1U, /*!< 0000_0010 - Current power mode is STOP */
  82. kSMC_PowerStateVlpr = 0x01U << 2U, /*!< 0000_0100 - Current power mode is VLPR */
  83. kSMC_PowerStateVlpw = 0x01U << 3U, /*!< 0000_1000 - Current power mode is VLPW */
  84. kSMC_PowerStateVlps = 0x01U << 4U, /*!< 0001_0000 - Current power mode is VLPS */
  85. #if (defined(FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE)
  86. kSMC_PowerStateLls = 0x01U << 5U, /*!< 0010_0000 - Current power mode is LLS */
  87. #endif /* FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE */
  88. #if (defined(FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE)
  89. kSMC_PowerStateVlls = 0x01U << 6U, /*!< 0100_0000 - Current power mode is VLLS */
  90. #endif
  91. #if (defined(FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE) && FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE)
  92. kSMC_PowerStateHsrun = 0x01U << 7U /*!< 1000_0000 - Current power mode is HSRUN */
  93. #endif /* FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE */
  94. } smc_power_state_t;
  95. /*!
  96. * @brief Run mode definition
  97. */
  98. typedef enum _smc_run_mode
  99. {
  100. kSMC_RunNormal = 0U, /*!< Normal RUN mode. */
  101. kSMC_RunVlpr = 2U, /*!< Very-low-power RUN mode. */
  102. #if (defined(FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE) && FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE)
  103. kSMC_Hsrun = 3U /*!< High-speed Run mode (HSRUN). */
  104. #endif /* FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE */
  105. } smc_run_mode_t;
  106. /*!
  107. * @brief Stop mode definition
  108. */
  109. typedef enum _smc_stop_mode
  110. {
  111. kSMC_StopNormal = 0U, /*!< Normal STOP mode. */
  112. kSMC_StopVlps = 2U, /*!< Very-low-power STOP mode. */
  113. #if (defined(FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE)
  114. kSMC_StopLls = 3U, /*!< Low-leakage Stop mode. */
  115. #endif /* FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE */
  116. #if (defined(FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE)
  117. kSMC_StopVlls = 4U /*!< Very-low-leakage Stop mode. */
  118. #endif
  119. } smc_stop_mode_t;
  120. #if (defined(FSL_FEATURE_SMC_USE_VLLSCTRL_REG) && FSL_FEATURE_SMC_USE_VLLSCTRL_REG) || \
  121. (defined(FSL_FEATURE_SMC_USE_STOPCTRL_VLLSM) && FSL_FEATURE_SMC_USE_STOPCTRL_VLLSM) || \
  122. (defined(FSL_FEATURE_SMC_HAS_LLS_SUBMODE) && FSL_FEATURE_SMC_HAS_LLS_SUBMODE)
  123. /*!
  124. * @brief VLLS/LLS stop sub mode definition
  125. */
  126. typedef enum _smc_stop_submode
  127. {
  128. kSMC_StopSub0 = 0U, /*!< Stop submode 0, for VLLS0/LLS0. */
  129. kSMC_StopSub1 = 1U, /*!< Stop submode 1, for VLLS1/LLS1. */
  130. kSMC_StopSub2 = 2U, /*!< Stop submode 2, for VLLS2/LLS2. */
  131. kSMC_StopSub3 = 3U /*!< Stop submode 3, for VLLS3/LLS3. */
  132. } smc_stop_submode_t;
  133. #endif
  134. /*!
  135. * @brief Partial STOP option
  136. */
  137. typedef enum _smc_partial_stop_mode
  138. {
  139. kSMC_PartialStop = 0U, /*!< STOP - Normal Stop mode*/
  140. kSMC_PartialStop1 = 1U, /*!< Partial Stop with both system and bus clocks disabled*/
  141. kSMC_PartialStop2 = 2U, /*!< Partial Stop with system clock disabled and bus clock enabled*/
  142. } smc_partial_stop_option_t;
  143. /*!
  144. * @brief SMC configuration status.
  145. */
  146. enum _smc_status
  147. {
  148. kStatus_SMC_StopAbort = MAKE_STATUS(kStatusGroup_POWER, 0) /*!< Entering Stop mode is abort*/
  149. };
  150. #if (defined(FSL_FEATURE_SMC_HAS_VERID) && FSL_FEATURE_SMC_HAS_VERID)
  151. /*!
  152. * @brief IP version ID definition.
  153. */
  154. typedef struct _smc_version_id
  155. {
  156. uint16_t feature; /*!< Feature Specification Number. */
  157. uint8_t minor; /*!< Minor version number. */
  158. uint8_t major; /*!< Major version number. */
  159. } smc_version_id_t;
  160. #endif /* FSL_FEATURE_SMC_HAS_VERID */
  161. #if (defined(FSL_FEATURE_SMC_HAS_PARAM) && FSL_FEATURE_SMC_HAS_PARAM)
  162. /*!
  163. * @brief IP parameter definition.
  164. */
  165. typedef struct _smc_param
  166. {
  167. bool hsrunEnable; /*!< HSRUN mode enable. */
  168. bool llsEnable; /*!< LLS mode enable. */
  169. bool lls2Enable; /*!< LLS2 mode enable. */
  170. bool vlls0Enable; /*!< VLLS0 mode enable. */
  171. } smc_param_t;
  172. #endif /* FSL_FEATURE_SMC_HAS_PARAM */
  173. #if (defined(FSL_FEATURE_SMC_HAS_LLS_SUBMODE) && FSL_FEATURE_SMC_HAS_LLS_SUBMODE) || \
  174. (defined(FSL_FEATURE_SMC_HAS_LPOPO) && FSL_FEATURE_SMC_HAS_LPOPO)
  175. /*!
  176. * @brief SMC Low-Leakage Stop power mode configuration.
  177. */
  178. typedef struct _smc_power_mode_lls_config
  179. {
  180. #if (defined(FSL_FEATURE_SMC_HAS_LLS_SUBMODE) && FSL_FEATURE_SMC_HAS_LLS_SUBMODE)
  181. smc_stop_submode_t subMode; /*!< Low-leakage Stop sub-mode */
  182. #endif
  183. #if (defined(FSL_FEATURE_SMC_HAS_LPOPO) && FSL_FEATURE_SMC_HAS_LPOPO)
  184. bool enableLpoClock; /*!< Enable LPO clock in LLS mode */
  185. #endif
  186. } smc_power_mode_lls_config_t;
  187. #endif /* (FSL_FEATURE_SMC_HAS_LLS_SUBMODE || FSL_FEATURE_SMC_HAS_LPOPO) */
  188. #if (defined(FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE)
  189. /*!
  190. * @brief SMC Very Low-Leakage Stop power mode configuration.
  191. */
  192. typedef struct _smc_power_mode_vlls_config
  193. {
  194. #if (defined(FSL_FEATURE_SMC_USE_VLLSCTRL_REG) && FSL_FEATURE_SMC_USE_VLLSCTRL_REG) || \
  195. (defined(FSL_FEATURE_SMC_USE_STOPCTRL_VLLSM) && FSL_FEATURE_SMC_USE_STOPCTRL_VLLSM) || \
  196. (defined(FSL_FEATURE_SMC_HAS_LLS_SUBMODE) && FSL_FEATURE_SMC_HAS_LLS_SUBMODE)
  197. smc_stop_submode_t subMode; /*!< Very Low-leakage Stop sub-mode */
  198. #endif
  199. #if (defined(FSL_FEATURE_SMC_HAS_PORPO) && FSL_FEATURE_SMC_HAS_PORPO)
  200. bool enablePorDetectInVlls0; /*!< Enable Power on reset detect in VLLS mode */
  201. #endif
  202. #if (defined(FSL_FEATURE_SMC_HAS_RAM2_POWER_OPTION) && FSL_FEATURE_SMC_HAS_RAM2_POWER_OPTION)
  203. bool enableRam2InVlls2; /*!< Enable RAM2 power in VLLS2 */
  204. #endif
  205. #if (defined(FSL_FEATURE_SMC_HAS_LPOPO) && FSL_FEATURE_SMC_HAS_LPOPO)
  206. bool enableLpoClock; /*!< Enable LPO clock in VLLS mode */
  207. #endif
  208. } smc_power_mode_vlls_config_t;
  209. #endif
  210. /*******************************************************************************
  211. * API
  212. ******************************************************************************/
  213. #if defined(__cplusplus)
  214. extern "C" {
  215. #endif /* __cplusplus */
  216. /*! @name System mode controller APIs*/
  217. /*@{*/
  218. #if (defined(FSL_FEATURE_SMC_HAS_VERID) && FSL_FEATURE_SMC_HAS_VERID)
  219. /*!
  220. * @brief Gets the SMC version ID.
  221. *
  222. * This function gets the SMC version ID, including major version number,
  223. * minor version number, and feature specification number.
  224. *
  225. * @param base SMC peripheral base address.
  226. * @param versionId Pointer to the version ID structure.
  227. */
  228. static inline void SMC_GetVersionId(SMC_Type *base, smc_version_id_t *versionId)
  229. {
  230. *((uint32_t *)versionId) = base->VERID;
  231. }
  232. #endif /* FSL_FEATURE_SMC_HAS_VERID */
  233. #if (defined(FSL_FEATURE_SMC_HAS_PARAM) && FSL_FEATURE_SMC_HAS_PARAM)
  234. /*!
  235. * @brief Gets the SMC parameter.
  236. *
  237. * This function gets the SMC parameter including the enabled power mdoes.
  238. *
  239. * @param base SMC peripheral base address.
  240. * @param param Pointer to the SMC param structure.
  241. */
  242. void SMC_GetParam(SMC_Type *base, smc_param_t *param);
  243. #endif
  244. /*!
  245. * @brief Configures all power mode protection settings.
  246. *
  247. * This function configures the power mode protection settings for
  248. * supported power modes in the specified chip family. The available power modes
  249. * are defined in the smc_power_mode_protection_t. This should be done at an early
  250. * system level initialization stage. See the reference manual for details.
  251. * This register can only write once after the power reset.
  252. *
  253. * The allowed modes are passed as bit map. For example, to allow LLS and VLLS,
  254. * use SMC_SetPowerModeProtection(kSMC_AllowPowerModeVlls | kSMC_AllowPowerModeVlps).
  255. * To allow all modes, use SMC_SetPowerModeProtection(kSMC_AllowPowerModeAll).
  256. *
  257. * @param base SMC peripheral base address.
  258. * @param allowedModes Bitmap of the allowed power modes.
  259. */
  260. static inline void SMC_SetPowerModeProtection(SMC_Type *base, uint8_t allowedModes)
  261. {
  262. base->PMPROT = allowedModes;
  263. }
  264. /*!
  265. * @brief Gets the current power mode status.
  266. *
  267. * This function returns the current power mode status. After the application
  268. * switches the power mode, it should always check the status to check whether it
  269. * runs into the specified mode or not. The application should check
  270. * this mode before switching to a different mode. The system requires that
  271. * only certain modes can switch to other specific modes. See the
  272. * reference manual for details and the smc_power_state_t for information about
  273. * the power status.
  274. *
  275. * @param base SMC peripheral base address.
  276. * @return Current power mode status.
  277. */
  278. static inline smc_power_state_t SMC_GetPowerModeState(SMC_Type *base)
  279. {
  280. return (smc_power_state_t)base->PMSTAT;
  281. }
  282. /*!
  283. * @brief Prepares to enter stop modes.
  284. *
  285. * This function should be called before entering STOP/VLPS/LLS/VLLS modes.
  286. */
  287. void SMC_PreEnterStopModes(void);
  288. /*!
  289. * @brief Recovers after wake up from stop modes.
  290. *
  291. * This function should be called after wake up from STOP/VLPS/LLS/VLLS modes.
  292. * It is used with @ref SMC_PreEnterStopModes.
  293. */
  294. void SMC_PostExitStopModes(void);
  295. /*!
  296. * @brief Prepares to enter wait modes.
  297. *
  298. * This function should be called before entering WAIT/VLPW modes.
  299. */
  300. static inline void SMC_PreEnterWaitModes(void)
  301. {
  302. __disable_irq();
  303. __ISB();
  304. }
  305. /*!
  306. * @brief Recovers after wake up from stop modes.
  307. *
  308. * This function should be called after wake up from WAIT/VLPW modes.
  309. * It is used with @ref SMC_PreEnterWaitModes.
  310. */
  311. static inline void SMC_PostExitWaitModes(void)
  312. {
  313. __enable_irq();
  314. __ISB();
  315. }
  316. /*!
  317. * @brief Configures the system to RUN power mode.
  318. *
  319. * @param base SMC peripheral base address.
  320. * @return SMC configuration error code.
  321. */
  322. status_t SMC_SetPowerModeRun(SMC_Type *base);
  323. #if (defined(FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE) && FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE)
  324. /*!
  325. * @brief Configures the system to HSRUN power mode.
  326. *
  327. * @param base SMC peripheral base address.
  328. * @return SMC configuration error code.
  329. */
  330. status_t SMC_SetPowerModeHsrun(SMC_Type *base);
  331. #endif /* FSL_FEATURE_SMC_HAS_HIGH_SPEED_RUN_MODE */
  332. /*!
  333. * @brief Configures the system to WAIT power mode.
  334. *
  335. * @param base SMC peripheral base address.
  336. * @return SMC configuration error code.
  337. */
  338. status_t SMC_SetPowerModeWait(SMC_Type *base);
  339. /*!
  340. * @brief Configures the system to Stop power mode.
  341. *
  342. * @param base SMC peripheral base address.
  343. * @param option Partial Stop mode option.
  344. * @return SMC configuration error code.
  345. */
  346. status_t SMC_SetPowerModeStop(SMC_Type *base, smc_partial_stop_option_t option);
  347. #if (defined(FSL_FEATURE_SMC_HAS_LPWUI) && FSL_FEATURE_SMC_HAS_LPWUI)
  348. /*!
  349. * @brief Configures the system to VLPR power mode.
  350. *
  351. * @param base SMC peripheral base address.
  352. * @param wakeupMode Enter Normal Run mode if true, else stay in VLPR mode.
  353. * @return SMC configuration error code.
  354. */
  355. status_t SMC_SetPowerModeVlpr(SMC_Type *base, bool wakeupMode);
  356. #else
  357. /*!
  358. * @brief Configures the system to VLPR power mode.
  359. *
  360. * @param base SMC peripheral base address.
  361. * @return SMC configuration error code.
  362. */
  363. status_t SMC_SetPowerModeVlpr(SMC_Type *base);
  364. #endif /* FSL_FEATURE_SMC_HAS_LPWUI */
  365. /*!
  366. * @brief Configures the system to VLPW power mode.
  367. *
  368. * @param base SMC peripheral base address.
  369. * @return SMC configuration error code.
  370. */
  371. status_t SMC_SetPowerModeVlpw(SMC_Type *base);
  372. /*!
  373. * @brief Configures the system to VLPS power mode.
  374. *
  375. * @param base SMC peripheral base address.
  376. * @return SMC configuration error code.
  377. */
  378. status_t SMC_SetPowerModeVlps(SMC_Type *base);
  379. #if (defined(FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE)
  380. #if ((defined(FSL_FEATURE_SMC_HAS_LLS_SUBMODE) && FSL_FEATURE_SMC_HAS_LLS_SUBMODE) || \
  381. (defined(FSL_FEATURE_SMC_HAS_LPOPO) && FSL_FEATURE_SMC_HAS_LPOPO))
  382. /*!
  383. * @brief Configures the system to LLS power mode.
  384. *
  385. * @param base SMC peripheral base address.
  386. * @param config The LLS power mode configuration structure
  387. * @return SMC configuration error code.
  388. */
  389. status_t SMC_SetPowerModeLls(SMC_Type *base, const smc_power_mode_lls_config_t *config);
  390. #else
  391. /*!
  392. * @brief Configures the system to LLS power mode.
  393. *
  394. * @param base SMC peripheral base address.
  395. * @return SMC configuration error code.
  396. */
  397. status_t SMC_SetPowerModeLls(SMC_Type *base);
  398. #endif
  399. #endif /* FSL_FEATURE_SMC_HAS_LOW_LEAKAGE_STOP_MODE */
  400. #if (defined(FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE) && FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE)
  401. /*!
  402. * @brief Configures the system to VLLS power mode.
  403. *
  404. * @param base SMC peripheral base address.
  405. * @param config The VLLS power mode configuration structure.
  406. * @return SMC configuration error code.
  407. */
  408. status_t SMC_SetPowerModeVlls(SMC_Type *base, const smc_power_mode_vlls_config_t *config);
  409. #endif /* FSL_FEATURE_SMC_HAS_VERY_LOW_LEAKAGE_STOP_MODE */
  410. /*@}*/
  411. #if defined(__cplusplus)
  412. }
  413. #endif /* __cplusplus */
  414. /*! @}*/
  415. #endif /* _FSL_SMC_H_ */