xref: /titanic_52/usr/src/uts/i86pc/ml/mach_offsets.in (revision e1c679fa4b0ab8c4bcaa6263974ca0c46e5b027f)
1\
2\ Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
3\ Use is subject to license terms.
4\
5\ CDDL HEADER START
6\
7\ The contents of this file are subject to the terms of the
8\ Common Development and Distribution License, Version 1.0 only
9\ (the "License").  You may not use this file except in compliance
10\ 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#pragma ident	"%Z%%M%	%I%	%E% SMI"
27
28\
29\ offsets.in: input file to produce assym.h using the ctfstabs program
30\
31
32#ifndef	_GENASSYM
33#define	_GENASSYM
34#endif
35
36#define	SIZES	1
37
38#include <sys/types.h>
39#include <sys/bootsvcs.h>
40#include <sys/systm.h>
41#include <sys/sysinfo.h>
42#include <sys/user.h>
43#include <sys/thread.h>
44#include <sys/proc.h>
45#include <sys/cpuvar.h>
46#include <sys/tss.h>
47#include <sys/privregs.h>
48#include <sys/segments.h>
49#include <sys/devops.h>
50#include <sys/ddi_impldefs.h>
51#include <vm/as.h>
52#include <sys/avintr.h>
53#include <sys/pic.h>
54#include <sys/rm_platter.h>
55#include <sys/stream.h>
56#include <sys/strsubr.h>
57#include <sys/sunddi.h>
58#include <sys/traptrace.h>
59#include <sys/ontrap.h>
60#include <sys/lgrp.h>
61#include <sys/dtrace.h>
62
63regs	REGSIZE
64	r_savfp	REGOFF_SAVFP
65	r_savpc	REGOFF_SAVPC
66	r_gs	REGOFF_GS
67	r_fs	REGOFF_FS
68	r_es	REGOFF_ES
69	r_ds	REGOFF_DS
70	r_edi	REGOFF_EDI
71	r_esi	REGOFF_ESI
72	r_ebp	REGOFF_EBP
73	r_esp	REGOFF_ESP
74	r_ebx	REGOFF_EBX
75	r_edx	REGOFF_EDX
76	r_ecx	REGOFF_ECX
77	r_eax	REGOFF_EAX
78	r_trapno	REGOFF_TRAPNO
79	r_err	REGOFF_ERR
80	r_eip	REGOFF_EIP
81	r_cs	REGOFF_CS
82	r_efl	REGOFF_EFL
83	r_uesp	REGOFF_UESP
84	r_ss	REGOFF_SS
85
86\#define	REGOFF_PC	REGOFF_EIP
87
88tss
89	tss_esp0		TSS_ESP0
90	tss_ss0		TSS_SS0
91	tss_ldt		TSS_LDT
92	tss_cr3		TSS_CR3
93	tss_cs		TSS_CS
94	tss_ss		TSS_SS
95	tss_ds		TSS_DS
96	tss_es		TSS_ES
97	tss_fs		TSS_FS
98	tss_gs		TSS_GS
99	tss_ebp		TSS_EBP
100	tss_eip		TSS_EIP
101	tss_eflags	TSS_EFL
102	tss_esp		TSS_ESP
103	tss_eax		TSS_EAX
104	tss_ebx		TSS_EBX
105	tss_ecx		TSS_ECX
106	tss_edx		TSS_EDX
107	tss_esi		TSS_ESI
108	tss_edi		TSS_EDI
109
110\#define	LABEL_EBP	_CONST(_MUL(2, LABEL_VAL_INCR) + LABEL_VAL)
111\#define	LABEL_EBX	_CONST(_MUL(3, LABEL_VAL_INCR) + LABEL_VAL)
112\#define	LABEL_ESI	_CONST(_MUL(4, LABEL_VAL_INCR) + LABEL_VAL)
113\#define	LABEL_EDI	_CONST(_MUL(5, LABEL_VAL_INCR) + LABEL_VAL)
114\#define	T_EBP		_CONST(T_LABEL + LABEL_EBP)
115\#define	T_EBX		_CONST(T_LABEL + LABEL_EBX)
116\#define	T_ESI		_CONST(T_LABEL + LABEL_ESI)
117\#define	T_EDI		_CONST(T_LABEL + LABEL_EDI)
118
119_klwp
120	lwp_pcb.pcb_fsdesc			LWP_PCB_FSDESC
121	lwp_pcb.pcb_gsdesc			LWP_PCB_GSDESC
122	lwp_pcb.pcb_drstat			LWP_PCB_DRSTAT
123	lwp_pcb.pcb_flags			PCB_FLAGS
124	lwp_pcb.pcb_fpu				LWP_PCB_FPU
125	lwp_pcb.pcb_fpu.fpu_regs		LWP_FPU_REGS
126	lwp_pcb.pcb_fpu.fpu_flags		LWP_FPU_FLAGS
127	lwp_pcb.pcb_fpu.fpu_regs.kfpu_u.kfpu_fx	LWP_FPU_CHIP_STATE
128
129pcb	PCBSIZE
130	pcb_drstat
131	pcb_fsdesc
132	pcb_gsdesc
133	pcb_fpu.fpu_regs	PCB_FPU_REGS
134	pcb_fpu.fpu_flags	PCB_FPU_FLAGS
135