1 /****************************************************************************
2  ****************************************************************************
3  ***
4  ***   This header was automatically generated from a Linux kernel header
5  ***   of the same name, to make information necessary for userspace to
6  ***   call into the kernel available to libc.  It contains only constants,
7  ***   structures, and macros generated from the original header, and thus,
8  ***   contains no copyrightable information.
9  ***
10  ***   To edit the content of this header, modify the corresponding
11  ***   source file (e.g. under external/kernel-headers/original/) then
12  ***   run bionic/libc/kernel/tools/update_all.py
13  ***
14  ***   Any manual change here will be lost the next time this script will
15  ***   be run. You've been warned!
16  ***
17  ****************************************************************************
18  ****************************************************************************/
19 #ifndef _UAPI_LINUX_ARM_SDEI_H
20 #define _UAPI_LINUX_ARM_SDEI_H
21 #define SDEI_1_0_FN_BASE 0xC4000020
22 #define SDEI_1_0_MASK 0xFFFFFFE0
23 #define SDEI_1_0_FN(n) (SDEI_1_0_FN_BASE + (n))
24 #define SDEI_1_0_FN_SDEI_VERSION SDEI_1_0_FN(0x00)
25 #define SDEI_1_0_FN_SDEI_EVENT_REGISTER SDEI_1_0_FN(0x01)
26 #define SDEI_1_0_FN_SDEI_EVENT_ENABLE SDEI_1_0_FN(0x02)
27 #define SDEI_1_0_FN_SDEI_EVENT_DISABLE SDEI_1_0_FN(0x03)
28 #define SDEI_1_0_FN_SDEI_EVENT_CONTEXT SDEI_1_0_FN(0x04)
29 #define SDEI_1_0_FN_SDEI_EVENT_COMPLETE SDEI_1_0_FN(0x05)
30 #define SDEI_1_0_FN_SDEI_EVENT_COMPLETE_AND_RESUME SDEI_1_0_FN(0x06)
31 #define SDEI_1_0_FN_SDEI_EVENT_UNREGISTER SDEI_1_0_FN(0x07)
32 #define SDEI_1_0_FN_SDEI_EVENT_STATUS SDEI_1_0_FN(0x08)
33 #define SDEI_1_0_FN_SDEI_EVENT_GET_INFO SDEI_1_0_FN(0x09)
34 #define SDEI_1_0_FN_SDEI_EVENT_ROUTING_SET SDEI_1_0_FN(0x0A)
35 #define SDEI_1_0_FN_SDEI_PE_MASK SDEI_1_0_FN(0x0B)
36 #define SDEI_1_0_FN_SDEI_PE_UNMASK SDEI_1_0_FN(0x0C)
37 #define SDEI_1_0_FN_SDEI_INTERRUPT_BIND SDEI_1_0_FN(0x0D)
38 #define SDEI_1_0_FN_SDEI_INTERRUPT_RELEASE SDEI_1_0_FN(0x0E)
39 #define SDEI_1_0_FN_SDEI_PRIVATE_RESET SDEI_1_0_FN(0x11)
40 #define SDEI_1_0_FN_SDEI_SHARED_RESET SDEI_1_0_FN(0x12)
41 #define SDEI_VERSION_MAJOR_SHIFT 48
42 #define SDEI_VERSION_MAJOR_MASK 0x7fff
43 #define SDEI_VERSION_MINOR_SHIFT 32
44 #define SDEI_VERSION_MINOR_MASK 0xffff
45 #define SDEI_VERSION_VENDOR_SHIFT 0
46 #define SDEI_VERSION_VENDOR_MASK 0xffffffff
47 #define SDEI_VERSION_MAJOR(x) (x >> SDEI_VERSION_MAJOR_SHIFT & SDEI_VERSION_MAJOR_MASK)
48 #define SDEI_VERSION_MINOR(x) (x >> SDEI_VERSION_MINOR_SHIFT & SDEI_VERSION_MINOR_MASK)
49 #define SDEI_VERSION_VENDOR(x) (x >> SDEI_VERSION_VENDOR_SHIFT & SDEI_VERSION_VENDOR_MASK)
50 #define SDEI_SUCCESS 0
51 #define SDEI_NOT_SUPPORTED - 1
52 #define SDEI_INVALID_PARAMETERS - 2
53 #define SDEI_DENIED - 3
54 #define SDEI_PENDING - 5
55 #define SDEI_OUT_OF_RESOURCE - 10
56 #define SDEI_EVENT_REGISTER_RM_ANY 0
57 #define SDEI_EVENT_REGISTER_RM_PE 1
58 #define SDEI_EVENT_STATUS_RUNNING 2
59 #define SDEI_EVENT_STATUS_ENABLED 1
60 #define SDEI_EVENT_STATUS_REGISTERED 0
61 #define SDEI_EV_HANDLED 0
62 #define SDEI_EV_FAILED 1
63 #define SDEI_EVENT_INFO_EV_TYPE 0
64 #define SDEI_EVENT_INFO_EV_SIGNALED 1
65 #define SDEI_EVENT_INFO_EV_PRIORITY 2
66 #define SDEI_EVENT_INFO_EV_ROUTING_MODE 3
67 #define SDEI_EVENT_INFO_EV_ROUTING_AFF 4
68 #define SDEI_EVENT_TYPE_PRIVATE 0
69 #define SDEI_EVENT_TYPE_SHARED 1
70 #define SDEI_EVENT_PRIORITY_NORMAL 0
71 #define SDEI_EVENT_PRIORITY_CRITICAL 1
72 #endif
73