Subject: Cabletron "etherd" program for NetBSD
To: None <port-mac68k@NetBSD.ORG, port-pc532@NetBSD.ORG>
From: Phil Budne <budd@cs.bu.edu>
List: port-mac68k
Date: 07/12/1996 17:24:33
As promissed I've put together a package.
	ftp://alpha.gnu.ai.mit.edu/budne/pc532/etherd.*

Here is the README file (It sounds like Steve has found a friendly at
Cabletron, new info since I wrote this an hour ago!);

etherd README
Phil Budne <budd@cs.bu.edu>
July 12, 1996

etherd is a user program that tries to drive a Cabletron EA41x SCSI to
Ethernet adaptor from a NetBSD (or other 4.4-based system).  It should
also be applicable to other devices and operating systems with raw
scsi access and a tunnel interface driver.

The scsi.txt file available on ftp.ctron.com was a useful start, but
appears to be dated. I had to resort to disassebling my PROM (before I
found the EA412 image file) to get protocol filters to work (and thus
transfer packets when not in promiscuous mode).

INSTALATION
===========

It looks like the EA41x may disregard the "read allocation" on
INQUIRY.  Solution; use padded struct (and thus large allocation) for
scsi_inquiry (hence scsi_xxx.c.diff).

Patches also needed to add "uk" driver support to pc532 port (see
*.pc532.diff).  You must have "uk" and "tun" drivers configured.

USAGE
=====

You MUST edit the "netstart" the script for your local configuration.

netstart also passes any command line arguments to etherd (ie; for
options).  I still haven't gotten routing quite right, it would be
nice to have a way to control (ie; using ifconfig linkX) whether a
given instance of the tunnel interface appears as a POINTTOPOINT or
multidrop interface!

etherd uses traditional (net2) Berkeley arp code (requires no routing
table support routines), and takes the following arguments;

options;
	-d	increment debug level (only levels 0, 1, & 2 are meaningful)
	-p	use promiscuous mode
	-r RATE	poll cabletron RATE times a second. The default is 25,
		which has reasonable overhead, and introduces a
		maximum of 40ms latency (well below human tolerance).

required;
	ukX	name of the "unknown SCSI driver" instance attached to
		Cabletron as shown in boot messages.

	tunY	name of the tunnel driver instance to use.  must be
		pre-configured.  No dest addr needed?

PROBLEMS
========

1. I cannot send large amounts of data out on the ether using the
cabletron. I see messages like;

    ncr0: can not transfer more data
    ncr0: aborting, but phase=DATA_IN (reset)
    ncr0: reset SCSI bus for TID=6 LUN=0

It may be that my scsi bus is a mess.  The cabletron only works when
termination is selected.  Reception works fine (I've seen up to
95000B/s sending /usr/share/misc/termcap).

2. I cannot recieve back-to back packets (ie; fragmented IP packets).
"ping -s 1472" works, "ping -s 1473" does not.  This works when the
box is hooked to my Mac, in fact I'm able to do; "spray -i -c 227 mac"
and "spray -i -c 10 -l 2000 mac" from my Sun running 4.1.4.  I see
123KB/s on the latter spray.

3. I sometimes get into a screwed up state (usuallu after seeing
problem #1) where I ping the box and packets arrive 1, 2 or 3 seconds
late.  This and problem #2 suggest I'm doing something that is
effecting the input buffering of packets!

4. Need to figure out how to use undocumented opcode 9 to download new
01.00.00 image file (my PROM is 00.00.19)!

Any of all of the above might be answered by peeking inside the
Macintosh driver!