Zephyr API Documentation
4.2.0-rc3
A Scalable Open Source RTOS
4.2.0-rc3
Toggle main menu visibility
Main Page
Related Pages
Topics
Data Structures
Data Structures
Data Structure Index
Data Fields
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Functions
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Enumerations
Enumerator
Files
File List
Globals
All
$
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Variables
$
a
b
c
d
f
g
h
i
k
l
m
n
o
p
r
s
t
u
x
z
Typedefs
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Enumerator
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
r
s
t
u
v
w
x
z
Macros
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Zephyr API Documentation
Introduction
Deprecated List
Topics
Data Structures
Files
File List
doc
kernel
lib
modules
subsys
zephyr
acpi
app_memory
arch
audio
bluetooth
canbus
console
crypto
data
debug
devicetree
dfu
display
drivers
dsp
dt-bindings
fs
input
internal
ipc
kernel
linker
devicetree_regions.h
iterable_sections.h
linker-defs.h
linker-devnull.h
linker-tool-gcc.h
linker-tool-lld.h
linker-tool-mwdt.h
linker-tool.h
section_tags.h
sections.h
utils.h
llext
logging
lorawan
math
mem_mgmt
mgmt
misc
modbus
modem
multi_heap
net
platform
pm
pmci
portability
posix
psa
random
retention
rtio
sd
sensing
settings
shell
sip_svc
stats
storage
sys
task_wdt
timing
toolchain
tracing
usb
usb_c
xen
zbus
zvfs
bindesc.h
cache.h
device.h
devicetree.h
fatal.h
fatal_types.h
init.h
irq.h
irq_multilevel.h
irq_nextlevel.h
irq_offload.h
kernel.h
kernel_includes.h
kernel_structs.h
kernel_version.h
net_buf.h
shared_irq.h
smf.h
spinlock.h
sw_isr_table.h
sys_clock.h
syscall.h
toolchain.h
types.h
Globals
•
All
Data Structures
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Modules
Pages
Loading...
Searching...
No Matches
iterable_sections.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2020, Intel Corporation
3
* Copyright (C) 2023, Nordic Semiconductor ASA
4
* SPDX-License-Identifier: Apache-2.0
5
*/
6
7
#ifndef INCLUDE_ZEPHYR_LINKER_ITERABLE_SECTIONS_H_
8
#define INCLUDE_ZEPHYR_LINKER_ITERABLE_SECTIONS_H_
9
14
15
/* clang-format off */
16
#define Z_LINK_ITERABLE(struct_type) \
17
PLACE_SYMBOL_HERE(_CONCAT(_##struct_type, _list_start)); \
18
KEEP(*(SORT_BY_NAME(._##struct_type.static.*))); \
19
PLACE_SYMBOL_HERE(_CONCAT(_##struct_type, _list_end));
20
21
22
#define Z_LINK_ITERABLE_NUMERIC(struct_type) \
23
PLACE_SYMBOL_HERE(_CONCAT(_##struct_type, _list_start)); \
24
KEEP(*(SORT(._##struct_type.static.*_?_*))); \
25
KEEP(*(SORT(._##struct_type.static.*_??_*))); \
26
KEEP(*(SORT(._##struct_type.static.*_???_*))); \
27
KEEP(*(SORT(._##struct_type.static.*_????_*))); \
28
KEEP(*(SORT(._##struct_type.static.*_?????_*))); \
29
PLACE_SYMBOL_HERE(_CONCAT(_##struct_type, _list_end));
30
31
#define Z_LINK_ITERABLE_ALIGNED(struct_type, align) \
32
. = ALIGN(align); \
33
Z_LINK_ITERABLE(struct_type);
34
35
#define Z_LINK_ITERABLE_GC_ALLOWED(struct_type) \
36
PLACE_SYMBOL_HERE(_CONCAT(_##struct_type, _list_start)); \
37
*(SORT_BY_NAME(._##struct_type.static.*)); \
38
PLACE_SYMBOL_HERE(_CONCAT(_##struct_type, _list_end));
39
/* clang-format on */
40
41
#define Z_LINK_ITERABLE_SUBALIGN CONFIG_LINKER_ITERABLE_SUBALIGN
42
57
#define ITERABLE_SECTION_ROM(struct_type, subalign) \
58
SECTION_PROLOGUE(struct_type##_area, ,) \
59
{ \
60
Z_LINK_ITERABLE(struct_type); \
61
} GROUP_ROM_LINK_IN(RAMABLE_REGION, ROMABLE_REGION)
57
#define ITERABLE_SECTION_ROM(struct_type, subalign) \
…
62
72
#define ITERABLE_SECTION_ROM_NUMERIC(struct_type, subalign) \
73
SECTION_PROLOGUE(struct_type##_area, EMPTY,) \
74
{ \
75
Z_LINK_ITERABLE_NUMERIC(struct_type); \
76
} GROUP_ROM_LINK_IN(RAMABLE_REGION, ROMABLE_REGION)
72
#define ITERABLE_SECTION_ROM_NUMERIC(struct_type, subalign) \
…
77
90
#define ITERABLE_SECTION_ROM_GC_ALLOWED(struct_type, subalign) \
91
SECTION_PROLOGUE(struct_type##_area, ,) \
92
{ \
93
Z_LINK_ITERABLE_GC_ALLOWED(struct_type); \
94
} GROUP_LINK_IN(ROMABLE_REGION)
90
#define ITERABLE_SECTION_ROM_GC_ALLOWED(struct_type, subalign) \
…
95
110
#define ITERABLE_SECTION_RAM(struct_type, subalign) \
111
SECTION_DATA_PROLOGUE(struct_type##_area, ,) \
112
{ \
113
Z_LINK_ITERABLE(struct_type); \
114
} GROUP_DATA_LINK_IN(RAMABLE_REGION, ROMABLE_REGION)
110
#define ITERABLE_SECTION_RAM(struct_type, subalign) \
…
115
125
#define ITERABLE_SECTION_RAM_NUMERIC(struct_type, subalign) \
126
SECTION_PROLOGUE(struct_type##_area, EMPTY,) \
127
{ \
128
Z_LINK_ITERABLE_NUMERIC(struct_type); \
129
} GROUP_DATA_LINK_IN(RAMABLE_REGION, ROMABLE_REGION)
125
#define ITERABLE_SECTION_RAM_NUMERIC(struct_type, subalign) \
…
130
143
#define ITERABLE_SECTION_RAM_GC_ALLOWED(struct_type, subalign) \
144
SECTION_DATA_PROLOGUE(struct_type##_area, ,) \
145
{ \
146
Z_LINK_ITERABLE_GC_ALLOWED(struct_type); \
147
} GROUP_DATA_LINK_IN(RAMABLE_REGION, ROMABLE_REGION)
143
#define ITERABLE_SECTION_RAM_GC_ALLOWED(struct_type, subalign) \
…
148
/* end of struct_section_apis */
152
153
#endif
/* INCLUDE_ZEPHYR_LINKER_ITERABLE_SECTIONS_H_ */
zephyr
linker
iterable_sections.h
Generated on
for Zephyr API Documentation by
1.14.0