Commit 436c7bb
committed
demand_paging: eviction: add kconfig CONFIG_EVICTION_TRACKING
This adds a new kconfig for eviction algorithm which needs page
tracking. When enabled, k_mem_paging_eviction_add()/_remove()
and k_mem_paging_eviction_accessed() must be implemented.
If an algorithm does not do page tracking, there is no need to
implement these functions, and no need for the kernel MMU code
to call into empty functions. This should save a few function
calls and some CPU cycles.
Note that arm64 unconditionally calls those functions so
forces CONFIG_EVICTION_TRACKING to be enabled there.
Signed-off-by: Daniel Leung <[email protected]>1 parent 40cd35e commit 436c7bb
File tree
6 files changed
+75
-14
lines changed- arch
- doc/kernel/memory_management
- include/zephyr/kernel/mm
- kernel
- subsys/demand_paging/eviction
6 files changed
+75
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| 58 | + | |
| 59 | + | |
58 | 60 | | |
59 | 61 | | |
60 | 62 | | |
| |||
694 | 696 | | |
695 | 697 | | |
696 | 698 | | |
| 699 | + | |
| 700 | + | |
| 701 | + | |
| 702 | + | |
| 703 | + | |
| 704 | + | |
697 | 705 | | |
698 | 706 | | |
699 | 707 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
156 | 156 | | |
157 | 157 | | |
158 | 158 | | |
159 | | - | |
160 | | - | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
161 | 165 | | |
162 | 166 | | |
163 | 167 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
217 | 217 | | |
218 | 218 | | |
219 | 219 | | |
| 220 | + | |
| 221 | + | |
220 | 222 | | |
221 | 223 | | |
222 | 224 | | |
| |||
261 | 263 | | |
262 | 264 | | |
263 | 265 | | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
264 | 285 | | |
265 | 286 | | |
266 | 287 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
556 | 556 | | |
557 | 557 | | |
558 | 558 | | |
559 | | - | |
| 559 | + | |
560 | 560 | | |
561 | 561 | | |
562 | 562 | | |
| |||
784 | 784 | | |
785 | 785 | | |
786 | 786 | | |
787 | | - | |
| 787 | + | |
| 788 | + | |
788 | 789 | | |
789 | 790 | | |
790 | 791 | | |
| |||
1041 | 1042 | | |
1042 | 1043 | | |
1043 | 1044 | | |
1044 | | - | |
| 1045 | + | |
| 1046 | + | |
1045 | 1047 | | |
1046 | 1048 | | |
1047 | 1049 | | |
| |||
1147 | 1149 | | |
1148 | 1150 | | |
1149 | 1151 | | |
1150 | | - | |
1151 | | - | |
1152 | | - | |
1153 | | - | |
| 1152 | + | |
| 1153 | + | |
| 1154 | + | |
| 1155 | + | |
| 1156 | + | |
| 1157 | + | |
| 1158 | + | |
1154 | 1159 | | |
1155 | 1160 | | |
1156 | 1161 | | |
| |||
1347 | 1352 | | |
1348 | 1353 | | |
1349 | 1354 | | |
1350 | | - | |
| 1355 | + | |
| 1356 | + | |
| 1357 | + | |
| 1358 | + | |
1351 | 1359 | | |
1352 | 1360 | | |
1353 | 1361 | | |
| |||
1683 | 1691 | | |
1684 | 1692 | | |
1685 | 1693 | | |
1686 | | - | |
| 1694 | + | |
| 1695 | + | |
| 1696 | + | |
1687 | 1697 | | |
1688 | 1698 | | |
1689 | 1699 | | |
| |||
1738 | 1748 | | |
1739 | 1749 | | |
1740 | 1750 | | |
1741 | | - | |
| 1751 | + | |
1742 | 1752 | | |
1743 | 1753 | | |
1744 | 1754 | | |
| |||
1807 | 1817 | | |
1808 | 1818 | | |
1809 | 1819 | | |
1810 | | - | |
| 1820 | + | |
| 1821 | + | |
| 1822 | + | |
| 1823 | + | |
1811 | 1824 | | |
1812 | 1825 | | |
1813 | 1826 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
14 | 15 | | |
15 | 16 | | |
16 | 17 | | |
| |||
30 | 31 | | |
31 | 32 | | |
32 | 33 | | |
| 34 | + | |
33 | 35 | | |
34 | 36 | | |
35 | 37 | | |
| |||
49 | 51 | | |
50 | 52 | | |
51 | 53 | | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
| 114 | + | |
114 | 115 | | |
115 | | - | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
116 | 119 | | |
117 | 120 | | |
118 | 121 | | |
| |||
129 | 132 | | |
130 | 133 | | |
131 | 134 | | |
| 135 | + | |
| 136 | + | |
0 commit comments