xref: /titanic_51/usr/src/uts/i86pc/ml/offsets.in (revision ccdeb6b6d71f3c9aa7e78b688f7b34fff109a817)
1\
2\ Copyright (c) 2004, 2010, Oracle and/or its affiliates. All rights reserved.
3\ Copyright 2012 Garrett D'Amore <garrett@damore.org>.  All rights reserved.
4\ Copyright 2016 Joyent, Inc.
5\
6\ CDDL HEADER START
7\
8\ The contents of this file are subject to the terms of the
9\ Common Development and Distribution License (the "License").
10\ You may not use this file except in compliance with the License.
11\
12\ You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
13\ or http://www.opensolaris.org/os/licensing.
14\ See the License for the specific language governing permissions
15\ and limitations under the License.
16\
17\ When distributing Covered Code, include this CDDL HEADER in each
18\ file and include the License file at usr/src/OPENSOLARIS.LICENSE.
19\ If applicable, add the following below this CDDL HEADER, with the
20\ fields enclosed by brackets "[]" replaced with your own identifying
21\ information: Portions Copyright [yyyy] [name of copyright owner]
22\
23\ CDDL HEADER END
24\
25
26
27\
28\ offsets.in: input file to produce assym.h using the ctfstabs program
29\
30
31#ifndef	_GENASSYM
32#define	_GENASSYM
33#endif
34
35#define	SIZES	1
36
37#include <sys/types.h>
38#include <sys/bootsvcs.h>
39#include <sys/systm.h>
40#include <sys/sysinfo.h>
41#include <sys/user.h>
42#include <sys/thread.h>
43#include <sys/proc.h>
44#include <sys/cpuvar.h>
45#include <sys/tss.h>
46#include <sys/privregs.h>
47#include <sys/segments.h>
48#include <sys/devops.h>
49#include <sys/ddi_impldefs.h>
50#include <vm/as.h>
51#include <sys/avintr.h>
52#include <sys/pic.h>
53#include <sys/rm_platter.h>
54#include <sys/stream.h>
55#include <sys/strsubr.h>
56#include <sys/sunddi.h>
57#include <sys/modctl.h>
58#include <sys/traptrace.h>
59#include <sys/ontrap.h>
60#include <sys/lgrp.h>
61#include <sys/dtrace.h>
62#include <sys/brand.h>
63#include <sys/fastboot.h>
64#include <sys/cpr_wakecode.h>
65#include <sys/comm_page.h>
66
67proc		PROCSIZE
68	p_link
69	p_next
70	p_child
71	p_sibling
72	p_sig
73	p_flag
74	p_tlist
75	p_as
76	p_lockp
77	p_user
78	p_ldt
79	p_ldt_desc
80	p_model
81	p_pctx
82	p_agenttp
83	p_zone
84	p_brand
85	p_brand_data
86
87_kthread	THREAD_SIZE
88	t_pcb			T_LABEL
89	t_lock
90	t_lockstat
91	t_lockp
92	t_lock_flush
93	t_oldspl
94	t_pri
95	t_pil
96	t_lwp
97	t_procp
98	t_link
99	t_state
100	t_mstate
101	t_preempt_lk
102	t_stk			T_STACK
103	t_swap
104	t_lwpchan.lc_wchan	T_WCHAN
105	t_flag			T_FLAGS
106	t_ctx
107	t_lofault
108	t_onfault
109	t_ontrap
110	t_cpu
111	t_lpl
112	t_bound_cpu
113	t_intr
114	t_forw
115	t_back
116	t_sig
117	t_tid
118	t_pre_sys
119	t_preempt
120	t_proc_flag
121	t_startpc
122	t_sysnum
123	t_intr_start
124	_tu._ts._t_astflag	T_ASTFLAG
125	_tu._ts._t_post_sys	T_POST_SYS
126	_tu._t_post_sys_ast	T_POST_SYS_AST
127	t_copyops
128
129ctxop
130	save_op			CTXOP_SAVE
131
132as
133	a_hat
134
135user	USIZEBYTES
136	u_comm
137	u_signal
138
139_label_t
140	val	LABEL_VAL
141
142\#define	LABEL_PC	LABEL_VAL
143\#define	LABEL_SP	_CONST(LABEL_VAL + LABEL_VAL_INCR)
144\#define	T_PC		_CONST(T_LABEL + LABEL_PC)
145\#define	T_SP		_CONST(T_LABEL + LABEL_SP)
146
147_klwp
148	lwp_thread
149	lwp_procp
150	lwp_brand
151	lwp_eosys
152	lwp_regs
153	lwp_arg
154	lwp_ap
155	lwp_cursig
156	lwp_state
157	lwp_mstate.ms_acct	LWP_MS_ACCT
158	lwp_mstate.ms_prev	LWP_MS_PREV
159	lwp_mstate.ms_start	LWP_MS_START
160	lwp_mstate.ms_state_start LWP_MS_STATE_START
161	lwp_pcb
162	lwp_ru.sysc		LWP_RU_SYSC
163
164\#define	LWP_ACCT_USER	_CONST(LWP_MS_ACCT + _MUL(LMS_USER, LWP_MS_ACCT_INCR))
165\#define	LWP_ACCT_SYSTEM	_CONST(LWP_MS_ACCT + _MUL(LMS_SYSTEM, LWP_MS_ACCT_INCR))
166
167fpu_ctx
168	fpu_regs		FPU_CTX_FPU_REGS
169	fpu_flags		FPU_CTX_FPU_FLAGS
170	fpu_xsave_mask		FPU_CTX_FPU_XSAVE_MASK
171
172fxsave_state	FXSAVE_STATE_SIZE
173	fx_fsw			FXSAVE_STATE_FSW
174	fx_mxcsr_mask		FXSAVE_STATE_MXCSR_MASK
175
176
177autovec		AUTOVECSIZE
178	av_vector
179	av_intarg1
180	av_intarg2
181	av_ticksp
182	av_link
183	av_prilevel
184	av_dip
185
186av_head
187	avh_link
188	avh_hi_pri
189	avh_lo_pri
190
191cpu
192	cpu_id
193	cpu_flags
194	cpu_self
195	cpu_thread
196	cpu_thread_lock
197	cpu_kprunrun
198	cpu_lwp
199	cpu_fpowner
200	cpu_idle_thread
201	cpu_intr_thread
202	cpu_intr_actv
203	cpu_base_spl
204	cpu_intr_stack
205	cpu_stats.sys.cpumigrate	CPU_STATS_SYS_CPUMIGRATE
206	cpu_stats.sys.intr		CPU_STATS_SYS_INTR
207	cpu_stats.sys.intrblk		CPU_STATS_SYS_INTRBLK
208	cpu_stats.sys.syscall		CPU_STATS_SYS_SYSCALL
209	cpu_profile_pc
210	cpu_profile_upc
211	cpu_profile_pil
212	cpu_ftrace.ftd_state		CPU_FTRACE_STATE
213	cpu_mstate
214	cpu_intracct
215
216\#define	CPU_INTR_ACTV_REF	_CONST(CPU_INTR_ACTV + 2)
217
218cpu
219	cpu_m.pil_high_start	CPU_PIL_HIGH_START
220	cpu_m.intrstat		CPU_INTRSTAT
221	cpu_m.mcpu_current_hat	CPU_CURRENT_HAT
222	cpu_m.mcpu_gdt		CPU_GDT
223	cpu_m.mcpu_idt		CPU_IDT
224	cpu_m.mcpu_tss		CPU_TSS
225	cpu_m.mcpu_softinfo	CPU_SOFTINFO
226	cpu_m.mcpu_pri		CPU_PRI
227#if defined(__xpv)
228	cpu_m.mcpu_vcpu_info	CPU_VCPU_INFO
229#endif
230
231standard_pic
232	c_curmask
233	c_iplmask
234
235ddi_dma_impl
236	dmai_rflags
237	dmai_rdip
238
239dev_info
240	devi_ops		DEVI_DEV_OPS
241	devi_bus_ctl
242	devi_bus_dma_ctl
243	devi_bus_dma_allochdl
244	devi_bus_dma_freehdl
245	devi_bus_dma_bindhdl
246	devi_bus_dma_unbindhdl
247	devi_bus_dma_flush
248	devi_bus_dma_win
249
250dev_ops
251	devo_bus_ops		DEVI_BUS_OPS
252
253bus_ops
254	bus_ctl			OPS_CTL
255	bus_dma_map		OPS_MAP
256	bus_dma_ctl		OPS_MCTL
257	bus_dma_allochdl	OPS_ALLOCHDL
258	bus_dma_freehdl		OPS_FREEHDL
259	bus_dma_bindhdl		OPS_BINDHDL
260	bus_dma_unbindhdl	OPS_UNBINDHDL
261	bus_dma_flush		OPS_FLUSH
262	bus_dma_win		OPS_WIN
263
264sysent	SYSENT_SIZE	SYSENT_SIZE_SHIFT
265	sy_callc
266	sy_flags
267	sy_narg
268
269stdata
270	sd_lock
271
272queue
273	q_flag
274	q_next
275	q_stream
276	q_syncq
277	q_qinfo
278
279qinit
280	qi_putp
281
282syncq
283	sq_flags
284	sq_count
285	sq_lock
286	sq_wait
287
288rm_platter
289	rm_idt_lim		IDTROFF
290	rm_gdt_lim		GDTROFF
291	rm_pdbr			CR3OFF
292	rm_cpu			CPUNOFF
293	rm_cr4			CR4OFF
294	rm_cpu_halt_code	CPUHALTCODEOFF
295	rm_cpu_halted		CPUHALTEDOFF
296
297ddi_acc_impl
298	ahi_acc_attr	ACC_ATTR
299	ahi_get8	ACC_GETB
300	ahi_get16	ACC_GETW
301	ahi_get32	ACC_GETL
302	ahi_get64	ACC_GETLL
303	ahi_put8	ACC_PUTB
304	ahi_put16	ACC_PUTW
305	ahi_put32	ACC_PUTL
306	ahi_put64	ACC_PUTLL
307	ahi_rep_get8	ACC_REP_GETB
308	ahi_rep_get16	ACC_REP_GETW
309	ahi_rep_get32	ACC_REP_GETL
310	ahi_rep_get64	ACC_REP_GETLL
311	ahi_rep_put8	ACC_REP_PUTB
312	ahi_rep_put16	ACC_REP_PUTW
313	ahi_rep_put32	ACC_REP_PUTL
314	ahi_rep_put64	ACC_REP_PUTLL
315
316on_trap_data
317	ot_prot
318	ot_trap
319	ot_trampoline
320	ot_jmpbuf
321	ot_prev
322	ot_handle
323	ot_pad1
324
325trap_trace_ctl_t	__TRAPTR_SIZE TRAPTR_SIZE_SHIFT
326	ttc_next	TRAPTR_NEXT
327	ttc_first	TRAPTR_FIRST
328	ttc_limit	TRAPTR_LIMIT
329
330trap_trace_rec_t	TRAP_ENT_SIZE
331	ttr_cr2
332	ttr_info.idt_entry.vector	TTR_VECTOR
333	ttr_info.idt_entry.ipl		TTR_IPL
334	ttr_info.idt_entry.spl		TTR_SPL
335	ttr_info.idt_entry.pri		TTR_PRI
336	ttr_info.gate_entry.sysnum	TTR_SYSNUM
337	ttr_marker
338	ttr_stamp
339	ttr_curthread
340	ttr_sdepth
341	ttr_stack
342
343lgrp_ld
344	lpl_lgrpid
345
346dtrace_id_t	DTRACE_IDSIZE
347
348cpu_core	CPU_CORE_SIZE	CPU_CORE_SHIFT
349	cpuc_dtrace_flags
350	cpuc_dtrace_illval
351
352timespec	TIMESPEC_SIZE
353
354gate_desc	GATE_DESC_SIZE
355
356desctbr_t	DESCTBR_SIZE
357	dtr_limit
358	dtr_base
359
360mod_stub_info	MODS_SIZE
361	mods_func_adr	MODS_INSTFCN
362	mods_errfcn	MODS_RETFCN
363	mods_flag
364
365\#define	TRAP_TSIZE		_MUL(TRAP_ENT_SIZE, TRAPTR_NENT)
366
367copyops
368	cp_copyin
369	cp_xcopyin
370	cp_copyout
371	cp_xcopyout
372	cp_copyinstr
373	cp_copyoutstr
374	cp_fuword8
375	cp_fuword16
376	cp_fuword32
377	cp_fuword64
378	cp_suword8
379	cp_suword16
380	cp_suword32
381	cp_suword64
382	cp_physio
383
384brand
385	b_machops
386
387brand_proc_data_t
388	spd_handler
389
390fastboot_file_t
391	fb_va
392	fb_pte_list_va
393	fb_pte_list_pa
394	fb_dest_pa
395	fb_size
396	fb_next_pa
397	fb_sections
398	fb_sectcnt
399
400fastboot_section_t
401	fb_sec_offset
402	fb_sec_paddr
403	fb_sec_size
404	fb_sec_bss_size
405
406fastboot_info_t
407	fi_files
408	fi_has_pae
409	fi_pagetable_va
410	fi_pagetable_pa
411	fi_last_table_pa
412	fi_new_mbi_pa
413	fi_valid
414
415zone
416	zone_brand_data
417
418wc_cpu	WC_CPU_SIZE
419	wc_retaddr
420	wc_virtaddr
421	wc_cr0
422	wc_cr3
423	wc_cr4
424	wc_cr8
425	wc_fs
426	wc_fsbase
427	wc_gs
428	wc_gsbase
429	wc_kgsbase
430	wc_r8
431	wc_r9
432	wc_r10
433	wc_r11
434	wc_r12
435	wc_r13
436	wc_r14
437	wc_r15
438	wc_rax
439	wc_rbp
440	wc_rbx
441	wc_rcx
442	wc_rdi
443	wc_rdx
444	wc_rsi
445	wc_rsp
446	wc_gdt_limit	WC_GDT
447	wc_gdt_base
448	wc_idt_limit	WC_IDT
449	wc_idt_base
450	wc_tr
451	wc_ldt
452	wc_eflags
453	wc_ebx
454	wc_edi
455	wc_esi
456	wc_ebp
457	wc_esp
458	wc_esp
459	wc_ss
460	wc_cs
461	wc_ds
462	wc_es
463	wc_cpu_id
464	wc_saved_stack
465
466wc_wakecode
467	wc_cpu
468
469comm_page_s	COMM_PAGE_S_SIZE
470