1 #ifndef __ASM_OFFSETS_H__
2 #define __ASM_OFFSETS_H__
3 /*
4  * DO NOT MODIFY.
5  *
6  * This file was generated by Kbuild
7  */
8 
9 #define TSK_ACTIVE_MM 968 /* offsetof(struct task_struct, active_mm) */
10 
11 #define TSK_TI_CPU 16 /* offsetof(struct task_struct, thread_info.cpu) */
12 #define TSK_TI_FLAGS 0 /* offsetof(struct task_struct, thread_info.flags) */
13 #define TSK_TI_PREEMPT 8 /* offsetof(struct task_struct, thread_info.preempt_count) */
14 #define TSK_STACK 32 /* offsetof(struct task_struct, stack) */
15 #define TSK_STACK_CANARY 1152 /* offsetof(struct task_struct, stack_canary) */
16 
17 #define THREAD_CPU_CONTEXT 2464 /* offsetof(struct task_struct, thread.cpu_context) */
18 #define THREAD_SCTLR_USER 3536 /* offsetof(struct task_struct, thread.sctlr_user) */
19 #define THREAD_KEYS_USER 3432 /* offsetof(struct task_struct, thread.keys_user) */
20 #define THREAD_KEYS_KERNEL 3512 /* offsetof(struct task_struct, thread.keys_kernel) */
21 #define THREAD_MTE_CTRL 3528 /* offsetof(struct task_struct, thread.mte_ctrl) */
22 
23 #define S_X0 0 /* offsetof(struct pt_regs, regs[0]) */
24 #define S_X2 16 /* offsetof(struct pt_regs, regs[2]) */
25 #define S_X4 32 /* offsetof(struct pt_regs, regs[4]) */
26 #define S_X6 48 /* offsetof(struct pt_regs, regs[6]) */
27 #define S_X8 64 /* offsetof(struct pt_regs, regs[8]) */
28 #define S_X10 80 /* offsetof(struct pt_regs, regs[10]) */
29 #define S_X12 96 /* offsetof(struct pt_regs, regs[12]) */
30 #define S_X14 112 /* offsetof(struct pt_regs, regs[14]) */
31 #define S_X16 128 /* offsetof(struct pt_regs, regs[16]) */
32 #define S_X18 144 /* offsetof(struct pt_regs, regs[18]) */
33 #define S_X20 160 /* offsetof(struct pt_regs, regs[20]) */
34 #define S_X22 176 /* offsetof(struct pt_regs, regs[22]) */
35 #define S_X24 192 /* offsetof(struct pt_regs, regs[24]) */
36 #define S_X26 208 /* offsetof(struct pt_regs, regs[26]) */
37 #define S_X28 224 /* offsetof(struct pt_regs, regs[28]) */
38 #define S_FP 232 /* offsetof(struct pt_regs, regs[29]) */
39 #define S_LR 240 /* offsetof(struct pt_regs, regs[30]) */
40 #define S_SP 248 /* offsetof(struct pt_regs, sp) */
41 #define S_PSTATE 264 /* offsetof(struct pt_regs, pstate) */
42 #define S_PC 256 /* offsetof(struct pt_regs, pc) */
43 #define S_SYSCALLNO 280 /* offsetof(struct pt_regs, syscallno) */
44 #define S_SDEI_TTBR1 288 /* offsetof(struct pt_regs, sdei_ttbr1) */
45 #define S_PMR_SAVE 296 /* offsetof(struct pt_regs, pmr_save) */
46 #define S_STACKFRAME 304 /* offsetof(struct pt_regs, stackframe) */
47 #define PT_REGS_SIZE 336 /* sizeof(struct pt_regs) */
48 
49 #define COMPAT_SIGFRAME_REGS_OFFSET 32 /* offsetof(struct compat_sigframe, uc.uc_mcontext.arm_r0) */
50 #define COMPAT_RT_SIGFRAME_REGS_OFFSET 160 /* offsetof(struct compat_rt_sigframe, sig.uc.uc_mcontext.arm_r0) */
51 
52 #define MM_CONTEXT_ID 736 /* offsetof(struct mm_struct, context.id.counter) */
53 
54 #define VMA_VM_MM 64 /* offsetof(struct vm_area_struct, vm_mm) */
55 #define VMA_VM_FLAGS 80 /* offsetof(struct vm_area_struct, vm_flags) */
56 
57 #define VM_EXEC 4 /* VM_EXEC */
58 
59 #define PAGE_SZ 4096 /* PAGE_SIZE */
60 
61 #define DMA_TO_DEVICE 1 /* DMA_TO_DEVICE */
62 #define DMA_FROM_DEVICE 2 /* DMA_FROM_DEVICE */
63 
64 #define PREEMPT_DISABLE_OFFSET 1 /* PREEMPT_DISABLE_OFFSET */
65 #define SOFTIRQ_SHIFT 8 /* SOFTIRQ_SHIFT */
66 #define IRQ_CPUSTAT_SOFTIRQ_PENDING 0 /* offsetof(irq_cpustat_t, __softirq_pending) */
67 
68 #define CPU_BOOT_TASK 0 /* offsetof(struct secondary_data, task) */
69 
70 #define FTR_OVR_VAL_OFFSET 0 /* offsetof(struct arm64_ftr_override, val) */
71 #define FTR_OVR_MASK_OFFSET 8 /* offsetof(struct arm64_ftr_override, mask) */
72 
73 #define VCPU_CONTEXT 256 /* offsetof(struct kvm_vcpu, arch.ctxt) */
74 #define VCPU_FAULT_DISR 2160 /* offsetof(struct kvm_vcpu, arch.fault.disr_el1) */
75 #define VCPU_WORKAROUND_FLAGS 2168 /* offsetof(struct kvm_vcpu, arch.workaround_flags) */
76 #define VCPU_HCR_EL2 2104 /* offsetof(struct kvm_vcpu, arch.hcr_el2) */
77 #define CPU_USER_PT_REGS 0 /* offsetof(struct kvm_cpu_context, regs) */
78 #define CPU_RGSR_EL1 1744 /* offsetof(struct kvm_cpu_context, sys_regs[RGSR_EL1]) */
79 #define CPU_GCR_EL1 1752 /* offsetof(struct kvm_cpu_context, sys_regs[GCR_EL1]) */
80 #define CPU_APIAKEYLO_EL1 1600 /* offsetof(struct kvm_cpu_context, sys_regs[APIAKEYLO_EL1]) */
81 #define CPU_APIBKEYLO_EL1 1616 /* offsetof(struct kvm_cpu_context, sys_regs[APIBKEYLO_EL1]) */
82 #define CPU_APDAKEYLO_EL1 1632 /* offsetof(struct kvm_cpu_context, sys_regs[APDAKEYLO_EL1]) */
83 #define CPU_APDBKEYLO_EL1 1648 /* offsetof(struct kvm_cpu_context, sys_regs[APDBKEYLO_EL1]) */
84 #define CPU_APGAKEYLO_EL1 1664 /* offsetof(struct kvm_cpu_context, sys_regs[APGAKEYLO_EL1]) */
85 #define HOST_CONTEXT_VCPU 1808 /* offsetof(struct kvm_cpu_context, __hyp_running_vcpu) */
86 #define HOST_DATA_CONTEXT 0 /* offsetof(struct kvm_host_data, host_ctxt) */
87 #define NVHE_INIT_MAIR_EL2 0 /* offsetof(struct kvm_nvhe_init_params, mair_el2) */
88 #define NVHE_INIT_TCR_EL2 8 /* offsetof(struct kvm_nvhe_init_params, tcr_el2) */
89 #define NVHE_INIT_TPIDR_EL2 16 /* offsetof(struct kvm_nvhe_init_params, tpidr_el2) */
90 #define NVHE_INIT_STACK_HYP_VA 24 /* offsetof(struct kvm_nvhe_init_params, stack_hyp_va) */
91 #define NVHE_INIT_PGD_PA 32 /* offsetof(struct kvm_nvhe_init_params, pgd_pa) */
92 #define NVHE_INIT_HCR_EL2 40 /* offsetof(struct kvm_nvhe_init_params, hcr_el2) */
93 #define NVHE_INIT_VTTBR 48 /* offsetof(struct kvm_nvhe_init_params, vttbr) */
94 #define NVHE_INIT_VTCR 56 /* offsetof(struct kvm_nvhe_init_params, vtcr) */
95 #define CPU_CTX_SP 104 /* offsetof(struct cpu_suspend_ctx, sp) */
96 #define MPIDR_HASH_MASK 0 /* offsetof(struct mpidr_hash, mask) */
97 #define MPIDR_HASH_SHIFTS 8 /* offsetof(struct mpidr_hash, shift_aff) */
98 #define SLEEP_STACK_DATA_SYSTEM_REGS 0 /* offsetof(struct sleep_stack_data, system_regs) */
99 #define SLEEP_STACK_DATA_CALLEE_REGS 112 /* offsetof(struct sleep_stack_data, callee_saved_regs) */
100 #define ARM_SMCCC_RES_X0_OFFS 0 /* offsetof(struct arm_smccc_res, a0) */
101 #define ARM_SMCCC_RES_X2_OFFS 16 /* offsetof(struct arm_smccc_res, a2) */
102 #define ARM_SMCCC_QUIRK_ID_OFFS 0 /* offsetof(struct arm_smccc_quirk, id) */
103 #define ARM_SMCCC_QUIRK_STATE_OFFS 8 /* offsetof(struct arm_smccc_quirk, state) */
104 #define ARM_SMCCC_1_2_REGS_X0_OFFS 0 /* offsetof(struct arm_smccc_1_2_regs, a0) */
105 #define ARM_SMCCC_1_2_REGS_X2_OFFS 16 /* offsetof(struct arm_smccc_1_2_regs, a2) */
106 #define ARM_SMCCC_1_2_REGS_X4_OFFS 32 /* offsetof(struct arm_smccc_1_2_regs, a4) */
107 #define ARM_SMCCC_1_2_REGS_X6_OFFS 48 /* offsetof(struct arm_smccc_1_2_regs, a6) */
108 #define ARM_SMCCC_1_2_REGS_X8_OFFS 64 /* offsetof(struct arm_smccc_1_2_regs, a8) */
109 #define ARM_SMCCC_1_2_REGS_X10_OFFS 80 /* offsetof(struct arm_smccc_1_2_regs, a10) */
110 #define ARM_SMCCC_1_2_REGS_X12_OFFS 96 /* offsetof(struct arm_smccc_1_2_regs, a12) */
111 #define ARM_SMCCC_1_2_REGS_X14_OFFS 112 /* offsetof(struct arm_smccc_1_2_regs, a14) */
112 #define ARM_SMCCC_1_2_REGS_X16_OFFS 128 /* offsetof(struct arm_smccc_1_2_regs, a16) */
113 
114 #define HIBERN_PBE_ORIG 8 /* offsetof(struct pbe, orig_address) */
115 #define HIBERN_PBE_ADDR 0 /* offsetof(struct pbe, address) */
116 #define HIBERN_PBE_NEXT 16 /* offsetof(struct pbe, next) */
117 #define ARM64_FTR_SYSVAL 24 /* offsetof(struct arm64_ftr_reg, sys_val) */
118 
119 #define TRAMP_VALIAS -4398084284416 /* TRAMP_VALIAS */
120 #define PTRAUTH_USER_KEY_APIA 0 /* offsetof(struct ptrauth_keys_user, apia) */
121 #define PTRAUTH_KERNEL_KEY_APIA 0 /* offsetof(struct ptrauth_keys_kernel, apia) */
122 
123 #define KIMAGE_ARCH_DTB_MEM 648 /* offsetof(struct kimage, arch.dtb_mem) */
124 #define KIMAGE_ARCH_EL2_VECTORS 664 /* offsetof(struct kimage, arch.el2_vectors) */
125 #define KIMAGE_ARCH_ZERO_PAGE 688 /* offsetof(struct kimage, arch.zero_page) */
126 #define KIMAGE_ARCH_PHYS_OFFSET 696 /* offsetof(struct kimage, arch.phys_offset) */
127 #define KIMAGE_ARCH_TTBR1 680 /* offsetof(struct kimage, arch.ttbr1) */
128 #define KIMAGE_HEAD 0 /* offsetof(struct kimage, head) */
129 #define KIMAGE_START 24 /* offsetof(struct kimage, start) */
130 
131 
132 #endif
133