| 1 | /* FIXME: CET arch_prctl bits should come from the kernel header files. |
| 2 | This file should be removed if <asm/prctl.h> from the required kernel |
| 3 | header files contains CET arch_prctl bits. */ |
| 4 | |
| 5 | #include_next <asm/prctl.h> |
| 6 | |
| 7 | #ifndef ARCH_CET_STATUS |
| 8 | /* CET features: |
| 9 | IBT: GNU_PROPERTY_X86_FEATURE_1_IBT |
| 10 | SHSTK: GNU_PROPERTY_X86_FEATURE_1_SHSTK |
| 11 | */ |
| 12 | /* Return CET features in unsigned long long *addr: |
| 13 | features: addr[0]. |
| 14 | shadow stack base address: addr[1]. |
| 15 | shadow stack size: addr[2]. |
| 16 | */ |
| 17 | # define ARCH_CET_STATUS 0x3001 |
| 18 | /* Disable CET features in unsigned int features. */ |
| 19 | # define ARCH_CET_DISABLE 0x3002 |
| 20 | /* Lock all CET features. */ |
| 21 | # define ARCH_CET_LOCK 0x3003 |
| 22 | /* Allocate a new shadow stack with unsigned long long *addr: |
| 23 | IN: requested shadow stack size: *addr. |
| 24 | OUT: allocated shadow stack address: *addr. |
| 25 | */ |
| 26 | # define ARCH_CET_ALLOC_SHSTK 0x3004 |
| 27 | #endif /* ARCH_CET_STATUS */ |
| 28 | |