diff options
author | patacongo <patacongo@7fd9a85b-ad96-42d3-883c-3090e2eb8679> | 2011-08-12 22:10:48 +0000 |
---|---|---|
committer | patacongo <patacongo@7fd9a85b-ad96-42d3-883c-3090e2eb8679> | 2011-08-12 22:10:48 +0000 |
commit | 04e97b88665439bdcffa81ce3fbb4db2c799c9a3 (patch) | |
tree | 401de244f5464fd9d593cc676395702d0510f915 /nuttx/arch/arm/src/common | |
parent | d56df9badf0864603f988e176b9d1a99596c2e92 (diff) |
Add Kinesis watchdog, ramfuncs, idle loop, start of clock configuration
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@3875 7fd9a85b-ad96-42d3-883c-3090e2eb8679
Diffstat (limited to 'nuttx/arch/arm/src/common')
-rw-r--r-- | nuttx/arch/arm/src/common/up_internal.h | 30 |
1 files changed, 29 insertions, 1 deletions
diff --git a/nuttx/arch/arm/src/common/up_internal.h b/nuttx/arch/arm/src/common/up_internal.h index 43c8bbeeb5..108dbd2ac6 100644 --- a/nuttx/arch/arm/src/common/up_internal.h +++ b/nuttx/arch/arm/src/common/up_internal.h @@ -147,7 +147,35 @@ extern uint32_t _sdata; /* Start of .data */ extern uint32_t _edata; /* End+1 of .data */ extern uint32_t _sbss; /* Start of .bss */ extern uint32_t _ebss; /* End+1 of .bss */ -#endif + +/* Sometimes, functions must be executed from RAM. In this case, the following + * macro may be used (with GCC!) to specify a function that will execute from + * RAM. For example, + * + * int __ramfunc__ foo (void); + * int __ramfunc__ foo (void) { return bar; } + * + * will create a function named foo that will execute from RAM. + */ + +#ifdef CONFIG_BOOT_RAMFUNCS + +# define __ramfunc__ __attribute__ ((section(".ramfunc"))) + +/* Functions decleared in the .ramfunc section will be packaged together + * by the linker script and stored in FLASH. During boot-up, the start + * logic must include logic to copy the RAM functions from their storage + * location in FLASH to their correct destination in SRAM. The following + * following linker-defined values provide the information to copy the + * functions from flash to RAM. + */ + +extern const uint32_t _framfuncs; /* Copy source address in FLASH */ +extern uint32_t _sramfuncs; /* Copy destination start address in RAM */ +extern uint32_t _eramfuncs; /* Copy destination start address in RAM */ + +#endif /* CONFIG_BOOT_RAMFUNCS */ +#endif /* __ASSEMBLY__ */ /**************************************************************************** * Inline Functions |