Subject: Re: esiop driver
To: Matt Thomas <matt@3am-software.com>
From: Manuel Bouyer <bouyer@antioche.lip6.fr>
List: current-users
Date: 05/14/2002 18:52:39
--liOOAslEiF7prFVr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

On Sat, May 11, 2002 at 01:14:12AM -0700, Matt Thomas wrote:
> At 11:26 AM 4/23/2002, Manuel Bouyer wrote:
> >Hi,
> >those following source-changes will have noticed I've done some haking on the
> >siop driver these days.
> >I've added a new driver, esiop, which match the siop chips with the
> >requested properties (basically enouth general purpose registers, the
> >load/store instruction and "aithmetic ops on 2 registers).
> 
> With -current as of a few minutes ago, both siop and esiop fail to
> negotiate properly with my SCSI drive:
> 
> Before:
> NetBSD 1.5ZC (PILOT) #54: Wed Apr  3 23:55:17 PST 2002
> [...]
> siop0 at pci1 dev 5 function 0: Symbios Logic 53c896 (ultra2-wide scsi)
> siop0: using on-board RAM
> siop0: interrupting at irq 9
> [...]
> sd0 at scsibus1 target 1 lun 0: <IBM, DXHS36D, 0162> SCSI3 0/direct fixed
> sd0: 34732 MB, 11494 cyl, 20 head, 309 sec, 512 bytes/sect x 71132960 sectors
> sd0: sync (25.0ns offset 15), 16-bit (80.000MB/s) transfers, tagged queueing
> 
> Now:
> 
> sd0 at scsibus1 target 1 lun 0: <IBM, DXHS36D, 0162> SCSI3 0/direct fixed
> sd0: 34732 MB, 11494 cyl, 20 head, 309 sec, 512 bytes/sect x 71132960 sectors
> sd0: async, 8-bit transfers, tagged queueing
> 
> Until this is fixed I can't run bleeding edge current. :(  Just thought
> you'd like to know.

Interesting. I have a SCSI2 and a SCSI3 device connected to a 1010 (bus in
SE mode, though) and some SCSI3 connected to a 895 and I don't have this
problem.
Maybe your drive has a bug, and claim to only support DT clocking when
it's not true ? The attached patch should confirm this.

If this is not the problem, can you define DEBUG and DEBUG_NEG in
dev/ic/siop_common.c (they are #undef just after the includes) and post me the
messages ?

--
Manuel Bouyer, LIP6, Universite Paris VI.           Manuel.Bouyer@lip6.fr
--

--liOOAslEiF7prFVr
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename=diff

Index: scsiconf.c
===================================================================
RCS file: /cvsroot/syssrc/sys/dev/scsipi/scsiconf.c,v
retrieving revision 1.183
diff -u -r1.183 scsiconf.c
--- scsiconf.c	2002/05/05 06:01:28	1.183
+++ scsiconf.c	2002/05/14 16:52:09
@@ -851,10 +851,12 @@
 			 */
 			switch (inqbuf.flags4 & SID_Clocking) {
 			case SID_CLOCKING_DT_ONLY:
+#if 0 /* some drives improperly report DT_ONLY when they can do ST just fine */
 				periph->periph_cap &=
 				    ~(PERIPH_CAP_SYNC |
 				      PERIPH_CAP_WIDE16 |
 				      PERIPH_CAP_WIDE32);
+#endif
 				/* FALLTHOUGH */
 			case SID_CLOCKING_SD_DT:
 				periph->periph_cap |= PERIPH_CAP_DT;

--liOOAslEiF7prFVr--