lib/os: cbprintf_packaged: simplify rodata check
NIOS2 is using _image_rodata_start/_end in its linker script to mark the boundaries of rodata. So they no loner need special treatment. Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
parent
990919fb89
commit
2c6da987cd
1 changed files with 2 additions and 6 deletions
|
@ -30,16 +30,12 @@ static inline bool ptr_in_rodata(const char *addr)
|
|||
#define RO_START 0
|
||||
#define RO_END 0
|
||||
#elif defined(CONFIG_ARC) || defined(CONFIG_ARM) || defined(CONFIG_X86) \
|
||||
|| defined(CONFIG_RISCV) || defined(CONFIG_ARM64)
|
||||
|| defined(CONFIG_RISCV) || defined(CONFIG_ARM64) \
|
||||
|| defined(CONFIG_NIOS2)
|
||||
extern char _image_rodata_start[];
|
||||
extern char _image_rodata_end[];
|
||||
#define RO_START _image_rodata_start
|
||||
#define RO_END _image_rodata_end
|
||||
#elif defined(CONFIG_NIOS2) || defined(CONFIG_RISCV)
|
||||
extern char _image_rom_start[];
|
||||
extern char _image_rom_end[];
|
||||
#define RO_START _image_rom_start
|
||||
#define RO_END _image_rom_end
|
||||
#elif defined(CONFIG_XTENSA)
|
||||
extern char _rodata_start[];
|
||||
extern char _rodata_end[];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue