zephyr/subsys/debug
Noah Pendleton 00d8870a50 debug: Set thread_info.c variables to const
The variables are usually placed into an output region located in FLASH
memory when linking, but the variables are not marked `const`, so the
section ends up with `W` writeable section flag:

```bash
❯ arm-zephyr-eabi-readelf --section-headers build/zephyr/zephyr.elf | \
  grep -E '(Section Headers:)|(  \[Nr\])|(zephyr_dbg_info)'
Section Headers:
  [Nr] Name            Type     Addr     Off    Size   ES Flg Lk Inf Al
  [10] zephyr_dbg_info PROGBITS 60012298 01238c 000040 00  WA  0   0  4
```

Set them as const to set the output section to read-only:

```bash
❯ arm-zephyr-eabi-readelf --section-headers build/zephyr/zephyr.elf | \
  grep -E '(Section Headers:)|(  \[Nr\])|(zephyr_dbg_info)'
Section Headers:
  [Nr] Name            Type     Addr     Off    Size   ES Flg Lk Inf Al
  [10] zephyr_dbg_info PROGBITS 60012298 01238c 000040 00   A  0   0  4
```

Signed-off-by: Noah Pendleton <noah.pendleton@gmail.com>
2023-09-11 19:56:18 +02:00
..
coredump debug: coredump: flash partition: Use K_NO_WAIT when in ISR 2023-06-21 16:06:06 -04:00
gdbstub debug: gdbstub: Move to DTS for uart device 2022-08-01 09:09:45 -07:00
asan_hacks.c debug: asan: Added leak suppression for SDL2 & X11 2019-12-09 16:38:48 -05:00
CMakeLists.txt debug: Remove deprecated CONFIG_OPENOCD_SUPPORT 2022-01-24 10:23:20 -05:00
gdbstub.c debug: gdbstub: s/device.h/init.h 2023-08-30 11:52:49 +02:00
gdbstub_backend.h debug: x86: Add gdbstub for X86 2020-09-02 20:54:57 -04:00
Kconfig debug: thread_analyzer: use printk by default 2023-07-19 11:06:04 +00:00
thread_analyzer.c all: Fix "#if IS_ENABLED(CONFIG_FOO)" occurrences 2022-12-21 10:09:23 +01:00
thread_info.c debug: Set thread_info.c variables to const 2023-09-11 19:56:18 +02:00