xref: /aosp_15_r20/bionic/libc/kernel/uapi/linux/patchkey.h (revision 8d67ca893c1523eb926b9080dbe4e2ffd2a27ba1)
1*8d67ca89SAndroid Build Coastguard Worker /*
2*8d67ca89SAndroid Build Coastguard Worker  * This file is auto-generated. Modifications will be lost.
3*8d67ca89SAndroid Build Coastguard Worker  *
4*8d67ca89SAndroid Build Coastguard Worker  * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/
5*8d67ca89SAndroid Build Coastguard Worker  * for more information.
6*8d67ca89SAndroid Build Coastguard Worker  */
7*8d67ca89SAndroid Build Coastguard Worker #ifndef _LINUX_PATCHKEY_H_INDIRECT
8*8d67ca89SAndroid Build Coastguard Worker #error "patchkey.h included directly"
9*8d67ca89SAndroid Build Coastguard Worker #endif
10*8d67ca89SAndroid Build Coastguard Worker #ifndef _UAPI_LINUX_PATCHKEY_H
11*8d67ca89SAndroid Build Coastguard Worker #define _UAPI_LINUX_PATCHKEY_H
12*8d67ca89SAndroid Build Coastguard Worker #include <endian.h>
13*8d67ca89SAndroid Build Coastguard Worker #ifdef __BYTE_ORDER
14*8d67ca89SAndroid Build Coastguard Worker #if __BYTE_ORDER == __BIG_ENDIAN
15*8d67ca89SAndroid Build Coastguard Worker #define _PATCHKEY(id) (0xfd00 | id)
16*8d67ca89SAndroid Build Coastguard Worker #elif __BYTE_ORDER==__LITTLE_ENDIAN
17*8d67ca89SAndroid Build Coastguard Worker #define _PATCHKEY(id) ((id << 8) | 0x00fd)
18*8d67ca89SAndroid Build Coastguard Worker #else
19*8d67ca89SAndroid Build Coastguard Worker #error "could not determine byte order"
20*8d67ca89SAndroid Build Coastguard Worker #endif
21*8d67ca89SAndroid Build Coastguard Worker #endif
22*8d67ca89SAndroid Build Coastguard Worker #endif
23