zephyr/include/linker
Sebastian Bøe ed85b76093 LD: Assert when CONFIG_PRIVILEGED_STACK_TEXT_AREA is too small
The error message is obscure when CONFIG_PRIVILEGED_STACK_TEXT_AREA is
configured incorrectly. It looks like this:

zephyr/linker.cmd:73 cannot move location counter backwards (from
0000000000069bfc to 0000000000069bd8)

This patch re-writes the linker script mechanism in a (believed and
tested) semantically equivalent way such that it is possible to use an
assertion.

The assertion's error message now looks like this:

Memory region         Used Size  Region Size  %age Used
           FLASH:      503012 B         1 MB     47.97%
            SRAM:       53760 B       256 KB     20.51%
        IDT_LIST:         120 B         2 KB      5.86
real-ld: The configuration system has incorrectly set
'CONFIG_PRIVILEGED_STACK_TEXT_AREA' to
128, which is not big enough. You must
through Kconfig either disable 'CONFIG_USERSPACE', or set
'CONFIG_PRIVILEGED_STACK_TEXT_AREA' to a value larger than
128 .
collect2: error: ld returned 1 exit status

Signed-off-by: Sebastian Bøe <sebastian.boe@nordicsemi.no>
2019-02-12 10:28:38 -05:00
..
common-ram.ld kernel: remove k_alert API 2019-01-16 21:34:07 -05:00
common-rom.ld app_shmem: auto-initialize partitions 2019-01-30 23:15:51 -05:00
debug-sections.ld linker: x86: add orphan linker sections 2019-01-26 09:21:17 -05:00
intlist.ld gen_isr_tables: Delete the dead code accompanying .intList.num_isrs 2018-06-25 12:54:49 -07:00
kobject-rom.ld kernel: introduce object validation mechanism 2017-09-07 16:33:33 -07:00
kobject-text.ld userspace: move KOBJECT/PRIVILEGED_STACK_TEXT_AREA to Kconfig 2018-10-08 14:18:26 -04:00
kobject.ld kernel: threads: assign index no. to dynamically created threads 2018-08-09 09:20:14 -07:00
linker-defs.h dts: Convert CONFIG_CCM to DT_CCM 2019-02-08 10:29:57 -06:00
linker-tool-gcc.h arch: add big endian support 2018-10-10 09:28:05 -04:00
linker-tool.h headers: Fix headers across the project 2018-09-17 15:49:26 -04:00
priv_stacks-noinit.ld linker: arm: place priv.noinit at the end of RAM 2018-10-19 16:11:34 -04:00
priv_stacks-rom.ld arm: Generate privileged stacks 2018-02-06 15:31:16 -08:00
priv_stacks-text.ld LD: Assert when CONFIG_PRIVILEGED_STACK_TEXT_AREA is too small 2019-02-12 10:28:38 -05:00
priv_stacks.ld arm: Generate privileged stacks 2018-02-06 15:31:16 -08:00
rel-sections.ld linker: warn about orphan sections 2018-10-19 16:11:34 -04:00
section_tags.h soc: nxp_imx: Add support for device configuration data (DCD) 2019-01-09 16:01:25 -06:00
sections.h soc: nxp_imx: Add support for device configuration data (DCD) 2019-01-09 16:01:25 -06:00