Subject: Re: basic install problem...
To: None <port-sun3@NetBSD.ORG>
From: der Mouse <mouse@Rodents.Montreal.QC.CA>
List: port-sun3
Date: 03/22/1998 08:10:41
>>>> [trouble booting a >1G disk from what's probably an sc]
>>> [...] the first 1G of the disk?  I suspect the six-byte-cdb problem
>>> here, and I *think* the size limit that implies is 1G.
>> The 6 byte CDB limits the disk to the hundreds of megs.  It may be
>> anywhere form 300-500.  But it is definately before 1G.
> ...and I thought for sure I also told Mouse that the 6-byte size
> limit on CDBs was incorrect on the "sc"

I think thorpej is right that there is no 6-byte limit on the sc - IIRC
when working on the sc driver I've had a 10-byte cdb succeed at least
once.  But there may very well be a 6-byte limit in the ROM driver for
the sc, which would have explained why it affects only booting.  I
found just such a limitation in the ROMs of my SS1+, which is much
newer, so it's entirely plausible that at least some Sun-3 ROMs also
have it.

As for the size, I was quite sure "may be anywhere [from] 300-500
[megs]" was incorrect, that the limit was at a specific size, not
something that could vary from one case to another - specifically,
6-byte CDBs have only some (relatively small) number of bits allocated
for the block number.

So I went looking.  sd.c version 1.100.4.1 (a little old, perhaps, but
it's not as if 6-byte CDBs have changed since then) says

		/*
		 *  Fill out the scsi command.  If the transfer will
		 *  fit in a "small" cdb, use it.
		 */
		if (((blkno & 0x1fffff) == blkno) &&
		    ((nblks & 0xff) == nblks)) {

So, the limit is 0x1fffff (512-byte) blocks, which means my memory was
right, the small-CDB limit is 1G (give or take some amount possibly as
much as 128K).

					der Mouse

			       mouse@rodents.montreal.qc.ca
		     7D C8 61 52 5D E7 2D 39  4E F1 31 3E E8 B3 27 4B