1: #define NGROUPS 10 /* number of mpx files permitted at one time */
2: #define NCHANS 20 /* number of channel structures */
3: #define NPORTS 30 /* number of channels to i/o ports */
4: #define CNTLSIZ 10
5: #define NLEVELS 4
6: #define NMSIZE 50 /* max size of mxlstn file name */
7:
8: /*
9: * header returned on read of mpx
10: */
11: struct rh {
12: short index;
13: short count;
14: short ccount;
15: };
16:
17: /*
18: * head expected on write of mpx
19: */
20: struct wh {
21: short index;
22: short count;
23: short ccount;
24: char *data;
25: };
26:
27: struct mx_args {
28: char *m_name;
29: int m_cmd;
30: int m_arg[3];
31: };
32:
33:
34: #ifdef KERNEL
35: /*
36: * internal structure for channel
37: */
38:
39: struct chan {
40: short c_flags;
41: char c_index;
42: char c_line;
43: struct group *c_group;
44: struct file *c_fy;
45: struct tty *c_ttyp;
46: struct clist c_ctlx;
47: int c_pgrp;
48: struct tty *c_ottyp;
49: char c_oline;
50: union {
51: struct clist datq;
52: } cx;
53: union {
54: struct clist datq;
55: struct chan *c_chan;
56: } cy;
57: struct clist c_ctly;
58: };
59:
60: struct schan {
61: short c_flags;
62: char c_index;
63: char c_line;
64: struct group *c_group;
65: struct file *c_fy;
66: struct tty *c_ttyp;
67: struct clist c_ctlx;
68: int c_pgrp;
69: };
70:
71:
72: /*
73: * flags
74: */
75: #define INUSE 01
76: #define COPEN 02
77: #define XGRP 04
78: #define YGRP 010
79: #define WCLOSE 020
80: #define ISGRP 0100
81: #define BLOCK 0200
82: #define EOTMARK 0400
83: #define SIGBLK 01000
84: #define BLKMSG 01000
85: #define ENAMSG 02000
86: #define WFLUSH 04000
87: #define NMBUF 010000
88: #define PORT 020000
89: #define ALT 040000
90:
91: #endif
92:
93:
94:
95:
96:
97:
98:
99:
100:
101: /*
102: * mpxchan command codes
103: */
104: #define MPX 5
105: #define MPXN 6
106: #define CHAN 1
107: #define JOIN 2
108: #define EXTR 3
109: #define ATTACH 4
110: #define CONNECT 7
111: #define DETACH 8
112: #define DISCON 9
113: #define DEBUG 10
114: #define NPGRP 11
115: #define CSIG 12
116: #define PACK 13
117:
118: #define NDEBUGS 30
119: /*
120: * control channel message codes
121: */
122: #define M_WATCH 1
123: #define M_CLOSE 2
124: #define M_EOT 3
125: #define M_OPEN 4
126: #define M_BLK 5
127: #define M_UBLK 6
128: #define DO_BLK 7
129: #define DO_UBLK 8
130: #define M_IOCTL 12
131: #define M_SIG 14
132:
133:
134: /*
135: * debug codes other than mpxchan cmds
136: */
137: #define MCCLOSE 29
138: #define MCOPEN 28
139: #define ALL 27
140: #define SCON 26
141: #define MSREAD 25
142: #define SDATA 24
143: #define MCREAD 23
144: #define MCWRITE 22
Defined struct's
chan
defined in line
39; used 90 times
- in line 55(2)
- in /usr/sys/dev/mx1.c line
33-37(4),
47(2),
63-67(4),
108-112(4),
119(2),
148(2),
423(2),
481(2)
- in /usr/sys/dev/mx2.c line
17-22(8),
68(2),
116-118(4),
140(2),
220(2),
308(2),
395(2),
421(2),
448(2),
483(2),
547(2),
572(2),
585(2),
662(2),
687(2),
701(2),
727(2),
749(2),
765(2),
796(2),
811-815(4),
837(2),
860-864(4)
- in /usr/sys/dev/tty.c line
435(2)
- in /usr/sys/sys/fakemx.c line
14(2),
29(2),
35(2)
rh
defined in line
11; used 2 times
schan
defined in line
60; used 4 times
wh
defined in line
20; used 2 times
Defined macros
ALL
defined in line
139; used 1 times
ALT
defined in line
89; used 2 times
BLOCK
defined in line
81; used 2 times
CHAN
defined in line
106; used 1 times
COPEN
defined in line
76; used 2 times
CSIG
defined in line
115; used 1 times
EXTR
defined in line
108; used 1 times
INUSE
defined in line
75; used 2 times
ISGRP
defined in line
80; used 8 times
JOIN
defined in line
107; used 1 times
MPX
defined in line
104; used 1 times
MPXN
defined in line
105; used 2 times
NCHANS
defined in line
2; used 3 times
NMBUF
defined in line
87; used 5 times
NMSIZE
defined in line
6; used 2 times
NPORTS
defined in line
3; used 2 times
PACK
defined in line
116;
never used
PORT
defined in line
88; used 7 times
SCON
defined in line
140;
never used
WCLOSE
defined in line
79; used 10 times
XGRP
defined in line
77; used 4 times
YGRP
defined in line
78; used 2 times
Usage of this include