freebsd-skq/sys/i386/isa
1999-07-17 18:34:32 +00:00
..
bs Add a number of interrelated CAM feature enhancements and bug fixes. 1999-05-06 20:16:39 +00:00
ic Remove fd driver from its old home and change files which include rtc.h 1999-05-31 18:36:14 +00:00
matcd Delete stray static prototype. 1999-07-03 21:02:09 +00:00
pcvt Keyboard allocation/deallocation fix. 1999-06-29 17:36:20 +00:00
snd Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
sound Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
adv_isa.c Use haveseen_ioport() which is now connected up to the resource manager. 1999-05-08 18:20:57 +00:00
aha_isa.c Use haveseen_ioport() which is now connected up to the resource manager. 1999-05-08 18:20:57 +00:00
aic6360.c Update the pccard hooks to use a module style declaration instead. 1999-01-19 00:21:53 +00:00
aic_98.h
apic_ipl.h
apic_ipl.s Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending 1999-07-10 15:28:01 +00:00
apic_vector.s Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending 1999-07-10 15:28:01 +00:00
asc.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
ascreg.h
atapi-cd.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
atapi-cd.h Add device stats for the acd device. 1999-01-31 21:51:03 +00:00
atapi.c Fix a potential hang situation. 1999-04-19 18:44:16 +00:00
atapi.h Shoot the LKM support in the old wd/wdc/atapi driver set in the head and 1999-04-13 19:38:12 +00:00
atpic_vector.s Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending 1999-07-10 15:28:01 +00:00
ccbque.h CAM support. 1998-12-28 12:46:55 +00:00
clock.c Shut up gcc. 1999-06-27 09:08:48 +00:00
cronyx.c
ctx.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
ctxreg.h
cx.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
cxreg.h
cy.c Really fix cy-driver-related panics when SMP is configured. Rev.1.88 only 1999-06-04 18:13:25 +00:00
cyreg.h Untangled the Cyclades offsets a little. CY16_RESET and CY_CLEAR_INTR 1998-11-23 13:58:55 +00:00
diskslice_machdep.c Convert buffer locking from using the B_BUSY and B_WANTED flags to using 1999-06-26 02:47:16 +00:00
elink.c
elink.h
gpib.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
gpib.h
gpibreg.h
gsc.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
gscreg.h
icu_ipl.h
icu_ipl.s Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending 1999-07-10 15:28:01 +00:00
icu_vector.s Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending 1999-07-10 15:28:01 +00:00
icu.h
if_ar.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_arregs.h
if_cs.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_csreg.h Add the 'cs' driver for Crystal Semiconductor CS89x0 devices. This 1998-07-20 20:00:43 +00:00
if_cx.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_ed.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_edreg.h Discard previous commit. 1998-10-08 17:20:58 +00:00
if_el.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_elreg.h
if_ep.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_epreg.h
if_ex.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_exreg.h
if_fe.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_fereg.h Oops, I forgot to commit two diffs to fe driver. 1998-12-15 15:56:37 +00:00
if_ie507.h
if_ie.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_iee16.h
if_iereg.h
if_le.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_lnc.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_lnc.h Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_rdp.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_rdpreg.h This is my first cut on a driver for the RealTek RTL 8002 pocket 1998-12-21 18:01:15 +00:00
if_sr.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_srregs.h
if_wi.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_wireg.h Add support to wicontrol(8) and wi(4) for enabling and configuring 1999-05-07 03:28:54 +00:00
if_wl.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_wl.h Someday I hope people will learn that "#endif" is not a comment 1998-12-09 03:30:52 +00:00
if_ze.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_zp.c Rename bpfilter to bpf. 1999-07-06 19:23:32 +00:00
if_zpreg.h
intr_machdep.c Fixed a longstanding scheduling bug. ASTs and softclock interrupts were 1999-07-10 14:54:19 +00:00
intr_machdep.h remove references to isa_device, it's no longer associated with interrupts. 1999-06-03 20:41:00 +00:00
ipl_funcs.c An SMP-specific change: eliminate another check on bsp_apic_ready. 1999-07-17 18:34:32 +00:00
ipl.s Go back to the old (icu.s rev.1.7 1993) way of keeping the AST-pending 1999-07-10 15:28:01 +00:00
isa_compat.c * Use ISA_DELETE_RESOURCE to cancel memory resource if driver clears maddr. 1999-05-30 11:04:31 +00:00
isa_compat.h fix some DRIVER_TYPE / INTR_TYPE confusions. 1999-05-09 09:56:52 +00:00
isa_device.h Don't include isa_dma.h if we have already seen isavar.h 1999-05-30 11:03:10 +00:00
isa_dma.c Clean out some unused leftovers from before the split from the old isa.c. 1999-05-09 23:56:00 +00:00
isa_dma.h Bring the 'new-bus' to the i386. This extensively changes the way the 1999-04-16 21:22:55 +00:00
isa.c Allow up to 8 ports, 4 memory regions and two irqs and drqs. 1999-05-30 11:05:39 +00:00
isa.h Move IO_PSMSIZE from kbdio.h to isa.h. I thought I did this a long time 1999-01-06 05:40:01 +00:00
istallion.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
joy.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
labpc.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
loran.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
lptreg.h
mcd.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
mcdreg.h
mse.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
nmi.c Fixed a longstanding scheduling bug. ASTs and softclock interrupts were 1999-07-10 14:54:19 +00:00
npx.c Don't hardcode IRQ 13 for NPX. It's as good as hardwired in the hardware 1999-05-15 17:58:58 +00:00
pcaudio.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
pcf.c Move the declaration of the interrupt type from the driver structure 1999-05-08 21:59:43 +00:00
pcibus.c Add support for multiple PCI busses directly connected to the nexus. 1999-07-16 01:00:30 +00:00
pcibus.h
pcic.h
pcicx.c
pnp.c Put the old-style isa interrupt handlers in id_ointr to avoid warnings. 1999-05-06 22:11:19 +00:00
pnp.h Support PnP compatibility IDs. This allow e.g. the ed driver to pick 1998-09-13 22:15:44 +00:00
ppc.c Return the port size from the probe. 1999-04-22 13:10:43 +00:00
ppcreg.h Distinguish EPP address/data register. Add EPP address register access to ppi. 1999-01-30 15:35:39 +00:00
prof_machdep.c Fixed profiling of elf kernels. Made high resolution profiling compile 1999-05-06 09:44:57 +00:00
random_machdep.c Add sufficient braces to keep egcs happy about potentially ambiguous 1999-05-06 18:13:11 +00:00
rc.c Fixed null setting of `rc_started'. This was fixed for the 1999-06-04 18:53:47 +00:00
rcreg.h
README.le Removed all `vector xxxintr' specifications. Interrupt handlers are now 1998-10-22 15:39:35 +00:00
README.stl Removed all `vector xxxintr' specifications. Interrupt handlers are now 1998-10-22 15:39:35 +00:00
rp.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
rpreg.h
rpvar.h
scd.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
scdreg.h
scsi_dvcfg.h
si2_z280.c Staticize. 1999-04-11 03:06:07 +00:00
si3_t225.c Staticize. 1999-04-11 03:06:07 +00:00
si.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
sireg.h SX ISA cards are only 32k wide in 8 bit mode (which is the only 1999-03-30 21:22:39 +00:00
spigot.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
spkr.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
stallion.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
timerreg.h
tw.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
vector.s Generate intrnames[] dynamically. This should be new-bus friendly. 1999-04-14 14:26:36 +00:00
vesa.c Fix some warnings, unused functions etc. 1999-07-01 15:05:11 +00:00
wd_cd.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
wd_cd.h Add device stats for the acd device. 1999-01-31 21:51:03 +00:00
wd.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
wdreg.h Add a couple of command definitions. 1999-06-15 23:13:09 +00:00
wfd.c From the submitter: 1999-06-24 03:09:11 +00:00
wst.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
wt.c Simplify cdevsw registration. 1999-05-31 11:29:30 +00:00
wtreg.h

Stallion Multiport Serial Driver Readme
---------------------------------------

Version: 0.0.5 alpha
Date:    20MAR96
Author:  Greg Ungerer (gerg@stallion.oz.au)



1. INTRODUCTION

This is a FreeBSD driver for some of the Stallion Technologies range of
multiport serial boards. This driver is still very new, so it should be
considered to be of very alpha quality.

This driver has not been developed by Stallion Technologies. I developed it
in my spare time in the hope that it would be useful. As such there is no
warranty or support of any form. What this means is that this driver is not
officially supported by Stallion Technologies, so don't ring their support
if you can't get it working. They will probably not be able to help you.
Instead email me if you have problems or bug reports and I will do what I
can... (Sorry to sound so heavy handed, but I need to stress that this driver
is not officially supported in any way.)

This package actually contains two drivers. One is for the true Stallion
intelligent multiport boards, and the other is for the smart range of boards.

All host driver source is included in this package, and is copyrighted under
a BSD style copyright. The board "firmware" code in this package is copyright
Stallion Technologies (the files cdk.sys and 2681.sys).


1.1 SMART MULTIPORT BOARD DRIVER

This driver supports the EasyIO and EasyConnection 8/32 range of boards.
These boards are not classic intelligent multiport boards, but are host
based multiport boards that use high performance Cirrus Logic CL-CD1400 RISC
UART's (they have built in FIFO's, automatic flow control and some other
good stuff).

The EasyIO range of cards comes in 3 forms, the EasyIO-4, EasyIO-8 and the
EasyIO-8M. All of these are non-expandable, low cost, ISA, multiport boards
with 4, 8 and 8 RS-232C ports respectively. Each EasyIO board requires 8
bytes of I/O address space and 1 interrupt. On an EISA system it is possible
to share 1 interrupt between multiple boards. The EasyIO-4 has 10 pin RJ
connectors, and the EasyIO-8 comes with a dongle cable with either 10 pin RJ
connectors or DB-25 connectors. The EasyIO-8M has 6 pin RJ connectors.

The EasyConnection 8/32 family of boards is a relatively low cost modular
range of multiport serial boards. The EasyConnection 8/32 boards can be
configured to have from 8 to 32 serial ports by plugging in external serial
port modules that contain either 8 or 16 ports each. There is a wide range
of external modules available that offer: DB-25 connectors, RJ-45 connectors
(both with RS-232 D and E compatible drivers), and also RS-422 and RS-485
ports. The EasyConnection 8/32 boards come in ISA, PCI and MCA bus versions.
The board takes the form of a host adapter card, with an external connector
cable that plugs into the external modules. The external modules just clip
together to add ports (BTW, they are NOT hot pluggable). Each ISA
EasyConnection 8/32 board requires two separate I/O address ranges, one two
bytes in size and a secondary region of 32 bytes. Each PCI EasyConnection
8/32 requires two regions of I/O address space, normally these will be
automatically allocated by the system BIOS at system power on time. Each MCA
EasyConnection board requires one I/O address region 64 bytes in size. All
board types also require one interrupt. On EISA systems multiple boards can
share one interrupt. The secondary I/O range of the ISA board (the 32 byte
range) can be shared between multiple boards on any bus type.


1.2 INTELLIGENT MULTIPORT BOARD DRIVER

This driver is for Stallion's range of true intelligent multiport boards.
It supports the EasyConnection 8/64, ONboard, Brumby and original Stallion
families of multiport boards. The EasyConnection 8/64 and ONboard boards come
in ISA, EISA and Microchannel bus versions. The Brumby and Stallion boards
are only available in ISA versions.

The EasyConnection 8/64 family of boards is a medium cost, high performance,
modular range of intelligent multiport serial boards. The EasyConnection 8/64
boards can be configured to have from 8 to 64 serial ports by plugging in
external serial port modules that contain either 8 or 16 ports each (these
modules are the same used by the EasyConnection 8/32 board). There is a wide
range of external modules available that offer: DB-25 connectors, RJ-45
connectors (both with RS-232 D and E compatible drivers), and also RS-422 and
RS-485 ports. The board takes the form of a host adapter card, with an external
connector cable that plugs into the external modules. The external modules
just clip together to add ports (BTW, they are NOT hot pluggable). Each
EasyConnection 8/64 board requires 4 bytes of I/O address space and a region
of memory space. The size of the memory region required depends on the exact
board type. The EISA version requires 64 Kbytes of address space (that can
reside anywhere in the 4 Gigabyte physical address space). The ISA and MCA
boards require 4 Kbytes of address space (which must reside in the lower
1 Mbyte of physical address space - typically in the c8000 to e0000 range).
No interrupts are required. The physical memory region of multiple
EasyConnection 8/64 boards can be shared, but each board must have a separate
I/O address space.

The ONboard family of boards are traditional intelligent multiport serial
boards. They are Stallion's older range of boards with a limited expansion
capability. They come in 4, 8, 12, 16 and 32 port versions. The board uses
the same base card (which has 4 ports on it) and is expanded to more ports
via a mezzanine board that attaches directly onto the board. External panels
plug into the ONboard providing RS-232C ports with DB-25 plugs. An RS-422
DB-25 dual interface panel is also available. The ISA and microchannel
ONboards require 16 bytes of I/O address space and 64K bytes of memory
space. The memory space can be anywhere in the 16 Mbyte ISA bus address
range. No interrupt is required. The EISA ONboard requires 64 Kbytes of
memory space that can be anywhere in the 4 Gigabyte physical address space.
All ONboard boards can share their memory region with other ONboards (or
EasyConnection 8/64 boards).

The Brumby family of boards are traditional, low cost intelligent multiport
serial boards. They are non-expandable and come in 4, 8 and 16 port versions.
They are only available for the ISA bus. The serial ports are all on DB-25
"dongle" cables that attach to the rear of the board. Each Brumby board
requires 16 bytes of I/O address space and 16 Kbytes of memory space. No
interrupts are required.

The original Stallion boards are old. They went out of production some years
back. They offer limited expandability and are available in 8 or 16 port
configurations. An external panel houses 16 RS-232C ports with DB-9
connectors. They require 16 bytes of I/O address space, and either 64K or
128K of memory space. No interrupt is required. I will not actively support
these boards, although they will work with the driver.

That's the boards supported by the second driver. The ONboard, Brumby and
Stallion boards are Stallion's older range of intelligent multiports - so
there are lots of them around. They only support a maximum baud rate of
38400. The EasyConnection 8/64 is a true high performance intelligent
multiport board, having much greater throughput than any of Stallion's
older boards. It also supports speeds up to 115200 baud.


1.3 HOW TO GET BOARDS

Stallion Technologies has offices all over the world, as well as many more
distributors and resellers. To find out about local availability please
contact the nearest Stallion office and they can give you all the information
you need.

	Stallion Technologies Sales and Support Offices
	===============================================

	Stallion Technologies Pty. Ltd.
	P.O. Box 954
	Toowong, QLD 4066, Australia
	Tel. +61 7 3270 4242
	Fax. +61 7 3270 4245
	Email: support@stallion.oz.au

	Stallion Technologies Inc.
	2880 Research Park Drive,
	Soquel,  CA 95073,  USA.
	Tel. +1 408 477 0440
	Fax. +1 408 477 0444
	Email: support@staltec.com

	Stallion Technologies Deutschland GmbH.
	Martin-Behaim-Strasse 12
	63263 Neu-Isenburg
	Germany
	Tel. +49 6102 73970
	Fax. +49 6102 739710

Another good source of information about the Stallion range of boards and
local availability is on the Stallion Web page. Check it out at
http://www.stallion.com.



2. INSTALLATION

This driver, as is, will work on a FreeBSD 2.1 system. It will run on
a 2.0.5 system, or -current version systems by changing a define in the
driver source.

You will need to build a new kernel to use this driver. So the first thing
you need is to have the full kernel source. Most people will have this
(I hope!). The following assumes that the kernel source is in /usr/src/sys.

The drivers can support up to 8 boards. For the smart board driver any
combination of EasyIO and EasyConnection 8/32 boards can be installed. For
the intelligent any combination of EasyConnection 8/64, ONboard, Brumby or
original Stallion. So there is a theoretical maximum of 512 ports.
(Off-course I have not tested a system with this many!)


[[[ The install instructions are obsolete, it is now standard ]]]
[[[ Skip forward to item 4, editing your kernel config file   ]]]

2.1 Instructions to install:

1. Copy the driver source files into the kernel source tree.

        cp stallion.c istallion.c cdk.h comstats.h /usr/src/sys/i386/isa
        cp scd1400.h /usr/src/sys/i386/isa/ic

   Note: if you are NOT using FreeBSD 2.1.0 then you will need to edit the
   stallion.c and istallion.c files and change the VFREEBSD define to match
   your version.

2. Skip to next step if on a FreeBSD kernel later than 2.1.0.
   Add a character device switch table entry for the driver that you which
   to use into the cdevsw table structure. This involves adding some code
   into the kernel conf.c file. 

   If you are using an EasyIO or EasyConnection 8/32 then you need to use
   the stallion.c driver. All other board types (EasyConnection 8/64,
   ONboard, Brumby, Stallion) use the istallion.c driver. You can also have
   a mix of boards using both drivers. You will need to use a different
   major device number for the second driver though (not the default 72 -
   see below for more details on this).

2.1. If using the stallion.c driver then do:

        cd /usr/src/sys/i386/i386
        vi conf.c
            - add the following lines (in 2.1 I put them at line 729):

/* Stallion Multiport Serial Driver */
#include "stl.h"
#if	NSTL > 0
d_open_t        stlopen;
d_close_t       stlclose;
d_read_t        stlread;
d_write_t       stlwrite;
d_ioctl_t	stlioctl;
d_stop_t        stlstop;
d_ttycv_t	stldevtotty;
#define stlreset	nxreset
#define	stlmmap		nxmmap
#define stlstrategy	nxstrategy
#else
#define	stlopen		nxopen
#define stlclose	nxclose
#define stlread		nxread
#define stlwrite	nxwrite
#define stlioctl	nxioctl
#define stlstop		nxstop
#define stlreset	nxreset
#define stlmmap		nxmmap
#define stlstrategy	nxstrategy
#define	stldevtotty	nxdevtotty
#endif


            - and then inside the actual cdevsw structure definition, at the
              last entry add (this is now line 1384 in the 2.1 conf.c):

	{ stlopen,	stlclose,	stlread,	stlwrite,	/*72*/
	  stlioctl,	stlstop,	stlreset,	stldevtotty,/*stallion*/
	  ttselect,	stlmmap,	stlstrategy },

            - the line above used major number 72, but this may be different
              on your system. Take note of what major number you are using.
              
            - save the file and exit vi.


2.2. If using the istallion.c driver then do:

        cd /usr/src/sys/i386/i386
        vi conf.c
            - add the following lines (in 2.1 I put them at line 729):

/* Stallion Intelligent Multiport Serial Driver */
#include "stl.h"
#if	NSTL > 0
d_open_t        stliopen;
d_close_t       stliclose;
d_read_t        stliread;
d_write_t       stliwrite;
d_ioctl_t	stliioctl;
d_stop_t        stlistop;
d_ttycv_t	stlidevtotty;
#define stlireset	nxreset
#define	stlimmap	nxmmap
#define stlistrategy	nxstrategy
#else
#define	stliopen	nxopen
#define stliclose	nxclose
#define stliread	nxread
#define stliwrite	nxwrite
#define stliioctl	nxioctl
#define stlistop	nxstop
#define stlireset	nxreset
#define stlimmap	nxmmap
#define stlistrategy	nxstrategy
#define	stlidevtotty	nxdevtotty
#endif


            - and then inside the actual cdevsw structure definition, at the
              last entry add (this is now line 1384 in the 2.1 conf.c):

	{ stliopen,	stliclose,	stliread,     stliwrite,	/*72*/
	  stliioctl,	stlistop,	stlireset,    stlidevtotty,/*istallion*/
	  ttselect,	stlimmap,	stlistrategy },

            - the line above used major number 72, but this may be different
              on your system. Take note of what major number you are using.
              
            - save the file and exit vi.

3. Add the driver source files to the kernel files list:

        cd /usr/src/sys/i386/conf
        vi files.i386
            - add the following definition lines into the list (it is stored
              alphabetically, so insert them appropriately):

i386/isa/istallion.c		optional	stli	device-driver

i386/isa/stallion.c		optional	stl	device-driver

            - save the file and exit vi.

4. Add board probe entries into the kernel configuration file:

        cd /usr/src/sys/i386/conf
        cp GENERIC MYKERNEL
            - if you already have a kernel config that you use then you
              could just use that (instead of MYKERNEL)
        vi MYKERNEL
            - if only using ECH-PCI boards then you don't need to enter a
              configuration line, the kernel will automatically detect
              the board at boot up, so skip to step 5.
            - enter a line for each board that you want to use. For stallion.c
              boards entries should look like:

device		stl0	at isa? port 0x2a0 tty irq 10

              For istallion.c boards, the entries should look like:

device		stli0	at isa? port 0x2a0 tty iomem 0xcc000 iosiz 0x1000 flags 23

              (I suggest you put them after the sio? entries)
              (Don't enter lines for ECH-PCI boards)
            - change the entry resources as required. For the Stallion.c
              entries this may involve changing the port address or irq.
              For the istallion.c entries this may involve changing the port
              address, iomem address, iosiz value and the flags. Select from
              the following table for appropriate flags and iosiz values for
              your board type:

              EasyConnection 8/64 ISA:     flags 23         iosiz 0x1000
              EasyConnection 8/64 EISA:    flags 24         iosiz 0x10000
              EasyConnection 8/64 MCA:     flags 25         iosiz 0x1000
              ONboard ISA:                 flags 4          iosiz 0x10000
              ONboard EISA:                flags 7          iosiz 0x10000
              ONboard MCA:                 flags 3          iosiz 0x10000
              Brumby:                      flags 2          iosiz 0x4000
              Stallion:                    flags 1          iosiz 0x10000

            - save the file and exit

5. Build a new kernel using this configuration.

        cd /usr/src/sys/i386/conf
        config MYKERNEL
        cd ../../compile/MYKERNEL
        make depend
        make all
        make install


And there you have it!  It is a little bit of effort to get it in there...

Once you have a new kernel built reboot to start it up. On startup the
Stallion board probes will report on whether the boards were found or not.
For each board found the driver will print out the type of board found,
and how many panels and ports it has. 

If a board is not found by the driver but is actually in the system then the
most likely problem is that the IO address is incorrect. The easiest thing to
do is change the DIP switches on the board to the desired address and reboot.

On EasyIO and EasyConnection 8/32 boards the IRQ is software programmable,
so if there is a conflict you may need to change the IRQ used for a board in
the MYKERNEL configuration file and rebuild the kernel.

Note that the secondary IO address of the EasyConnection 8/32 boards is hard
coded into the stallion.c driver code. It is currently set to IO address
0x280. If you need to use a different address then you will need to edit this
file and change the variable named stl_ioshared.

On intelligent boards it is possible that the board shared memory region is
clashing with that of some other device. Check for this and change the device
or kernel configuration as required.


2.2 INTELLIGENT DRIVER OPERATION

The intelligent boards also need to have their "firmware" code downloaded
to them. This is done via a user level application supplied in the driver
package called "stlload". Compile this program where ever you dropped the
package files, by typing "make". In its simplest form you can then type
    ./stlload -i cdk.sys
in this directory and that will download board 0 (assuming board 0 is an
EasyConnection 8/64 board). To download to an ONboard, Brumby or Stallion do:
    ./stlload -i 2681.sys

Normally you would want all boards to be downloaded as part of the standard
system startup. To achieve this, add one of the lines above into the
/etc/rc.serial file. To download each board just add the "-b <brd-number>"
option to the line. You will need to download code for every board. You should
probably move the stlload program into a system directory, such as /usr/sbin.
Also, the default location of the cdk.sys image file in the stlload
down-loader is /usr/lib/stallion. Create that directory and put the cdk.sys
and 2681.sys files in it. (It's a convenient place to put them anyway). As an
example your /etc/rc.serial file might have the following lines added to it
(if you had 3 boards):
    /usr/sbin/stlload -b 0 -i /usr/lib/stallion/cdk.sys
    /usr/sbin/stlload -b 1 -i /usr/lib/stallion/2681.sys
    /usr/sbin/stlload -b 2 -i /usr/lib/stallion/2681.sys

The image files cdk.sys and 2681.sys are specific to the board types. The
cdk.sys will only function correctly on an EasyConnection 8/64 board. Similarly
the 2681.sys image will only operate on ONboard, Brumby and Stallion boards.
If you load the wrong image file into a board it will fail to start up, and
of course the ports will not be operational!



3. USING THE DRIVER

Once the driver is installed you will need to setup some device nodes to
access the serial ports. Use the supplied "mkdevnods" script to automatically
create all required device entries for your boards. To make device nodes for
more than 1 board then just supply the number of boards you are using as a
command line parameter to mkdevnods and it will create nodes for that number
of boards. By default it will create device nodes for 1 board only.

Note that if the driver is not installed at character major number 72 then
you will need to edit the mkdevnods script and modify the STL_SERIALMAJOR
variable to the major number you are using.

Device nodes created for the normal serial port devices are named /dev/ttyEX
where X is the port number. (The second boards ports will start from ttyE64,
the third boards from ttyE128, etc). It will also create a set of modem call
out devices named cueX where again X is the port number.

For the most part the Stallion driver tries to emulate the standard PC system
com ports and the standard sio serial driver. The idea is that you should
be able to use Stallion board ports and com ports inter-changeably without
modifying anything but the device name. Anything that doesn't work like that
should be considered a bug in this driver!

Since this driver tries to emulate the standard serial ports as much as
possible then most system utilities should work as they do for the standard
com ports. Most importantly "stty" works as expected and "comcontrol" can be
used just like for the serial ports.

This driver should work with anything that works on standard com serial ports.
Having said that, I have used it on at least the following types of "things"
under FreeBSD:
    a) standard dumb terminals (using getty)
    b) modems (using cu, etc)
    c) ppp (through pppd, kernel ppp)



4. NOTES

Be aware that these drivers are still very new, so there is sure to be some
bugs in them. Please email me any feedback on bugs, problems, or even good
experiences with these drivers!

You can use both drivers at once if you have a mix of board types installed
in a system. However to do this you will need to change the major number used
by one of the drivers. Currently both drivers use default major number 72 for
their devices. Change one driver to use some other major number (how this is
achieved will depend on the kernel version you are using), and then modify the
mkdevnods script to make device nodes based on those new major numbers. For
example, you could change the stallion.c driver to use major number 73. You
will also need to create device nodes with different names for the ports, for
eg ttyFXXX.

Currently the intelligent board driver (istallion.c) does not have the
ability to share a boards memory region with other boards (you can only do
this on EasyConnection 8/64 and ONboards normally anyway). It also does
not currently support any memory address ranges above the low 1Mb region.
These will be fixed in a future release of the driver.

Finding a free physical memory address range can be a problem. The older
boards like the Stallion and ONboard need large areas (64K or even 128K), so
they can be very difficult to get into a system. If you have 16 Mb of RAM
then you have no choice but to put them somewhere in the 640K -> 1Mb range.
ONboards require 64K, so typically 0xd0000 is good, or 0xe0000 on some
systems. If you have an original Stallion board, "V4.0" or Rev.O, then you
need a 64K memory address space, so again 0xd0000 and 0xe0000 are good. Older
Stallion boards are a much bigger problem. They need 128K of address space and
must be on a 128K boundary. If you don't have a VGA card then 0xc0000 might be
usable - there is really no other place you can put them below 1Mb.

Both the ONboard and old Stallion boards can use higher memory addresses as
well, but you must have less than 16Mb of RAM to be able to use them. Usual
high memory addresses used include 0xec0000 and 0xf00000.

The Brumby boards only require 16Kb of address space, so you can usually
squeeze them in somewhere. Common addresses are 0xc8000, 0xcc000, or in
the 0xd0000 range. EasyConnection 8/64 boards are even better, they only
require 4Kb of address space, again usually 0xc8000, 0xcc000 or 0xd0000
are good.

If you are using an EasyConnection 8/64-EI or ONboard/E then usually the
0xd0000 or 0xe0000 ranges are the best options below 1Mb. If neither of
them can be used then the high memory support to use the really high address
ranges is the best option. Typically the 2Gb range is convenient for them,
and gets them well out of the way.

The ports of the EasyIO-8M board do not have DCD or DTR signals. So these
ports cannot be used as real modem devices. Generally when using these
ports you should only use the cueX devices.

There is a new utility in this package that reports statistics on the
serial ports. You will need to have the ncurses library installed on your
system to build it.

To build the statistics display program type:
    make stlstats
Once compiled simply run it (you will need to be root) and it will display
a port summary for the first board and panel installed. Use the digits to
select different board numbers, or 'n' to cycle through the panels on a
board. To look at detailed port information then hit 'p', that will display
detailed port 0 information. Use the digits and letters 'a' through 'f' to
select the different ports (on this board and panel).



5. ACKNOWLEDGEMENTS

This driver is loosely based on the code of the FreeBSD sio serial driver.
A big thanks to Stallion Technologies for the use of their equipment.