| 1 |
// SPDX-License-Identifier: GPL-2.0-or-later |
| 2 |
/* |
| 3 |
* Generate definitions needed by assembly language modules. |
| 4 |
* This code generates raw asm output which is post-processed to extract |
| 5 |
* and format the required data. |
| 6 |
* |
| 7 |
* Copyright (C) 2000-2001 John Marvin <jsm at parisc-linux.org> |
| 8 |
* Copyright (C) 2000 David Huggins-Daines <dhd with pobox.org> |
| 9 |
* Copyright (C) 2000 Sam Creasey <[email protected]> |
| 10 |
* Copyright (C) 2000 Grant Grundler <grundler with parisc-linux.org> |
| 11 |
* Copyright (C) 2001 Paul Bame <bame at parisc-linux.org> |
| 12 |
* Copyright (C) 2001 Richard Hirst <rhirst at parisc-linux.org> |
| 13 |
* Copyright (C) 2002 Randolph Chung <tausq with parisc-linux.org> |
| 14 |
* Copyright (C) 2003 James Bottomley <jejb at parisc-linux.org> |
| 15 |
*/ |
| 16 |
#define COMPILE_OFFSETS |
| 17 |
|
| 18 |
#include <linux/types.h> |
| 19 |
#include <linux/sched.h> |
| 20 |
#include <linux/thread_info.h> |
| 21 |
#include <linux/ptrace.h> |
| 22 |
#include <linux/hardirq.h> |
| 23 |
#include <linux/kbuild.h> |
| 24 |
#include <linux/pgtable.h> |
| 25 |
|
| 26 |
#include <asm/assembly.h> |
| 27 |
#include <asm/ptrace.h> |
| 28 |
#include <asm/processor.h> |
| 29 |
#include <asm/pdc.h> |
| 30 |
#include <uapi/asm/sigcontext.h> |
| 31 |
#include <asm/ucontext.h> |
| 32 |
#include <asm/rt_sigframe.h> |
| 33 |
#include <linux/uaccess.h> |
| 34 |
#include "signal32.h" |
| 35 |
|
| 36 |
/* Add FRAME_SIZE to the size x and align it to y. All definitions |
| 37 |
* that use align_frame will include space for a frame. |
| 38 |
*/ |
| 39 |
#define align_frame(x,y) (((x)+FRAME_SIZE+(y)-1) - (((x)+(y)-1)%(y))) |
| 40 |
|
| 41 |
int main(void) |
| 42 |
{ |
| 43 |
DEFINE(TASK_TI_FLAGS, offsetof(struct task_struct, thread_info.flags)); |
| 44 |
#ifdef CONFIG_SMP |
| 45 |
DEFINE(TASK_TI_CPU, offsetof(struct task_struct, thread_info.cpu)); |
| 46 |
#endif |
| 47 |
DEFINE(TASK_STACK, offsetof(struct task_struct, stack)); |
| 48 |
DEFINE(TASK_PAGEFAULT_DISABLED, offsetof(struct task_struct, pagefault_disabled)); |
| 49 |
BLANK(); |
| 50 |
DEFINE(TASK_REGS, offsetof(struct task_struct, thread.regs)); |
| 51 |
DEFINE(TASK_PT_PSW, offsetof(struct task_struct, thread.regs.gr[ 0])); |
| 52 |
DEFINE(TASK_PT_GR1, offsetof(struct task_struct, thread.regs.gr[ 1])); |
| 53 |
DEFINE(TASK_PT_GR2, offsetof(struct task_struct, thread.regs.gr[ 2])); |
| 54 |
DEFINE(TASK_PT_GR3, offsetof(struct task_struct, thread.regs.gr[ 3])); |
| 55 |
DEFINE(TASK_PT_GR4, offsetof(struct task_struct, thread.regs.gr[ 4])); |
| 56 |
DEFINE(TASK_PT_GR5, offsetof(struct task_struct, thread.regs.gr[ 5])); |
| 57 |
DEFINE(TASK_PT_GR6, offsetof(struct task_struct, thread.regs.gr[ 6])); |
| 58 |
DEFINE(TASK_PT_GR7, offsetof(struct task_struct, thread.regs.gr[ 7])); |
| 59 |
DEFINE(TASK_PT_GR8, offsetof(struct task_struct, thread.regs.gr[ 8])); |
| 60 |
DEFINE(TASK_PT_GR9, offsetof(struct task_struct, thread.regs.gr[ 9])); |
| 61 |
DEFINE(TASK_PT_GR10, offsetof(struct task_struct, thread.regs.gr[10])); |
| 62 |
DEFINE(TASK_PT_GR11, offsetof(struct task_struct, thread.regs.gr[11])); |
| 63 |
DEFINE(TASK_PT_GR12, offsetof(struct task_struct, thread.regs.gr[12])); |
| 64 |
DEFINE(TASK_PT_GR13, offsetof(struct task_struct, thread.regs.gr[13])); |
| 65 |
DEFINE(TASK_PT_GR14, offsetof(struct task_struct, thread.regs.gr[14])); |
| 66 |
DEFINE(TASK_PT_GR15, offsetof(struct task_struct, thread.regs.gr[15])); |
| 67 |
DEFINE(TASK_PT_GR16, offsetof(struct task_struct, thread.regs.gr[16])); |
| 68 |
DEFINE(TASK_PT_GR17, offsetof(struct task_struct, thread.regs.gr[17])); |
| 69 |
DEFINE(TASK_PT_GR18, offsetof(struct task_struct, thread.regs.gr[18])); |
| 70 |
DEFINE(TASK_PT_GR19, offsetof(struct task_struct, thread.regs.gr[19])); |
| 71 |
DEFINE(TASK_PT_GR20, offsetof(struct task_struct, thread.regs.gr[20])); |
| 72 |
DEFINE(TASK_PT_GR21, offsetof(struct task_struct, thread.regs.gr[21])); |
| 73 |
DEFINE(TASK_PT_GR22, offsetof(struct task_struct, thread.regs.gr[22])); |
| 74 |
DEFINE(TASK_PT_GR23, offsetof(struct task_struct, thread.regs.gr[23])); |
| 75 |
DEFINE(TASK_PT_GR24, offsetof(struct task_struct, thread.regs.gr[24])); |
| 76 |
DEFINE(TASK_PT_GR25, offsetof(struct task_struct, thread.regs.gr[25])); |
| 77 |
DEFINE(TASK_PT_GR26, offsetof(struct task_struct, thread.regs.gr[26])); |
| 78 |
DEFINE(TASK_PT_GR27, offsetof(struct task_struct, thread.regs.gr[27])); |
| 79 |
DEFINE(TASK_PT_GR28, offsetof(struct task_struct, thread.regs.gr[28])); |
| 80 |
DEFINE(TASK_PT_GR29, offsetof(struct task_struct, thread.regs.gr[29])); |
| 81 |
DEFINE(TASK_PT_GR30, offsetof(struct task_struct, thread.regs.gr[30])); |
| 82 |
DEFINE(TASK_PT_GR31, offsetof(struct task_struct, thread.regs.gr[31])); |
| 83 |
DEFINE(TASK_PT_FR0, offsetof(struct task_struct, thread.regs.fr[ 0])); |
| 84 |
DEFINE(TASK_PT_FR1, offsetof(struct task_struct, thread.regs.fr[ 1])); |
| 85 |
DEFINE(TASK_PT_FR2, offsetof(struct task_struct, thread.regs.fr[ 2])); |
| 86 |
DEFINE(TASK_PT_FR3, offsetof(struct task_struct, thread.regs.fr[ 3])); |
| 87 |
DEFINE(TASK_PT_FR4, offsetof(struct task_struct, thread.regs.fr[ 4])); |
| 88 |
DEFINE(TASK_PT_FR5, offsetof(struct task_struct, thread.regs.fr[ 5])); |
| 89 |
DEFINE(TASK_PT_FR6, offsetof(struct task_struct, thread.regs.fr[ 6])); |
| 90 |
DEFINE(TASK_PT_FR7, offsetof(struct task_struct, thread.regs.fr[ 7])); |
| 91 |
DEFINE(TASK_PT_FR8, offsetof(struct task_struct, thread.regs.fr[ 8])); |
| 92 |
DEFINE(TASK_PT_FR9, offsetof(struct task_struct, thread.regs.fr[ 9])); |
| 93 |
DEFINE(TASK_PT_FR10, offsetof(struct task_struct, thread.regs.fr[10])); |
| 94 |
DEFINE(TASK_PT_FR11, offsetof(struct task_struct, thread.regs.fr[11])); |
| 95 |
DEFINE(TASK_PT_FR12, offsetof(struct task_struct, thread.regs.fr[12])); |
| 96 |
DEFINE(TASK_PT_FR13, offsetof(struct task_struct, thread.regs.fr[13])); |
| 97 |
DEFINE(TASK_PT_FR14, offsetof(struct task_struct, thread.regs.fr[14])); |
| 98 |
DEFINE(TASK_PT_FR15, offsetof(struct task_struct, thread.regs.fr[15])); |
| 99 |
DEFINE(TASK_PT_FR16, offsetof(struct task_struct, thread.regs.fr[16])); |
| 100 |
DEFINE(TASK_PT_FR17, offsetof(struct task_struct, thread.regs.fr[17])); |
| 101 |
DEFINE(TASK_PT_FR18, offsetof(struct task_struct, thread.regs.fr[18])); |
| 102 |
DEFINE(TASK_PT_FR19, offsetof(struct task_struct, thread.regs.fr[19])); |
| 103 |
DEFINE(TASK_PT_FR20, offsetof(struct task_struct, thread.regs.fr[20])); |
| 104 |
DEFINE(TASK_PT_FR21, offsetof(struct task_struct, thread.regs.fr[21])); |
| 105 |
DEFINE(TASK_PT_FR22, offsetof(struct task_struct, thread.regs.fr[22])); |
| 106 |
DEFINE(TASK_PT_FR23, offsetof(struct task_struct, thread.regs.fr[23])); |
| 107 |
DEFINE(TASK_PT_FR24, offsetof(struct task_struct, thread.regs.fr[24])); |
| 108 |
DEFINE(TASK_PT_FR25, offsetof(struct task_struct, thread.regs.fr[25])); |
| 109 |
DEFINE(TASK_PT_FR26, offsetof(struct task_struct, thread.regs.fr[26])); |
| 110 |
DEFINE(TASK_PT_FR27, offsetof(struct task_struct, thread.regs.fr[27])); |
| 111 |
DEFINE(TASK_PT_FR28, offsetof(struct task_struct, thread.regs.fr[28])); |
| 112 |
DEFINE(TASK_PT_FR29, offsetof(struct task_struct, thread.regs.fr[29])); |
| 113 |
DEFINE(TASK_PT_FR30, offsetof(struct task_struct, thread.regs.fr[30])); |
| 114 |
DEFINE(TASK_PT_FR31, offsetof(struct task_struct, thread.regs.fr[31])); |
| 115 |
DEFINE(TASK_PT_SR0, offsetof(struct task_struct, thread.regs.sr[ 0])); |
| 116 |
DEFINE(TASK_PT_SR1, offsetof(struct task_struct, thread.regs.sr[ 1])); |
| 117 |
DEFINE(TASK_PT_SR2, offsetof(struct task_struct, thread.regs.sr[ 2])); |
| 118 |
DEFINE(TASK_PT_SR3, offsetof(struct task_struct, thread.regs.sr[ 3])); |
| 119 |
DEFINE(TASK_PT_SR4, offsetof(struct task_struct, thread.regs.sr[ 4])); |
| 120 |
DEFINE(TASK_PT_SR5, offsetof(struct task_struct, thread.regs.sr[ 5])); |
| 121 |
DEFINE(TASK_PT_SR6, offsetof(struct task_struct, thread.regs.sr[ 6])); |
| 122 |
DEFINE(TASK_PT_SR7, offsetof(struct task_struct, thread.regs.sr[ 7])); |
| 123 |
DEFINE(TASK_PT_IASQ0, offsetof(struct task_struct, thread.regs.iasq[0])); |
| 124 |
DEFINE(TASK_PT_IASQ1, offsetof(struct task_struct, thread.regs.iasq[1])); |
| 125 |
DEFINE(TASK_PT_IAOQ0, offsetof(struct task_struct, thread.regs.iaoq[0])); |
| 126 |
DEFINE(TASK_PT_IAOQ1, offsetof(struct task_struct, thread.regs.iaoq[1])); |
| 127 |
DEFINE(TASK_PT_CR27, offsetof(struct task_struct, thread.regs.cr27)); |
| 128 |
DEFINE(TASK_PT_ORIG_R28, offsetof(struct task_struct, thread.regs.orig_r28)); |
| 129 |
DEFINE(TASK_PT_KSP, offsetof(struct task_struct, thread.regs.ksp)); |
| 130 |
DEFINE(TASK_PT_KPC, offsetof(struct task_struct, thread.regs.kpc)); |
| 131 |
DEFINE(TASK_PT_SAR, offsetof(struct task_struct, thread.regs.sar)); |
| 132 |
DEFINE(TASK_PT_IIR, offsetof(struct task_struct, thread.regs.iir)); |
| 133 |
DEFINE(TASK_PT_ISR, offsetof(struct task_struct, thread.regs.isr)); |
| 134 |
DEFINE(TASK_PT_IOR, offsetof(struct task_struct, thread.regs.ior)); |
| 135 |
BLANK(); |
| 136 |
DEFINE(PT_PSW, offsetof(struct pt_regs, gr[ 0])); |
| 137 |
DEFINE(PT_GR1, offsetof(struct pt_regs, gr[ 1])); |
| 138 |
DEFINE(PT_GR2, offsetof(struct pt_regs, gr[ 2])); |
| 139 |
DEFINE(PT_GR3, offsetof(struct pt_regs, gr[ 3])); |
| 140 |
DEFINE(PT_GR4, offsetof(struct pt_regs, gr[ 4])); |
| 141 |
DEFINE(PT_GR5, offsetof(struct pt_regs, gr[ 5])); |
| 142 |
DEFINE(PT_GR6, offsetof(struct pt_regs, gr[ 6])); |
| 143 |
DEFINE(PT_GR7, offsetof(struct pt_regs, gr[ 7])); |
| 144 |
DEFINE(PT_GR8, offsetof(struct pt_regs, gr[ 8])); |
| 145 |
DEFINE(PT_GR9, offsetof(struct pt_regs, gr[ 9])); |
| 146 |
DEFINE(PT_GR10, offsetof(struct pt_regs, gr[10])); |
| 147 |
DEFINE(PT_GR11, offsetof(struct pt_regs, gr[11])); |
| 148 |
DEFINE(PT_GR12, offsetof(struct pt_regs, gr[12])); |
| 149 |
DEFINE(PT_GR13, offsetof(struct pt_regs, gr[13])); |
| 150 |
DEFINE(PT_GR14, offsetof(struct pt_regs, gr[14])); |
| 151 |
DEFINE(PT_GR15, offsetof(struct pt_regs, gr[15])); |
| 152 |
DEFINE(PT_GR16, offsetof(struct pt_regs, gr[16])); |
| 153 |
DEFINE(PT_GR17, offsetof(struct pt_regs, gr[17])); |
| 154 |
DEFINE(PT_GR18, offsetof(struct pt_regs, gr[18])); |
| 155 |
DEFINE(PT_GR19, offsetof(struct pt_regs, gr[19])); |
| 156 |
DEFINE(PT_GR20, offsetof(struct pt_regs, gr[20])); |
| 157 |
DEFINE(PT_GR21, offsetof(struct pt_regs, gr[21])); |
| 158 |
DEFINE(PT_GR22, offsetof(struct pt_regs, gr[22])); |
| 159 |
DEFINE(PT_GR23, offsetof(struct pt_regs, gr[23])); |
| 160 |
DEFINE(PT_GR24, offsetof(struct pt_regs, gr[24])); |
| 161 |
DEFINE(PT_GR25, offsetof(struct pt_regs, gr[25])); |
| 162 |
DEFINE(PT_GR26, offsetof(struct pt_regs, gr[26])); |
| 163 |
DEFINE(PT_GR27, offsetof(struct pt_regs, gr[27])); |
| 164 |
DEFINE(PT_GR28, offsetof(struct pt_regs, gr[28])); |
| 165 |
DEFINE(PT_GR29, offsetof(struct pt_regs, gr[29])); |
| 166 |
DEFINE(PT_GR30, offsetof(struct pt_regs, gr[30])); |
| 167 |
DEFINE(PT_GR31, offsetof(struct pt_regs, gr[31])); |
| 168 |
DEFINE(PT_FR0, offsetof(struct pt_regs, fr[ 0])); |
| 169 |
DEFINE(PT_FR1, offsetof(struct pt_regs, fr[ 1])); |
| 170 |
DEFINE(PT_FR2, offsetof(struct pt_regs, fr[ 2])); |
| 171 |
DEFINE(PT_FR3, offsetof(struct pt_regs, fr[ 3])); |
| 172 |
DEFINE(PT_FR4, offsetof(struct pt_regs, fr[ 4])); |
| 173 |
DEFINE(PT_FR5, offsetof(struct pt_regs, fr[ 5])); |
| 174 |
DEFINE(PT_FR6, offsetof(struct pt_regs, fr[ 6])); |
| 175 |
DEFINE(PT_FR7, offsetof(struct pt_regs, fr[ 7])); |
| 176 |
DEFINE(PT_FR8, offsetof(struct pt_regs, fr[ 8])); |
| 177 |
DEFINE(PT_FR9, offsetof(struct pt_regs, fr[ 9])); |
| 178 |
DEFINE(PT_FR10, offsetof(struct pt_regs, fr[10])); |
| 179 |
DEFINE(PT_FR11, offsetof(struct pt_regs, fr[11])); |
| 180 |
DEFINE(PT_FR12, offsetof(struct pt_regs, fr[12])); |
| 181 |
DEFINE(PT_FR13, offsetof(struct pt_regs, fr[13])); |
| 182 |
DEFINE(PT_FR14, offsetof(struct pt_regs, fr[14])); |
| 183 |
DEFINE(PT_FR15, offsetof(struct pt_regs, fr[15])); |
| 184 |
DEFINE(PT_FR16, offsetof(struct pt_regs, fr[16])); |
| 185 |
DEFINE(PT_FR17, offsetof(struct pt_regs, fr[17])); |
| 186 |
DEFINE(PT_FR18, offsetof(struct pt_regs, fr[18])); |
| 187 |
DEFINE(PT_FR19, offsetof(struct pt_regs, fr[19])); |
| 188 |
DEFINE(PT_FR20, offsetof(struct pt_regs, fr[20])); |
| 189 |
DEFINE(PT_FR21, offsetof(struct pt_regs, fr[21])); |
| 190 |
DEFINE(PT_FR22, offsetof(struct pt_regs, fr[22])); |
| 191 |
DEFINE(PT_FR23, offsetof(struct pt_regs, fr[23])); |
| 192 |
DEFINE(PT_FR24, offsetof(struct pt_regs, fr[24])); |
| 193 |
DEFINE(PT_FR25, offsetof(struct pt_regs, fr[25])); |
| 194 |
DEFINE(PT_FR26, offsetof(struct pt_regs, fr[26])); |
| 195 |
DEFINE(PT_FR27, offsetof(struct pt_regs, fr[27])); |
| 196 |
DEFINE(PT_FR28, offsetof(struct pt_regs, fr[28])); |
| 197 |
DEFINE(PT_FR29, offsetof(struct pt_regs, fr[29])); |
| 198 |
DEFINE(PT_FR30, offsetof(struct pt_regs, fr[30])); |
| 199 |
DEFINE(PT_FR31, offsetof(struct pt_regs, fr[31])); |
| 200 |
DEFINE(PT_SR0, offsetof(struct pt_regs, sr[ 0])); |
| 201 |
DEFINE(PT_SR1, offsetof(struct pt_regs, sr[ 1])); |
| 202 |
DEFINE(PT_SR2, offsetof(struct pt_regs, sr[ 2])); |
| 203 |
DEFINE(PT_SR3, offsetof(struct pt_regs, sr[ 3])); |
| 204 |
DEFINE(PT_SR4, offsetof(struct pt_regs, sr[ 4])); |
| 205 |
DEFINE(PT_SR5, offsetof(struct pt_regs, sr[ 5])); |
| 206 |
DEFINE(PT_SR6, offsetof(struct pt_regs, sr[ 6])); |
| 207 |
DEFINE(PT_SR7, offsetof(struct pt_regs, sr[ 7])); |
| 208 |
DEFINE(PT_IASQ0, offsetof(struct pt_regs, iasq[0])); |
| 209 |
DEFINE(PT_IASQ1, offsetof(struct pt_regs, iasq[1])); |
| 210 |
DEFINE(PT_IAOQ0, offsetof(struct pt_regs, iaoq[0])); |
| 211 |
DEFINE(PT_IAOQ1, offsetof(struct pt_regs, iaoq[1])); |
| 212 |
DEFINE(PT_CR27, offsetof(struct pt_regs, cr27)); |
| 213 |
DEFINE(PT_ORIG_R28, offsetof(struct pt_regs, orig_r28)); |
| 214 |
DEFINE(PT_KSP, offsetof(struct pt_regs, ksp)); |
| 215 |
DEFINE(PT_KPC, offsetof(struct pt_regs, kpc)); |
| 216 |
DEFINE(PT_SAR, offsetof(struct pt_regs, sar)); |
| 217 |
DEFINE(PT_IIR, offsetof(struct pt_regs, iir)); |
| 218 |
DEFINE(PT_ISR, offsetof(struct pt_regs, isr)); |
| 219 |
DEFINE(PT_IOR, offsetof(struct pt_regs, ior)); |
| 220 |
/* PT_SZ_ALGN includes space for a stack frame. */ |
| 221 |
DEFINE(PT_SZ_ALGN, align_frame(sizeof(struct pt_regs), FRAME_ALIGN)); |
| 222 |
BLANK(); |
| 223 |
DEFINE(TI_FLAGS, offsetof(struct thread_info, flags)); |
| 224 |
DEFINE(TI_PRE_COUNT, offsetof(struct task_struct, thread_info.preempt_count)); |
| 225 |
BLANK(); |
| 226 |
DEFINE(ASM_SIGFRAME_SIZE, PARISC_RT_SIGFRAME_SIZE); |
| 227 |
DEFINE(SIGFRAME_CONTEXT_REGS, offsetof(struct rt_sigframe, uc.uc_mcontext) - PARISC_RT_SIGFRAME_SIZE); |
| 228 |
#ifdef CONFIG_64BIT |
| 229 |
DEFINE(ASM_SIGFRAME_SIZE32, PARISC_RT_SIGFRAME_SIZE32); |
| 230 |
DEFINE(SIGFRAME_CONTEXT_REGS32, offsetof(struct compat_rt_sigframe, uc.uc_mcontext) - PARISC_RT_SIGFRAME_SIZE32); |
| 231 |
#else |
| 232 |
DEFINE(ASM_SIGFRAME_SIZE32, PARISC_RT_SIGFRAME_SIZE); |
| 233 |
DEFINE(SIGFRAME_CONTEXT_REGS32, offsetof(struct rt_sigframe, uc.uc_mcontext) - PARISC_RT_SIGFRAME_SIZE); |
| 234 |
#endif |
| 235 |
BLANK(); |
| 236 |
DEFINE(ICACHE_BASE, offsetof(struct pdc_cache_info, ic_base)); |
| 237 |
DEFINE(ICACHE_STRIDE, offsetof(struct pdc_cache_info, ic_stride)); |
| 238 |
DEFINE(ICACHE_COUNT, offsetof(struct pdc_cache_info, ic_count)); |
| 239 |
DEFINE(ICACHE_LOOP, offsetof(struct pdc_cache_info, ic_loop)); |
| 240 |
DEFINE(DCACHE_BASE, offsetof(struct pdc_cache_info, dc_base)); |
| 241 |
DEFINE(DCACHE_STRIDE, offsetof(struct pdc_cache_info, dc_stride)); |
| 242 |
DEFINE(DCACHE_COUNT, offsetof(struct pdc_cache_info, dc_count)); |
| 243 |
DEFINE(DCACHE_LOOP, offsetof(struct pdc_cache_info, dc_loop)); |
| 244 |
DEFINE(ITLB_SID_BASE, offsetof(struct pdc_cache_info, it_sp_base)); |
| 245 |
DEFINE(ITLB_SID_STRIDE, offsetof(struct pdc_cache_info, it_sp_stride)); |
| 246 |
DEFINE(ITLB_SID_COUNT, offsetof(struct pdc_cache_info, it_sp_count)); |
| 247 |
DEFINE(ITLB_OFF_BASE, offsetof(struct pdc_cache_info, it_off_base)); |
| 248 |
DEFINE(ITLB_OFF_STRIDE, offsetof(struct pdc_cache_info, it_off_stride)); |
| 249 |
DEFINE(ITLB_OFF_COUNT, offsetof(struct pdc_cache_info, it_off_count)); |
| 250 |
DEFINE(ITLB_LOOP, offsetof(struct pdc_cache_info, it_loop)); |
| 251 |
DEFINE(DTLB_SID_BASE, offsetof(struct pdc_cache_info, dt_sp_base)); |
| 252 |
DEFINE(DTLB_SID_STRIDE, offsetof(struct pdc_cache_info, dt_sp_stride)); |
| 253 |
DEFINE(DTLB_SID_COUNT, offsetof(struct pdc_cache_info, dt_sp_count)); |
| 254 |
DEFINE(DTLB_OFF_BASE, offsetof(struct pdc_cache_info, dt_off_base)); |
| 255 |
DEFINE(DTLB_OFF_STRIDE, offsetof(struct pdc_cache_info, dt_off_stride)); |
| 256 |
DEFINE(DTLB_OFF_COUNT, offsetof(struct pdc_cache_info, dt_off_count)); |
| 257 |
DEFINE(DTLB_LOOP, offsetof(struct pdc_cache_info, dt_loop)); |
| 258 |
BLANK(); |
| 259 |
DEFINE(TIF_BLOCKSTEP_PA_BIT, 31-TIF_BLOCKSTEP); |
| 260 |
DEFINE(TIF_SINGLESTEP_PA_BIT, 31-TIF_SINGLESTEP); |
| 261 |
DEFINE(TIF_32BIT_PA_BIT, 31-TIF_32BIT); |
| 262 |
|
| 263 |
BLANK(); |
| 264 |
DEFINE(ASM_PMD_SHIFT, PMD_SHIFT); |
| 265 |
DEFINE(ASM_PGDIR_SHIFT, PGDIR_SHIFT); |
| 266 |
DEFINE(ASM_BITS_PER_PGD, BITS_PER_PGD); |
| 267 |
DEFINE(ASM_BITS_PER_PMD, BITS_PER_PMD); |
| 268 |
DEFINE(ASM_BITS_PER_PTE, BITS_PER_PTE); |
| 269 |
DEFINE(ASM_PMD_ENTRY, ((PAGE_OFFSET & PMD_MASK) >> PMD_SHIFT)); |
| 270 |
DEFINE(ASM_PGD_ENTRY, PAGE_OFFSET >> PGDIR_SHIFT); |
| 271 |
DEFINE(ASM_PGD_ENTRY_SIZE, PGD_ENTRY_SIZE); |
| 272 |
DEFINE(ASM_PMD_ENTRY_SIZE, PMD_ENTRY_SIZE); |
| 273 |
DEFINE(ASM_PTE_ENTRY_SIZE, PTE_ENTRY_SIZE); |
| 274 |
DEFINE(ASM_PFN_PTE_SHIFT, PFN_PTE_SHIFT); |
| 275 |
DEFINE(ASM_PT_INITIAL, PT_INITIAL); |
| 276 |
BLANK(); |
| 277 |
/* HUGEPAGE_SIZE is only used in vmlinux.lds.S to align kernel text |
| 278 |
* and kernel data on physical huge pages */ |
| 279 |
#ifdef CONFIG_HUGETLB_PAGE |
| 280 |
DEFINE(HUGEPAGE_SIZE, 1UL << REAL_HPAGE_SHIFT); |
| 281 |
#elif !defined(CONFIG_64BIT) |
| 282 |
DEFINE(HUGEPAGE_SIZE, 4*1024*1024); |
| 283 |
#else |
| 284 |
DEFINE(HUGEPAGE_SIZE, PAGE_SIZE); |
| 285 |
#endif |
| 286 |
BLANK(); |
| 287 |
DEFINE(ASM_PDC_RESULT_SIZE, NUM_PDC_RESULT * sizeof(unsigned long)); |
| 288 |
BLANK(); |
| 289 |
return 0; |
| 290 |
} |