1\ 2\ CDDL HEADER START 3\ 4\ The contents of this file are subject to the terms of the 5\ Common Development and Distribution License (the "License"). 6\ You may not use this file except in compliance with the License. 7\ 8\ You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9\ or http://www.opensolaris.org/os/licensing. 10\ See the License for the specific language governing permissions 11\ and limitations under the License. 12\ 13\ When distributing Covered Code, include this CDDL HEADER in each 14\ file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15\ If applicable, add the following below this CDDL HEADER, with the 16\ fields enclosed by brackets "[]" replaced with your own identifying 17\ information: Portions Copyright [yyyy] [name of copyright owner] 18\ 19\ CDDL HEADER END 20\ 21\ Copyright 2006 Sun Microsystems, Inc. All rights reserved. 22\ Use is subject to license terms. 23\ 24\ offsets.in: input file to produce assym.h using the stabs program 25\ 26\ 27\ Guidelines: 28\ 29\ A blank line is required between structure/union/intrinsic names. 30\ 31\ The general form is: 32\ 33\ name size_define [shift_define] 34\ [member_name [offset_define]] 35\ {blank line} 36\ 37\ If no individual member_name's are specified then NO members are processed. 38\ If offset_define is not specified then the member_name is 39\ converted to all caps and used instead. If the size of an item is 40\ a power of two then an optional shift count may be output using 41\ shift_define as the name but only if shift_define was specified. 42\ 43\ Arrays cause stabs to automatically output the per-array-item increment 44\ in addition to the base address: 45\ 46\ foo FOO_SIZE 47\ array FOO_ARRAY 48\ 49\ results in: 50\ 51\ #define FOO_ARRAY 0x0 52\ #define FOO_ARRAY_INCR 0x4 53\ 54\ which allows \#define's to be used to specify array items: 55\ 56\ #define FOO_0 (FOO_ARRAY + (0 * FOO_ARRAY_INCR)) 57\ #define FOO_1 (FOO_ARRAY + (1 * FOO_ARRAY_INCR)) 58\ ... 59\ #define FOO_n (FOO_ARRAY + (n * FOO_ARRAY_INCR)) 60\ 61\ There are several examples below (search for _INCR). 62\ 63\ There is currently no manner in which to identify "anonymous" 64\ structures or unions so if they are to be used in assembly code 65\ they must be given names. 66\ 67\ When specifying the offsets of nested structures/unions each nested 68\ structure or union must be listed separately then use the 69\ "\#define" escapes to add the offsets from the base structure/union 70\ and all of the nested structures/unions together. See the many 71\ examples already in this file. 72 73#pragma ident "%Z%%M% %I% %E% SMI" 74 75#ifndef _GENASSYM 76#define _GENASSYM 77#endif 78 79#include <vm/hat_sfmmu.h> 80#include <sys/spitregs.h> 81#include <sys/cheetahregs.h> 82#include <sys/fpras_impl.h> 83#include <sys/traptrace.h> 84 85machcpu 86 intrstat MCPU_INTRSTAT 87 pil_high_start MCPU_PIL_HIGH_START 88 89trap_trace_record TRAP_ENT_SIZE 90 tt_tl TRAP_ENT_TL 91 tt_tt TRAP_ENT_TT 92 tt_tpc TRAP_ENT_TPC 93 tt_tstate TRAP_ENT_TSTATE 94 tt_tick TRAP_ENT_TICK 95 tt_sp TRAP_ENT_SP 96 tt_tr TRAP_ENT_TR 97 tt_f1 TRAP_ENT_F1 98 tt_f2 TRAP_ENT_F2 99 tt_f3 TRAP_ENT_F3 100 tt_f4 TRAP_ENT_F4 101 102hat HAT_SIZE 103 sfmmu_cnum 104 sfmmu_cpusran 105 sfmmu_tsb 106 sfmmu_ismblkpa 107 sfmmu_flags 108 109sfmmu_global_stat HATSTAT_SIZE 110 sf_pagefaults HATSTAT_PAGEFAULT 111 sf_uhash_searches HATSTAT_UHASH_SEARCH 112 sf_uhash_links HATSTAT_UHASH_LINKS 113 sf_khash_searches HATSTAT_KHASH_SEARCH 114 sf_khash_links HATSTAT_KHASH_LINKS 115 116ctx CTX_SIZE CTX_SZ_SHIFT 117 ctx_un.ctx_sfmmup CTX_SFMMUP 118 119sf_hment SFHME_SIZE SFHME_SHIFT 120 hme_tte SFHME_TTE 121 122tsbmiss TSBMISS_SIZE TSBMISS_SHIFT 123 tsbptr TSBMISS_TSBPTR 124 tsbptr4m TSBMISS_TSBPTR4M 125 ksfmmup TSBMISS_KHATID 126 usfmmup TSBMISS_UHATID 127 khashsz TSBMISS_KHASHSZ 128 khashstart TSBMISS_KHASHSTART 129 dcache_line_mask TSBMISS_DMASK 130 uhashsz TSBMISS_UHASHSZ 131 uhashstart TSBMISS_UHASHSTART 132 hat_flags TSBMISS_HATFLAGS 133 ismblkpa TSBMISS_ISMBLKPA 134 itlb_misses TSBMISS_ITLBMISS 135 dtlb_misses TSBMISS_DTLBMISS 136 utsb_misses TSBMISS_UTSBMISS 137 ktsb_misses TSBMISS_KTSBMISS 138 uprot_traps TSBMISS_UPROTS 139 kprot_traps TSBMISS_KPROTS 140 scratch TSBMISS_SCRATCH 141 142\#define TSB_TAGACC (0 * TSBMISS_SCRATCH_INCR) 143\#define TSBMISS_HMEBP (1 * TSBMISS_SCRATCH_INCR) 144\#define TSBMISS_HATID (2 * TSBMISS_SCRATCH_INCR) 145\#define TSBMISS_XMMURET (3 * TSBMISS_SCRATCH_INCR) 146\#define TSBMISS_XMMUPTR (4 * TSBMISS_SCRATCH_INCR) 147 148kpmtsbm KPMTSBM_SIZE KPMTSBM_SHIFT 149 vbase KPMTSBM_VBASE 150 vend KPMTSBM_VEND 151 flags KPMTSBM_FLAGS 152 sz_shift KPMTSBM_SZSHIFT 153 kpmp_shift KPMTSBM_KPMPSHIFT 154 kpmp2pshft KPMTSBM_KPMP2PSHFT 155 kpmp_table_sz KPMTSBM_KPMPTABLESZ 156 kpmp_tablepa KPMTSBM_KPMPTABLEPA 157 msegphashpa KPMTSBM_MSEGPHASHPA 158 tsbptr KPMTSBM_TSBPTR 159 kpm_dtlb_misses KPMTSBM_DTLBMISS 160 kpm_tsb_misses KPMTSBM_TSBMISS 161 162kpm_page KPMPAGE_SIZE KPMPAGE_SHIFT 163 kp_refcnt KPMPAGE_REFCNT 164 kp_refcnta KPMPAGE_REFCNTA 165 kp_refcntc KPMPAGE_REFCNTC 166 kp_refcnts KPMPAGE_REFCNTS 167 168kpm_hlk KPMHLK_SIZE KPMHLK_SHIFT 169 khl_mutex KPMHLK_MUTEX 170 khl_lock KPMHLK_LOCK 171 172kpm_spage KPMSPAGE_SIZE KPMSPAGE_SHIFT 173 kp_mapped KPMSPAGE_MAPPED 174 175kpm_shlk KPMSHLK_SIZE KPMSHLK_SHIFT 176 kshl_lock KPMSHLK_LOCK 177 178memseg MEMSEG_SIZE 179 pages MEMSEG_PAGES 180 epages MEMSEG_EPAGES 181 pages_base MEMSEG_PAGES_BASE 182 pages_end MEMSEG_PAGES_END 183 next MEMSEG_NEXT 184 lnext MEMSEG_LNEXT 185 nextpa MEMSEG_NEXTPA 186 pagespa MEMSEG_PAGESPA 187 epagespa MEMSEG_EPAGESPA 188 kpm_pbase MEMSEG_KPM_PBASE 189 kpm_nkpmpgs MEMSEG_KPM_NKPMPGS 190 mseg_un 191 kpm_pagespa MEMSEG_KPM_PAGESPA 192 193\#define MEMSEG_KPM_PAGES (MSEG_UN) 194\#define MEMSEG_KPM_SPAGES (MSEG_UN) 195 196page PAGE_SIZE 197 p_pagenum PAGE_PAGENUM 198 199tsb_info TSBINFO_SIZE 200 tsb_tte TSBINFO_TTE 201 tsb_va TSBINFO_VADDR 202 tsb_pa TSBINFO_PADDR 203 tsb_szc TSBINFO_SZCODE 204 tsb_next TSBINFO_NEXTPTR 205 206cpu_node CPU_NODE_SIZE 207 implementation 208 version 209 nodeid 210 clock_freq 211 tick_nsec_scale 212 ecache_size ECACHE_SIZE 213 ecache_linesize ECACHE_LINESIZE 214 device_id DEVICE_ID 215 216spitfire_scrub_misc_t 217 ec_scrub_outstanding 218 219spitfire_private_t 220 sfpr_scrub_misc 221 sfpr_scrub_afsr 222 223cheetah_private_t 224 chpr_icache_size 225 chpr_icache_linesize 226 chpr_tl1_err_data 227 chpr_scrub_misc 228 chpr_fecctl0_logout 229 chpr_cecc_logout 230 chpr_async_logout 231 chpr_tlb_logout 232 chpr_fpras_timestamp 233 234ch_scrub_misc_t 235 chsm_outstanding 236 237ch_cpu_logout_t CH_CPU_LOGOUT_SIZE 238 clo_flags CH_CLO_FLAGS 239 clo_nest_cnt CH_CLO_NEST_CNT 240 clo_data CH_CLO_DATA 241 clo_sdw_data CH_CLO_SDW_DATA 242 243ch_err_tl1_data_t CH_ERR_TL1_DATA_SIZE 244 ch_err_tl1_g1 245 ch_err_tl1_g2 246 ch_err_tl1_g3 247 ch_err_tl1_g4 248 ch_err_tl1_g5 249 ch_err_tl1_g6 250 ch_err_tl1_g7 251 ch_err_tl1_tpc 252 ch_err_tl1_flags 253 ch_err_tl1_tmp 254 ch_err_tl1_logout 255 256ch_cpu_errors_t CH_CPU_ERROR_SIZE 257 afsr CH_CPU_ERRORS_AFSR 258 afar CH_CPU_ERRORS_AFAR 259 shadow_afsr CH_CPU_ERRORS_SHADOW_AFSR 260 shadow_afar CH_CPU_ERRORS_SHADOW_AFAR 261 afsr_ext CH_CPU_ERRORS_AFSR_EXT 262 shadow_afsr_ext CH_CPU_ERRORS_SHADOW_AFSR_EXT 263 afar2 CH_CPU_ERRORS_AFAR2 264 265ch_diag_data_t CH_DIAG_DATA_SIZE 266 chd_afar CH_CHD_AFAR 267 chd_afar2 CH_CHD_AFAR2 268 chd_afsr CH_CHD_AFSR 269 chd_afsr_ext CH_CHD_AFSR_EXT 270 chd_ec_data CH_CHD_EC_DATA 271 chd_l2_data CH_CHD_L2_DATA 272 chd_dc_data CH_CHD_DC_DATA 273 chd_ic_data CH_CHD_IC_DATA 274 275ch_ec_data_t CH_EC_DATA_SIZE 276 ec_idx CH_EC_IDX 277 ec_tag CH_EC_TAG 278 ec_tag_ecc CH_EC_TAG_ECC 279 ec_data CH_EC_DATA 280 281ch_dc_data CH_DC_DATA_SIZE 282 dc_idx CH_DC_IDX 283 dc_way CH_DC_WAY 284 dc_tag CH_DC_TAG 285 dc_utag CH_DC_UTAG 286 dc_sntag CH_DC_SNTAG 287 dc_data CH_DC_DATA 288 dc_pn_data_parity CH_DC_PN_DATA_PARITY 289 290ch_ic_data CH_IC_DATA_SIZE 291 ic_idx CH_IC_IDX 292 ic_way CH_IC_WAY 293 ic_patag CH_IC_PATAG 294 ic_utag CH_IC_UTAG 295 ic_upper CH_IC_UPPER 296 ic_lower CH_IC_LOWER 297 ic_sntag CH_IC_SNTAG 298 ic_data CH_IC_DATA 299 300fpras_chkfn FPRAS_CHKFN_SIZE FPRAS_CHKFN_SIZE_SHIFT 301 fpras_blk0 302 303fpras_chkfngrp FPRAS_CHKFNGRP_SIZE FPRAS_CHKFNGRP_SIZE_SHIFT 304 305ch_pc_data CH_PC_DATA_SIZE 306 pc_idx CH_PC_IDX 307 pc_way CH_PC_WAY 308 pc_status CH_PC_STATUS 309 pc_tag CH_PC_TAG 310 pc_sntag CH_PC_SNTAG 311 pc_data CH_PC_DATA 312 313pn_tlb_logout PN_TLO_SIZE 314 tlo_info PN_TLO_INFO 315 tlo_addr PN_TLO_ADDR 316 tlo_pc PN_TLO_PC 317 tlo_itlb_tte PN_TLO_ITLB_TTE 318 tlo_dtlb_tte PN_TLO_DTLB_TTE 319 320ch_tte_entry CH_TLO_TTE_SIZE 321 ch_tte_tag CH_TLO_TTE_TAG 322 ch_tte_data CH_TLO_TTE_DATA 323 324ptl1_regs 325 ptl1_trap_regs 326 ptl1_g1 327 ptl1_g2 328 ptl1_g3 329 ptl1_g4 330 ptl1_g5 331 ptl1_g6 332 ptl1_g7 333 ptl1_tick 334 ptl1_dmmu_sfar 335 ptl1_dmmu_sfsr 336 ptl1_dmmu_tag_access 337 ptl1_immu_sfsr 338 ptl1_immu_tag_access 339 ptl1_rwindow 340 ptl1_softint 341 ptl1_pstate 342 ptl1_pil 343 ptl1_cwp 344 ptl1_wstate 345 ptl1_otherwin 346 ptl1_cleanwin 347 ptl1_cansave 348 ptl1_canrestore 349 350