2 Computone Intelliport II/Plus Multiport Serial Driver
3 -----------------------------------------------------
5 Release Notes For Linux Kernel 2.2 and higher.
6 These notes are for the drivers which have already been integrated into the
7 kernel and have been tested on Linux kernels 2.0, 2.2, and 2.3.
11 Author: Andrew Manison <amanison@america.net>
12 Testing: larryg@computone.com
13 Support: support@computone.com
14 Fixes and Updates: Doug McNash <dmcnash@computone.com>
15 Proc Filesystem and Kernel Integration: Mike Warfield <mhw@wittsend.com>
18 This file assumes that you are using the Computone drivers which are
19 integrated into the kernel sources. For updating the drivers or installing
20 drivers into kernels which do not already have Computone drivers, please
21 refer to the instructions in the README.computone file in the driver patch.
26 This driver supports the entire family of Intelliport II/Plus controllers
27 with the exception of the MicroChannel controllers. It does not support
28 products previous to the Intelliport II.
30 This driver was developed on the v2.0.x Linux tree and has been tested up
31 to v2.2.9; it will probably not work with earlier v1.X kernels,.
36 Hardware - If you have an ISA card, find a free interrupt and io port.
37 List those in use with `cat /proc/interrupts` and
38 `cat /proc/ioports`. Set the card dip switches to a free
39 address. You may need to configure your BIOS to reserve an
40 irq for an ISA card. PCI and EISA parameters are set
41 automagically. Insert card into computer with the power off
42 before or after drivers installation.
44 Note the hardware address from the Computone ISA cards installed into
45 the system. These are required for editing ip2.h or editing
46 /etc/config.modules, or for specification on the modprobe
53 a) Obtain driver-kernel patch file
54 b) Copy to the linux source tree root, Run ip2build (if not patch)
55 c) Determine free irq/address to use if any (configure BIOS if need be)
56 d) Run "make config" or "make menuconfig" or "make xconfig"
57 Select (m) module for CONFIG_COMPUTONE under character
58 devices. CONFIG_PCI and CONFIG_MODULES also may need to be set.
59 e) Set address on ISA cards then:
60 edit /usr/src/linux/drivers/char/ip2/ip2.h if needed
62 edit /etc/modules.conf if needed (module).
63 or both to match this setting.
66 h) Run "make modules_install"
67 i) Run "/sbin/depmod -a"
68 j) install driver using `modprobe ip2 <options>` (options listed below)
69 k) run ip2mkdev (either the script below or the binary version)
74 a) Obtain driver-kernel patch file
75 b) Copy to the linux source tree root, Run ip2build (if not patch)
76 c) Determine free irq/address to use if any (configure BIOS if need be)
77 d) Run "make config" or "make menuconfig" or "make xconfig"
78 Select (y) kernel for CONFIG_COMPUTONE under character
79 devices. CONFIG_PCI may need to be set if you have PCI bus.
80 e) Set address on ISA cards then:
81 edit /usr/src/linux/drivers/char/ip2/ip2.h
83 g) Run "make zImage" or whatever target you prefer.
84 h) mv /usr/src/linux/arch/i386/boot/zImage to /boot.
85 i) Add new config for this kernel into /etc/lilo.conf, run "lilo"
86 or copy to a floppy disk and boot from that floppy disk.
87 j) Reboot using this kernel
88 k) run ip2mkdev (either the script below or the binary version)
93 Previously, the driver sources were packaged with a set of patch files
94 to update the character drivers' makefile and configuration file, and other
95 kernel source files. A build script (ip2build) was included which applies
96 the patches if needed, and build any utilities needed.
97 What you recieve may be a single patch file in conventional kernel
98 patch format build script. That form can also be applied by
99 running patch -p1 < ThePatchFile. Otherwise run ip2build.
101 The driver can be installed as a module (recommended) or built into the
102 kernel. This is selected as for other drivers through the `make config`
103 command from the root of the Linux source tree. If the driver is built
104 into the kernel you will need to edit the file ip2.h to match the boards
105 you are installing. See that file for instructions. If the driver is
106 installed as a module the configuration can also be specified on the
107 modprobe command line as follows:
109 modprobe ip2 irq=irq1,irq2,irq3,irq4 io=addr1,addr2,addr3,addr4
111 where irqnum is one of the valid Intelliport II interrupts (3,4,5,7,10,11,
112 12,15) and addr1-4 are the base addresses for up to four controllers. If
113 the irqs are not specified the driver uses the default in ip2/ip2.h (which
114 selects polled mode). If no base addresses are specified the defaults in
115 ip2.h are used. If you are autoloading the driver module with kerneld or
116 kmod the base addresses and interrupt number must also be set in ip2/ip2.h
117 and recompile or just insert and options line in /etc/modules.conf or both.
118 The options line is equivalent to the command line and takes precidence over
121 /etc/modules.conf sample:
122 options ip2 io=1,0x328 irq=1,10
123 alias char-major-71 ip2
124 alias char-major-72 ip2
125 alias char-major-73 ip2
128 static ip2config_t ip2config =
132 0x0001, // Board 0, ttyF0 - ttyF63 /* PCI card */
133 0x0328, // Board 1, ttyF64 - ttyF127 /* ISA card */
134 0x0000, // Board 2, ttyF128 - ttyF191 /* empty */
135 0x0000 // Board 3, ttyF192 - ttyF255 /* empty */
140 Note: Both io and irq should be updated to reflect YOUR system. An "io"
141 address of "1/2" indicates a PCI/EISA card in the board table. The
142 PCI or EISA irq will be assigned automatically.
144 Specifying an invalid or in-use irq will default the driver into
145 running in polled mode for that card. If all irq entries are 0 then
146 all cards will operate in polled mode.
148 If you select the driver as part of the kernel run :
151 make zlilo (or whatever you do to create a bootable kernel)
153 If you selected a module run :
155 make modules && make modules_install
157 The utility ip2mkdev (see 5 and 7 below) creates all the device nodes
158 required by the driver. For a device to be created it must be configured
159 in the driver and the board must be installed. Only devices corresponding
160 to real IntelliPort II ports are created. With multiple boards and expansion
161 boxes this will leave gaps in the sequence of device names. ip2mkdev uses
162 Linux tty naming conventions: ttyF0 - ttyF255 for normal devices, and
163 cuf0 - cuf255 for callout devices.
168 As noted above, the driver implements the ports in accordance with Linux
169 conventions, and the devices should be interchangeable with the standard
170 serial devices. (This is a key point for problem reporting: please make
171 sure that what you are trying do works on the ttySx/cuax ports first; then
172 tell us what went wrong with the ip2 ports!)
174 Higher speeds can be obtained using the setserial utility which remaps
175 38,400 bps (extb) to 57,600 bps, 115,200 bps, or a custom speed.
176 Intelliport II installations using the PowerPort expansion module can
177 use the custom speed setting to select the highest speeds: 153,600 bps,
178 230,400 bps, 307,200 bps, 460,800bps and 921,600 bps. The base for
179 custom baud rate configuration is fixed at 921,600 for cards/expantion
180 modules with ST654's and 115200 for those with Cirrus CD1400's. This
181 corresponds to the maximum bit rates those chips are capable.
182 For example if the baud base is 921600 and the baud divisor is 18 then
183 the custom rate is 921600/18 = 51200 bps. See the setserial man page for
184 complete details. Of course if stty accepts the higher rates now you can
185 use that as well as the standard ioctls().
188 5. ip2mkdev and assorted utilities...
190 Several utilities, including the source for a binary ip2mkdev utility are
191 available under .../drivers/char/ip2. These can be build by changing to
192 that directory and typing "make" after the kernel has be built. If you do
193 not wish to compile the binary utilities, the shell script below can be
194 cut out and run as "ip2mkdev" to create the necessary device files. To
195 use the ip2mkdev script, you must have procfs enabled and the proc file
196 system mounted on /proc.
200 This is a release version of the driver, but it is impossible to test it
201 in all configurations of Linux. If there is any anomalous behaviour that
202 does not match the standard serial port's behaviour please let us know.
205 7. ip2mkdev shell script
212 # Make or remove devices as needed for Computone Intelliport drivers
214 # First rule! If the dev file exists and you need it, don't mess
215 # with it. That prevents us from screwing up open ttys, ownership
216 # and permissions on a running system!
218 # This script will NOT remove devices that no longer exist because
219 # their board or interface box has been removed. If you want to get
220 # rid of them, you can manually do an "rm -f /dev/ttyF* /dev/cuaf*"
221 # before running this script, which will then recreate all the valid
225 # Michael H. Warfield
228 if test ! -f /proc/tty/drivers
231 Unable to check driver status.
232 Make sure proc file system is mounted."
237 if test ! -f /proc/tty/driver/ip2
240 Unable to locate ip2 proc file.
241 Attempting to load driver"
245 if test ! -f /proc/tty/driver/ip2
248 Unable to locate ip2 proc file after loading driver.
249 Driver initialization failure or driver version error.
254 echo "Unable to load ip2 driver."
259 # Ok... So we got the driver loaded and we can locate the procfs files.
260 # Next we need our major numbers.
262 TTYMAJOR=`sed -e '/^ip2/!d' -e '/\/dev\/tty/!d' -e 's/.*tty.[ ]*\([0-9]*\)[ ]*.*/\1/' < /proc/tty/drivers`
263 CUAMAJOR=`sed -e '/^ip2/!d' -e '/\/dev\/cu/!d' -e 's/.*cu.[ ]*\([0-9]*\)[ ]*.*/\1/' < /proc/tty/drivers`
264 BRDMAJOR=`sed -e '/^Driver: /!d' -e 's/.*IMajor=\([0-9]*\)[ ]*.*/\1/' < /proc/tty/driver/ip2`
272 # Ok... Now we should know our major numbers, if appropriate...
273 # Now we need our boards and start the device loops.
275 grep '^Board [0-9]:' /proc/tty/driver/ip2 | while read token number type alltherest
277 # The test for blank "type" will catch the stats lead-in lines
278 # if they exist in the file
279 if test "$type" = "vacant" -o "$type" = "Vacant" -o "$type" = ""
284 BOARDNO=`expr "$number" : '\([0-9]\):'`
285 PORTS=`expr "$alltherest" : '.*ports=\([0-9]*\)' | tr ',' ' '`
286 MINORS=`expr "$alltherest" : '.*minors=\([0-9,]*\)' | tr ',' ' '`
288 if test "$BOARDNO" = "" -o "$PORTS" = ""
290 # This may be a bug. We should at least get this much information
291 echo "Unable to process board line"
295 if test "$MINORS" = ""
297 # Silently skip this one. This board seems to have no boxes
301 echo "board $BOARDNO: $type ports = $PORTS; port numbers = $MINORS"
303 if test "$BRDMAJOR" != ""
305 BRDMINOR=`expr $BOARDNO \* 4`
306 STSMINOR=`expr $BRDMINOR + 1`
307 if test ! -c /dev/ip2ipl$BOARDNO ; then
308 mknod /dev/ip2ipl$BOARDNO c $BRDMAJOR $BRDMINOR
310 if test ! -c /dev/ip2stat$BOARDNO ; then
311 mknod /dev/ip2stat$BOARDNO c $BRDMAJOR $STSMINOR
315 if test "$TTYMAJOR" != ""
319 for PORTNO in $MINORS
321 if test ! -c /dev/ttyF$PORTNO ; then
322 # We got the harware but no device - make it
323 mknod /dev/ttyF$PORTNO c $TTYMAJOR $PORTNO
328 if test "$CUAMAJOR" != ""
332 for PORTNO in $MINORS
334 if test ! -c /dev/cuf$PORTNO ; then
335 # We got the harware but no device - make it
336 mknod /dev/cuf$PORTNO c $CUAMAJOR $PORTNO