summaryrefslogtreecommitdiffstats
path: root/usr.sbin/stallion/bootcode/stl.4
blob: ea983355a8cb9a9374a30385d0eb0de517146b97 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
.\" Copyright (c) 1996 Greg Ungerer (gerg@stallion.oz.au).
.\" All rights reserved.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" 1. Redistributions of source code must retain the above copyright
.\"    notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\"    notice, this list of conditions and the following disclaimer in the
.\"    documentation and/or other materials provided with the distribution.
.\" 3. All advertising materials mentioning features or use of this software
.\"    must display the following acknowledgement:
.\"	This product includes software developed by Greg Ungerer.
.\" 4. Neither the name of the author nor the names of any co-contributors
.\"    may be used to endorse or promote products derived from this software
.\"    without specific prior written permission.
.\"
.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
.\" $FreeBSD$
.\"
.Dd December 2, 1996
.Os
.Dt STL 4 i386
.Sh NAME
.Nm stl ,
.Nm stli
.Nd "drivers for Stallion Technologies multiport serial controllers"
.Sh SYNOPSIS
.Cd "stl0 at isa? port <addr> tty irq <irq>"
.Cd "stli0 at isa? port <io-addr> tty iomem <mem-addr> iosiz <size> flags <type> "
.Cd "stli0 at eisa? port <io-addr> tty iomem <mem-addr> iosiz <size> flags <type> "
.Sh DESCRIPTION
This is a kernel driver for Stallion Technologies multiport serial boards.
There are two drivers, each supporting a different class of boards.
The
.Nm
driver supports the EasyIO and EasyConnection 8/32
boards, while the
.Nm stli
driver supports all other types, including
ONboard, Brumby and EasyConnection 8/64.
.Sh CONFIGURATION
Each board installed in the system needs a configuration entry in the
kernel configuration file.
Slightly different options and parameters are required for each of the
different board types.
Depending on the type of board one of the
.Nm
or
.Nm stli
drivers will be used.  The
.Nm
and
.Nm stli
drivers can support up to 8 boards.
.Pp
Configuration of the hardware - DIP switches, jumpers, etc - varies
from board to board.
Consult documentation supplied with the board for hardware
configuration details.
Alternatively the board documentation is available on Stallion
Technologies WWW site at http://www.stallion.com.
.Pp
The EasyIO and EasyConnection 8/32 families of boards use the
.Nm
driver.
ISA board configuration entries for the
.Nm
driver take the general form of:
.Pp
.Cd "stlX at isa? port <io-addr> tty irq <irq>"
.Pp
.Ar X
is the unit number assigned to the board.
Any unique value between 0 and 7 is valid.
.Pp
The I/O address used by the board is specified by
.Ar <io-addr> .
Each of the EasyIO and EasyConnection 8/32-AT boards can use
an I/O address in the range from 0 to 0x400.
.Pp
All EasyIO and EasyConnection 8/32 boards require an interrupt,
and this interrupt is specified by
.Ar <irq> .
Legal IRQ values for the ISA boards are 3, 4, 5, 7, 10, 11, 12 and 15.
Interrupts are software programmed on all boards except the EasyIO-8M.
.Pp
The EasyConnection 8/32-AT board uses a secondary I/O address region,
and this is fixed at address 0x280 in the driver code.
All EasyConnection 8/32-AT boards may share the same secondary address
region.
.Pp
EasyConnection 8/32 PCI boards are detected automatically by the
system on boot up.
No configuration information is required in advance for these
board types.
During boot up the
.Nm
driver will issue messages to indicate that an EasyConnection 8/32
PCI board was found, and some information about it.
.Pp
Following are some examples of configuration entries for each of the ISA
boards supported by the
.Nm
driver.
Each example also describes some important details about each of the
board types.
.Pp
Each EasyIO board requires 8 bytes of I/O address space and 1 IRQ line.
A configuration entry for an EasyIO board would look like:
.Pp
.Cd "stl0 at isa? port 0x2a8 tty irq 15"
.Pp
This entry specifies an EasyIO board at I/O address 0x2a8 using IRQ 15.
The I/O and IRQ values can be modified as required.
.Pp
Each EasyConnection 8/32-AT board requires 2 sets of I/O addresses
and 1 IRQ line.
The primary I/O address range is 2 bytes in size, and must be unique
to each EasyConnection 8/32-AT board in the system.
The secondary I/O address range is 32 bytes in size, but can be shared
by multiple EasyConnection 8/32-AT boards.
This secondary I/O address is set at 0x280 in the driver code.
A configuration entry would look like:
.Pp
.Cd "stl0 at isa? port 0x2a0 irq 10 tty"
.Pp
This specifies an EasyConnection 8/32-AT with primary I/O address 0x2a0,
secondary I/O address of 0x280 and IRQ 10.
.Pp
The ONboard, Brumby and EasyConnection 8/64 families of boards use the
.Nm stli
driver.  The
.Nm stli
driver supports the ISA and EISA members of these families.
.Pp
ISA board configuration entries for the
.Nm stli
driver take the general form of:
.Pp
.Cd "stliX at isa? port <io-addr> tty iomem <mem-addr> iosiz <size> flags <type>"
.Pp
.Ar X
is the unit number assigned to the board.
Any unique value between 0 and 7 is valid.
.Pp
The I/O address used by the board is specified by
.Ar <io-addr> .
Each of the different supported board types has restrictions on valid
I/O addresses and also the amount of I/O space required varies between
the boards.
.Pp
All boards using the
.Nm stli
driver require a shared memory region to operate.
Depending on the board type the region required varies in size
from 4 kbytes to 64 kbytes.  The size of the board region is specified
by field
.Ar <size>
of the configuration entry, and the address of the region is specified by
.Ar <mem-addr> .
.Pp
The flags field specifies the particular board type that this entry
applies to.
Not all board types are distinguishable by the driver at runtime,
so this field is required by the driver.
Valid board types are:
.Bd -literal -offset indent
BOARD NAME			TYPE	I/O SIZE

Brumby				  2	0x4000
ONboard				  4	0x10000
ONboard/E			  7	0x10000
EasyConnection 8/64-AT		 23	0x1000
EasyConnection 8/64-EISA	 24	0x10000
.Ed
.Pp
Following are some examples of configuration entries for each of the
boards supported by the
.Nm stli
driver.
Each example also describes some important details about
each of the board types.
.Pp
The EasyConnection 8/64-AT board requires 4 bytes of I/O address space and
4 kbytes of memory space.
A configuration entry would look like:
.Pp
.Cd "stli0 at isa? port 0x2a0 tty iomem 0xcc000 iosiz 0x1000 flags 23"
.Pp
The flags field of this entry specifies that this is an
EasyConnection 8/64-AT board.
It is set to I/O address 0x2a0 and memory address 0xcc000.
The
.Ar iosiz
parameter specifies a memory region size
of 4 kbytes.
.Pp
The EasyConnection 8/64-EISA board requires a 64 kbyte region of
memory space.
This region can be anywhere in the 32 bit memory address space.
A configuration entry would be like:
.Pp
.Cd "stli0 at eisa? port 0x2000 tty iomem 0x80000000 iosiz 0x10000 flags 24"
.Pp
The flags field is used to specify that this is an EasyConnection 8/64-EISA
board.
The I/O (port) address resource is derived from the EISA slot that
the board is in.
Each EISA slot is allocated a section of the I/O address space by the
hardware of the system.
That address being 0xX000 where X is the slot number.
The example board is at memory address 0x80000000 which is 2 Gbyte.
The
.Ar iosiz
parameter specifies the size of the memory region,
in this case 64 kbytes.
.Pp
Each ONboard ISA board requires 16 bytes of I/O space and a 64 kbyte
section of memory address space.
Valid ONboard I/O addresses are in the range 0x200 to 0x300.
A configuration entry for an ONboard ISA would look like:
.Pp
.Cd "stli0 at isa? port 0x240 tty iomem 0xd0000 iosiz 0x10000 flags 4"
.Pp
This entry specifies an ONboard ISA by setting flags to 4.
It uses I/O address 0x240 and a memory region of 64 kbytes at memory
address 0xd0000.
.Pp
Each ONboard/E board requires a 64 kbyte memory region, and this
can be anywhere in the 32 bit address space (that is from 0 to 4 Gbyte).
A configuration entry would look like:
.Pp
.Cd "stli0 at eisa? port 0x3000 tty iomem 0xc0000000 iosiz 0x10000 flags 7"
.Pp
The specifies an ONboard/E in slot 3 using a shared memory address
of 0xc0000000 (3 Gbyte).
.Pp
Each Brumby board requires 16 bytes of I/O address space and a 4 kbyte
region of shared memory space.
The valid Brumby I/O addresses are in the range 0x300 to 0x400.
The shared memory region of the Brumby must be in the 0xc0000 to
0xdc000 region of the memory address space.
A configuration entry for a Brumby would be like:
.Pp
.Cd "stli0 at isa? port 0x360 tty iomem 0xc8000 iosiz 0x4000 flags 2"
.Pp
This specifies a Brumby board at I/O address 0x360 using a shared memory
region at address 0xc8000.
.Sh NOTES
When building the device nodes for the ports be sure to use the correct
driver name,
.Nm
or
.Nm stli .
Each driver has a separate major number allocated,
so even though the port device names are the same for each driver,
the major number of the device node is different.
Use the
.Xr MAKEDEV 8
script to create the devices.
Use the ttyE and cue tag for the
.Nm
driver, and
the ttyEi and cuei tags for the
.Nm stli
driver.
.Pp
The intelligent board types (ONboard, Brumby and EasyConnection 8/64)
require a firmware download before the ports will be operational.
This is achieved by using the
.Nm stlload
command.
See its manual page for details on usage.
.Sh FILES
.Bl -tag -width "/dev/staliomem?" -compact
.It Pa /dev/ttyE?
standard callin devices
.It Pa /dev/ttyiE?
initial-state callin devices
.It Pa /dev/ttylE?
lock-state callin devices
.It Pa /dev/cue?
standard callout devices
.It Pa /dev/cuie?
initial-state callout devices
.It Pa /dev/cule?
lock-state callout devices
.It Pa /dev/staliomem?
board control device
.El
.Pp
Note that the port numbers start at 0 for port 0 of board 0.
Each board has 64 port slots allocated for it.
So the second boards ports start at 64 and go through 127.
Use the
.Xr MAKEDEV 8
script to create the devices.
Use the ttyE and cue tag for the
.Nm
driver, and
the ttyEi and cuei tags for the
.Nm stli
driver.
.Sh SEE ALSO
.Xr stty 1 ,
.Xr termios 4 ,
.Xr tty 4 ,
.Xr comcontrol 8 ,
.Xr MAKEDEV 8 ,
.Xr stlload 8 ,
.Xr stlstats 8
.Sh HISTORY
This driver was originally developed by
.An Greg Ungerer Aq gerg@stallion.com .
OpenPOWER on IntegriCloud