|
1 | 1 | # ARM Cortex-M platform configuration options
|
2 | 2 |
|
3 | 3 | # Copyright (c) 2014-2015 Wind River Systems, Inc.
|
| 4 | +# Copyright 2025 Arm Limited and/or its affiliates <open-source-office@arm.com> |
4 | 5 | # SPDX-License-Identifier: Apache-2.0
|
5 | 6 |
|
6 | 7 | # NOTE: We have the specific core implementations first and outside of the
|
@@ -298,6 +299,60 @@ config ARMV8_1_M_PMU
|
298 | 299 | This option is enabled when the CPU implements ARMv8-M Performance
|
299 | 300 | Monitoring Unit (PMU).
|
300 | 301 |
|
| 302 | +choice ARMV8_1_M_PACBTI |
| 303 | + prompt "Pointer Authentication and Branch Target Identification" |
| 304 | + default ARMV8_1_M_PACBTI_NONE |
| 305 | + depends on ARMV8_1_M_MAINLINE |
| 306 | + |
| 307 | +config ARMV8_1_M_PACBTI_STANDARD |
| 308 | + bool "Standard (PACRET + LEAF + BTI)" |
| 309 | + help |
| 310 | + This option instructs the compiler to generate code with all branch protection features |
| 311 | + enabled at their standard level. |
| 312 | + |
| 313 | +config ARMV8_1_M_PACBTI_PACRET |
| 314 | + bool "PACRET only" |
| 315 | + help |
| 316 | + This option instructs the compiler to generate code with return address signing for |
| 317 | + all functions that save the return address to memory. |
| 318 | + |
| 319 | +config ARMV8_1_M_PACBTI_PACRET_LEAF |
| 320 | + bool "PACRET + Leaf" |
| 321 | + help |
| 322 | + This option instructs the compiler to generate code with return address signing for |
| 323 | + all functions that save the return address to memory and, |
| 324 | + also sign leaf functions even if they do not write the return address to memory. |
| 325 | + |
| 326 | +config ARMV8_1_M_PACBTI_BTI |
| 327 | + bool "BTI only" |
| 328 | + help |
| 329 | + This option enables Branch Target Identification (BTI), which inserts special landing |
| 330 | + pad instructions at valid indirect branch targets. This option does not enable Pointer |
| 331 | + Authentication (PAC). |
| 332 | + |
| 333 | +config ARMV8_1_M_PACBTI_PACRET_BTI |
| 334 | + bool "PACRET + BTI" |
| 335 | + help |
| 336 | + This option instructs the compiler to generate code with return address signing for |
| 337 | + all functions that save the return address to memory and, |
| 338 | + add landing-pad instructions at the permitted targets of indirect branch instructions |
| 339 | + |
| 340 | +config ARMV8_1_M_PACBTI_PACRET_LEAF_BTI |
| 341 | + bool "PACRET + Leaf + BTI" |
| 342 | + help |
| 343 | + This option instructs the compiler to generate code with return address signing for |
| 344 | + all functions that save the return address to memory and, |
| 345 | + also sign leaf functions even if they do not write the return address to memory and, |
| 346 | + add landing-pad instructions at the permitted targets of indirect branch instructions |
| 347 | + |
| 348 | +config ARMV8_1_M_PACBTI_NONE |
| 349 | + bool "None" |
| 350 | + help |
| 351 | + This option instructs the compiler to generate code without branch protection or return |
| 352 | + address signing |
| 353 | + |
| 354 | +endchoice |
| 355 | + |
301 | 356 | config ARMV8_M_PMU_EVENTCNT
|
302 | 357 | int "Number of event counters in the Performance Monitoring Unit"
|
303 | 358 | depends on ARMV8_1_M_PMU
|
|
0 commit comments