1: #ifndef NOVL
2: #define NOVL 7
3:
4: #define A_MAGIC1 0407 /* normal */
5: #define A_MAGIC2 0410 /* read-only text */
6: #define A_MAGIC3 0411 /* separated I&D */
7: #define A_MAGIC4 0405 /* overlay */
8: #define A_MAGIC5 0430 /* auto-overlay (nonseparate) */
9: #define A_MAGIC6 0431 /* auto-overlay (separate) */
10:
11: #ifndef KERNEL
12: struct exec {
13: int a_magic; /* magic number */
14: unsigned a_text; /* size of text segment */
15: unsigned a_data; /* size of initialized data */
16: unsigned a_bss; /* size of uninitialized data */
17: unsigned a_syms; /* size of symbol table */
18: unsigned a_entry; /* entry point */
19: unsigned a_unused; /* not used */
20: unsigned a_flag; /* relocation info stripped */
21: };
22: struct ovlhdr {
23: int max_ovl; /* maximum ovl size */
24: unsigned ov_siz[NOVL]; /* size of i'th overlay */
25: };
26:
27: struct nlist {
28: char n_name[8]; /* symbol name */
29: int n_type; /* type flag */
30: unsigned n_value; /* value */
31: };
32:
33: /*
34: * Macros which take exec structures as arguments and tell whether
35: * the file has a reasonable magic number or offset to text.
36: */
37: #define N_BADMAG(x) \
38: (((x).a_magic)!=A_MAGIC1 && ((x).a_magic)!=A_MAGIC2 && \
39: ((x).a_magic)!=A_MAGIC3 && ((x).a_magic)!=A_MAGIC4 && \
40: ((x).a_magic)!=A_MAGIC5 && ((x).a_magic)!=A_MAGIC6)
41:
42: #define N_TXTOFF(x) \
43: ((x).a_magic==A_MAGIC5 || (x).a_magic==A_MAGIC6 ? \
44: sizeof (struct ovlhdr) + sizeof (struct exec) : sizeof (struct exec))
45:
46: /* values for type flag */
47: #define N_UNDF 0 /* undefined */
48: #define N_ABS 01 /* absolute */
49: #define N_TEXT 02 /* text symbol */
50: #define N_DATA 03 /* data symbol */
51: #define N_BSS 04 /* bss symbol */
52: #define N_TYPE 037 /* mask for type flag */
53: #define N_REG 024 /* register name */
54: #define N_FN 037 /* file name symbol */
55: #define N_EXT 040 /* external bit, or'ed in */
56: #define FORMAT "%06o" /* to print a value */
57: #endif KERNEL
58: #endif NOVL
Defined struct's
exec
defined in line
12; used 50 times
nlist
defined in line
27; used 100 times
- in /usr/src/cmd/dmesg.c line
19(2)
- in /usr/src/cmd/iostat.c line
33(2)
- in /usr/src/cmd/make/files.c line
334(2)
- in /usr/src/cmd/nm.c line
110-111(4),
130(2),
197-205(12),
215(2),
256(2)
- in /usr/src/cmd/prof.c line
124-125(4)
- in /usr/src/cmd/ps/ps.c line
31(2),
609-620(8),
691-696(4),
720(2)
- in /usr/src/cmd/pstat.c line
29(2)
- in /usr/src/cmd/ranlib.c line
50(2),
59(2),
115(2)
- in /usr/src/cmd/savecore.c line
27(2)
- in /usr/src/games/snake/busy.c line
31(2)
- in /usr/src/lib/c/gen/nlist.c line
6-13(6),
50(2)
- in /usr/src/sys/GENERIC/checksys.c line
21(2)
- in /usr/src/sys/autoconfig/do_config.c line
17(2)
- in /usr/src/sys/autoconfig/read_nlist.c line
18-20(6),
32-34(4),
43(2),
118-121(4)
- in /usr/src/sys/conf/checksys.c line
21(2)
- in /usr/src/ucb/checkobj.c line
27(2),
33(2)
- in /usr/src/ucb/sysline.c line
97(2)
- in /usr/src/ucb/vmstat.c line
15(2)
- in /usr/src/ucb/w.c line
37(2)
ovlhdr
defined in line
22; used 24 times
Defined macros
NOVL
defined in line
2; used 40 times
- in line 1,
24
- in /usr/include/sys/user.h line
105
- in /usr/src/cmd/nm.c line
108,
121
- in /usr/src/cmd/ps/ps.c line
631
- in /usr/src/cmd/size.c line
53-57(2)
- in /usr/src/cmd/strip.c line
89,
107,
124
- in /usr/src/lib/c/gen/nlist.c line
36
- in /usr/src/sys/GENERIC/checksys.c line
158,
230
- in /usr/src/sys/autoconfig/read_nlist.c line
96
- in /usr/src/sys/conf/checksys.c line
158,
230
- in /usr/src/sys/stand/bootstrap/boot.c line
38,
166,
330,
422-423(2),
473,
531(2)
- in /usr/src/sys/sys/mch.s line
415
- in /usr/src/sys/sys/sigjcl.c line
779
- in /usr/src/sys/sys/signojcl.c line
488
- in /usr/src/sys/sys/sys1.c line
275,
397,
465
- in /usr/src/sys/sys/text.c line
198,
215,
226
- in /usr/src/sys/sys/ureg.c line
107
- in /usr/src/ucb/checkobj.c line
139,
147,
185,
203
- in /usr/src/ucb/strings.c line
85
N_ABS
defined in line
48; used 1 times
N_BSS
defined in line
51; used 1 times
N_EXT
defined in line
55; used 12 times
N_FN
defined in line
54;
never used
N_REG
defined in line
53;
never used
Usage of this include