MCR2 and hard drive upgrade; HwNote02

John B. Milton jbm at uncle.UUCP
Tue Oct 11 16:10:26 AEST 1988


This is the first in a series of interesting hardware notes.

But wait, there's more!

There have been several major hardware revisions of the UNIXpc. I have seen
some evidence of a P1, and the kernel seems to still support a P2, even though
I have never seen a P2 running. Most boards out there are P3, P4 or P5. These
last three are mostly the same, and it shows. When UNIX is booted, it prints
the message "Main board is P3...P5". Some of us lucky folks have a drive with
more than 8 heads. The UNIXpc up the rev P5 was only designed for 3 bits of
hard disk head select, so 8 heads is the maximum. Convergent came up with a
hardware patch which brings the board rev up to P5.1. It consists of a PAL, a
bypass cap and 9 wires. This patch is supported in UNIX 3.5 and later. When
UNIX is booted with this patch installed, it will show "Main board is P5.1"

The extra bit needed for all this came from an as yet unused port, now called
the Miscellaneous Control Register 2 (MCR2), at address $E20000. The low order
bit of this register is the 4th hard disk head select bit. This means the
kernel has to go through some gyrations to select heads: put three bits over
here and the 4th one over there.

Well now; that's all good and fine and most you are yawning about now. Please
read along in <sys/hardware.h>. Right after the line:

#define HDSEL3	0x0001			/* Hard disk head select bit 3 */

is the line:

#define	DDRIVE1	0x0002			/* Hard disk drive select bit 1 */

Hmm. Does this mean it's the drive select bit for the first drive? No, the
4th bit of the register that has the three head select bits is DDRIVE0. That
must mean that this is the select bit for a SECOND hard disk drive. Everything
else in this register is new, so that makes sense. Those of us who have been
reading these news groups for while have heard the rumors of another upgrade
from Convergent for a second hard drive. The other goodies, namely an internal
floppy tape and an internal 2400 baud modem must be what Convergent calls a P6
machine. I wonder if this was going to be a UNIXpc+, or if it is a completely
different machine, the miniframe perhaps. I haven't seen specs for Convergent's
other machines, so I don't know.

Well, what would it take to add a second hard drive? Each hard drive has two
cables going to it. One of them is a 34 wire control signal cable. This is
bused to each hard drive, with a termination resistor in the last drive on the
cable. Each hard drive has a DIP switch or punch-out pack to pick the select
number for that drive. The second cable is the data cable. It has two
differential data signals on it, one for read data, one for write data, 11
grounds, and 5 others for a total of 20 pins. This cable can not be bused,
there has to be one for each hard drive. The drivers and receivers for this
cable also have to provided. There is another problem. How does one select
which of the two incoming data streams will be presented to the hard disk
data separation circuitry? All this is starting to sound like a lot of serious
hardware hacking.

What about the potentially nastiest problem of software? What would have to
be changed to get the gd disk driver to control the second drive? One could
format the second drive by temporarily switching it over to the drive 0 spot
and then switching it back to drive 1. Well, if you will now cd over to your
/dev directory, you will find some interesting things. There are two kinds
of disk drive special files: character and block. The character are rfpxxx,
and the block are fpxxx. A hard drive can have at most 16 partitions, by
default the first partition is the VHB/BBT, the second is the swap, and the
third, covering the rest of the disk is the user data partition. These cor-
respond to the fp000, fp001, fp002 files. The floppy drive only has two
paritions: VHB and user data. WHAT? NO FLOP SWAP? Sorry. That means that
[r]fp00[0-9a-f] are for the hard drive, [r]fp02[01] are for the floppy. What
are [r]fp01[0-9a-f] used for? Sixteen partitions for a second hard drive? Hmm.

If one could upgrade a system to handle two hard drives, would the P5.1 patch
need to be installed? In theory, no it wouldn't need to be. It would be just
fine to have two hard drives with <=8 heads. If fact this might be the most
common application. Lots of people can dig up two 20M drives, but maybe not
a 40M drive; or two 40M, but not an 80M, etc. Then there are the POWER users
who want to get TWO 190M Maxtors on there.

A second drive might present another opportunity. The UNIXpc power supply is
already overloaded. If one were to take the internal hard drive out and put
it with another in an external box with an external power supply, the load
would be taken off the UNIXpc. The whole noisy mess could be shoved in a drawer
somewhere too.

The machine across the table from me shows this for a "mount" command:
/ on /dev/fp002 read/write on Mon Oct 10 20:01:01 1988
/mnt on /dev/fp012 read/write on Mon Oct 10 20:03:21 1988

Now wait a minute...

John
--
-- 
John Bly Milton IV, jbm at uncle.UUCP, n8emr!uncle!jbm at osu-cis.cis.ohio-state.edu
home (614) 294-4823, work (614) 764-4272;  Send vi tricks, I'm making a manual



More information about the Unix-pc.general mailing list