Subject: microSONIC using if_ssce.c
To: list NetBSD port-pc532 <port-pc532@netbsd.org>
From: Eyal Lebedinsky <eyal@eyal.emu.id.au>
List: port-pc532
Date: 03/01/2004 21:23:01
I recently was handed a Sonic microSCSI unit, a SCSI to Ethernet
adapter. Simon Burge gave me some advice and I now have a new
kernel (cross compiled from Linux) with a new SCSI driver
(if_ssce.c).

I also found the correct cables. Powering up the unit brought
no reaction. Some checking around identified a tiny, surface
mounted fuse (a clue: it is labeled F1) hidden under the dc-dc
module. Soldering a wire accross it cured the problem and I
got a green PWR LED.

I could see yellow blinks on the RX LED so this looks good.

Booting the machine with a new kernel detected the device,
probably too well (see console log below). I then attempted
to bring up the interface and the machine locked up with
SCSI errors. Unplugging the SCSI cable caused a panic.

For a first attempt maybe it is not too bad...

Simon, will you look into this driver or is someone else
handling it (if any)?


telnet session
==============
[root@e1]# ifconfig -a
lo0: flags=8009<UP,LOOPBACK,MULTICAST> mtu 33196
         inet 127.0.0.1 netmask 0xff000000
ppp0: flags=8051<UP,POINTOPOINT,RUNNING,MULTICAST> mtu 1500
         inet 192.168.2.1 -> 192.168.10.1 netmask 0xffffff00
ssce0: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 00:40:10:07:a7:67
ssce1: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 01:00:00:00:00:34
ssce2: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 00:40:10:07:a7:67
ssce3: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 03:00:00:00:00:5c
ssce4: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 00:40:10:07:a7:67
ssce5: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 05:00:00:00:00:54
ssce6: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 00:40:10:07:a7:67
ssce7: flags=8822<BROADCAST,NOTRAILERS,SIMPLEX,MULTICAST> mtu 1500
         address: 07:00:00:00:00:8c
[root@e1]# ifconfig ssce0 192.168.2.10
[root@e1]#
	<<< No more response here

pc532 console
=============
NS32000 ROM Debugger
Version: Sat Jul 14 19:25:31 PDT 1990
RAM free above 0x1554

Command (? for help): read d'506920 3be000 48
Command (? for help): run 3be020

 >> NetBSD/pc532 Boot, Revision 1.1
 >> (jon@bullbox.bullers.net, Wed Jun 19 21:11:10 PDT 2002)
Boot: [[[sd0a:]netbsd][-abds]] :- E5
897024+24576+141020+[62340+75467] total=0x127133

[ Kernel symbol table invalid! ]
Copyright (c) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
     The NetBSD Foundation, Inc.  All rights reserved.
Copyright (c) 1982, 1986, 1989, 1991, 1993
     The Regents of the University of California.  All rights reserved.

NetBSD 1.6ZK (E5) #0: Sun Feb 29 20:38:02 EST 2004
         eyal@e7:/data2/NetBSD/NetBSD-current/src/sys/arch/pc532/compile/obj/E5
total memory = 8192 KB
avail memory = 6780 KB
mainbus0 (root)
rtc0 at mainbus0 addr 0xfff00000
clock0 at mainbus0 addr 0xfffffe00, irq 2
scn0 at mainbus0 addr 0xffc80000, irq 13, 12: scn2692, flags 1
scn1 at mainbus0 addr 0xffc80008
scn2 at mainbus0 addr 0xffc80010, irq 11, 10: scn2692
scn3 at mainbus0 addr 0xffc80018
scn4 at mainbus0 addr 0xffc80020, irq 9, 8: scn2692
scn5 at mainbus0 addr 0xffc80028
scn6 at mainbus0 addr 0xffc80030, irq 7, 6: scn2692
scn7 at mainbus0 addr 0xffc80038
ncr0 at mainbus0 addr 0xffd00000, irq 4
scsibus0 at ncr0: 8 targets, 8 luns per target
zero=fff8802b, bio=4010, net=34010, tty=76a90, clock=76a94, imp=76a90, softclock=fff9c02b, softnet=0
setstatclockrate
scsibus0: waiting 2 seconds for devices to settle...
sd0 at scsibus0 target 0 lun 0: <SEAGATE, ST32171W, 0484> disk fixed
sd0: 2062 MB, 5172 cyl, 5 head, 163 sec, 512 bytes/sect x 4223444 sectors
sd0: async, 8-bit transfers
sd1 at scsibus0 target 1 lun 0: <DEC, RZ29L-AS (C) DEC, 0654> disk fixed
sd1: 4091 MB, 3708 cyl, 20 head, 113 sec, 512 bytes/sect x 8380080 sectors
sd1: async, 8-bit transfers
ssce0 at scsibus0 target 3 lun 0: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce0: ethernet address 00:40:10:07:a7:67
ssce1 at scsibus0 target 3 lun 1: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce1(ncr0:0:3:1): Sense Error Code 0x5
ssce1: ethernet address 01:00:00:00:00:34
ssce2 at scsibus0 target 3 lun 2: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce2: ethernet address 00:40:10:07:a7:67
ssce3 at scsibus0 target 3 lun 3: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce3(ncr0:0:3:3): Sense Error Code 0x5
ssce3: ethernet address 03:00:00:00:00:5c
ssce4 at scsibus0 target 3 lun 4: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce4: ethernet address 00:40:10:07:a7:67
ssce5 at scsibus0 target 3 lun 5: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce5(ncr0:0:3:5): Sense Error Code 0x5
ssce5: ethernet address 05:00:00:00:00:54
ssce6 at scsibus0 target 3 lun 6: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce6: ethernet address 00:40:10:07:a7:67
ssce7 at scsibus0 target 3 lun 7: <SonicSys, MicroSCSI, 2.00> processor fixed
ssce7(ncr0:0:3:7): Sense Error Code 0x5
ssce7: ethernet address 07:00:00:00:00:8c
ssce0: async, 8-bit transfers
ssce1: async, 8-bit transfers
ssce2: async, 8-bit transfers
ssce3: async, 8-bit transfers
ssce4: async, 8-bit transfers
ssce5: async, 8-bit transfers
ssce6: async, 8-bit transfers
ssce7: async, 8-bit transfers
sd2 at scsibus0 target 4 lun 0: <QUANTUM, PD210S   SUN0207, 492W> disk fixed
sd2: 199 MB, 1156 cyl, 7 head, 50 sec, 512 bytes/sect x 408574 sectors
sd2: async, 8-bit transfers
st0 at scsibus0 target 5 lun 0: <ARCHIVE, VIPER 150  21247, -005> tape removable
st0: rogue, drive empty
st0: async, 8-bit transfers
cd0 at scsibus0 target 6 lun 0: <DEC, RRD44   (C) DEC, 3593> cdrom removable
cd0: async, 8-bit transfers
boot device: sd0
root on sd0a dumps on sd0b
root file system type: ffs
swapctl: adding /dev/sd0b as swap device at priority 0
Automatic boot in progress: starting file system checks.
/dev/rsd0a: file system is clean; not checking
/dev/rsd1a: file system is clean; not checking
Setting tty flags.
Setting sysctl variables:
Starting network.
Hostname: e1.eyal.emu.id.au
add net 127.0.0.0: gateway 127.0.0.1
Configuring network interfaces:.
Building databases...
    Using /E5
Starting syslogd.
Starting pppd: e4.
Checking for core dump...
savecore: no core dump
Mounting all filesystems...
Clearing /tmp.
Checking quotas: done.
Setting securelevel: kern.securelevel: 0 -> 1
Creating runtime link editor directory cache.
Starting ntpd.
Mar  1 20:33:46 e1 ntpd[189]: mlockall(): Cannot allocate memory
Updating motd.
Starting lpd.
starting local daemons:.
Starting inetd.
Starting cron.
Mon Mar  1 20:33:57 EST 2004

NetBSD/pc532 (e1.eyal.emu.id.au) (console)

login:
Mar  1 20:35:11 e1 su: eyal to root on /dev/ttyp0
Mar  1 20:41:28 e1 /netbsd: scn3: fifo overrun
Mar  1 20:41:48 e1 /netbsd: scn3: fifo overrun
Mar  1 20:45:44 e1 /netbsd: scn3: fifo overrun
ssce0: not queued, error 12
ssce0(ncr0:0:3:0): Sense Error Code 0x5
	<<< the above repeated fast, the telnet session has no response
	<<< I unplugged the microSCSI >>>
Unknown hardware interrupt: vec=1 pc=0xe00d1577 psr=0x08a0 cpl=0x00000000
Unknown hardware interrupt: vec=3 pc=0xe00d1577 psr=0x08a0 cpl=0x00000000
fatal abort trap in supervisor mode
trap type=2, pc=0x4c3b2, tear=0x4c3b2, msr=0x91
panic: trap
syncing disks...
	<<< no more, time to reset

--
Eyal Lebedinsky (eyal@eyal.emu.id.au) <http://samba.org/eyal/>