The Unix Heritage Society mailing list
 help / color / mirror / Atom feed
* [pups] Major/minor device numbers and device names for MSCP drives?
@ 2006-06-19  3:15 Robert Armstrong
  2006-06-19  6:57 ` Jochen Kunz
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Robert Armstrong @ 2006-06-19  3:15 UTC (permalink / raw)


  Probably this is documented somewhere, but I really need a pointer or a
brief tutorial on the major/minor device numbers for mknod() and the device
names for MSCP drives in 2.11bsd.
 
  If I have a really simple PDP with an RQDXn and one RDxx disk, then the
device name is conventionally /dev/ra0x and the first partition, ra0a is
(5,0), the second, ra0b, is (5,1), etc.  Pretty easy.
 
  If I have two drives on my single RQDXn, then the second hard disk is
/dev/ra1 and ra1a is (5,8), ra1b is (5,9), etc.  I guess the offset of 8
must be the maximum number of partitions on a drive - OK, I'm still with
you.
 
  But what if I have a second MSCP controller?  Assuming that I've built the
kernel to handle it and modified dtab to autoconfigure it, that is.  What
are the usual names and mknod() numbers for the drives on the second
controller?
 
  Worse, what if the MSCP controller isn't a RQDX but is a real UDA/QDA ?
Now the drives have their own MSCP unit numbers that can be anything from 0
to 250 - where does this figure in?
 
  Same question for TMSCP - what if I have more than one tape controller?
This case is easier, though, since TMSCP controllers normally have only one
drive associated with them.
 
Thanks,
Bob Armstrong
 
 
  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://minnie.tuhs.org/pipermail/tuhs/attachments/20060618/b4615e63/attachment.html>


^ permalink raw reply	[flat|nested] 7+ messages in thread

* [pups] Major/minor device numbers and device names for MSCP drives?
  2006-06-19  3:15 [pups] Major/minor device numbers and device names for MSCP drives? Robert Armstrong
@ 2006-06-19  6:57 ` Jochen Kunz
  2006-06-19 14:51   ` Robert Armstrong
  2006-06-19 15:08 ` Johnny Billquist
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 7+ messages in thread
From: Jochen Kunz @ 2006-06-19  6:57 UTC (permalink / raw)


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 690 bytes --]

On Sun, 18 Jun 2006 20:15:52 -0700
"Robert Armstrong" <bob at jfcl.com> wrote:

>  But what if I have a second MSCP controller?
/dev/ra1a is still (5,8). The disks are numbered in the same order as
they are found. (Modulo devices that are "nailed down" in the kernel
config file.) This is independent of the controler they are connected
to. Some years ago I used a MSCP ESDI disk controller and in addition a
MSCP SMD disk controller to connect two disks to my PDP-11/73 and IIRC
the SMD disk showd up as /dev/ra1[a-h].

At least this is "the generic BSD way". 2.11BSD may be a bit different
due to its age.
-- 


tschüß,
       Jochen

Homepage: http://www.unixag-kl.fh-kl.de/~jkunz/




^ permalink raw reply	[flat|nested] 7+ messages in thread

* [pups] Major/minor device numbers and device names for MSCP drives?
  2006-06-19  6:57 ` Jochen Kunz
@ 2006-06-19 14:51   ` Robert Armstrong
  0 siblings, 0 replies; 7+ messages in thread
From: Robert Armstrong @ 2006-06-19 14:51 UTC (permalink / raw)



>Jochen Kunz wrote:
>The disks are numbered in the same order as they are found.

  Is it safe to assume that drives are always discovered in ascending unit
number order, starting with the first controller and continuing with the
second ?

  Is there any utility that will examine the running system and tell you
which drives and units were actually discovered?

  init will say something like "ra 0 at ...." and "ra 1 at ...", but that's
talking about controllers.  AFAIK it says nothing about the drives
discovered.

  Sorry to complain, but it seems like it can be a little bit ambiguous as
to whether BSD actually discovered the drives you think it should have.
This is especially true if you have something like a SCSI controller where
it may not be immediately obviously which drives are online or what their
MSCP unit numbers are.

  And it's important to know which actual disk drive you're writing on :-)

Bob





^ permalink raw reply	[flat|nested] 7+ messages in thread

* [pups] Major/minor device numbers and device names for MSCP drives?
  2006-06-19  3:15 [pups] Major/minor device numbers and device names for MSCP drives? Robert Armstrong
  2006-06-19  6:57 ` Jochen Kunz
@ 2006-06-19 15:08 ` Johnny Billquist
  2006-06-19 21:43 ` C. H. Dickman
  2006-06-19 21:53 ` C. H. Dickman
  3 siblings, 0 replies; 7+ messages in thread
From: Johnny Billquist @ 2006-06-19 15:08 UTC (permalink / raw)


On Sun, 18 Jun 2006, Robert Armstrong wrote:

>  Worse, what if the MSCP controller isn't a RQDX but is a real UDA/QDA ?
> Now the drives have their own MSCP unit numbers that can be anything from 0
> to 250 - where does this figure in?

Note that this isn't really anything special.
You can both have a RQDX with an extender card which allows you to set 
other unit numbers on RD disks, and if you have two UDA controllers, they 
could both have disks starting from number 0.

The other response about automatic numbering of disks is true of NetBSD, 
as well as Ultrix. However, I'm not sure that BSD2 do this.
Unfortunately I can't remember for sure.
But don't you actually tell the unit numbers in the configuration file, 
along with the controller? Or do BSD2 also do a full autodetect and 
connect of MSCP disks?

If not, it could work in several ways, but I would suspect that disks on 
the second controller would start with minor # 64 (8 disks * 8 partitions 
per disk is I believe the default). But that assumes that the first disk 
found will be "0", no matter what the physical unit number is set to. 
Unless of course, this also is set in the configuration file. :-)

>  Same question for TMSCP - what if I have more than one tape controller?
> This case is easier, though, since TMSCP controllers normally have only one
> drive associated with them.

Well, DEC only have TMSCP controllers with a single unit for the PDP-11. 
Third party controllers can have several units...

 	Johnny



^ permalink raw reply	[flat|nested] 7+ messages in thread

* [pups] Major/minor device numbers and device names for MSCP drives?
  2006-06-19  3:15 [pups] Major/minor device numbers and device names for MSCP drives? Robert Armstrong
  2006-06-19  6:57 ` Jochen Kunz
  2006-06-19 15:08 ` Johnny Billquist
@ 2006-06-19 21:43 ` C. H. Dickman
  2006-06-20 15:45   ` Robert Armstrong
  2006-06-19 21:53 ` C. H. Dickman
  3 siblings, 1 reply; 7+ messages in thread
From: C. H. Dickman @ 2006-06-19 21:43 UTC (permalink / raw)


Robert Armstrong wrote:
>   Probably this is documented somewhere, but I really need a pointer 
> or a brief tutorial on the major/minor device numbers for mknod() and 
> the device names for MSCP drives in 2.11bsd.
This is what I remember about it all when I struggled with it a couple 
of years ago.

The 8 bit minor number has 3 parts: the upper two bits are the 
controller (4 controllers max), the middle 3 bits are unit number (8 
drives per controller) and the lower 3 bits are the partition (a-h).

The assignment of device names is static (or nearly static). The 
discovery code for the controllers checks them in the order listed in 
/dev/dtab and assigns a controller number to each that is discovered and 
in that order (the nearly static part). Note also that DEC has a 
standard order for controller addresses too (which might be different). 
After that, drives are accessed using the 3 bit unit number which MUST 
correspond to the MSCP unit number (a catch follows because of this). 
Partitions are accessed with the 3 bit partition number.

The catch is that MSCP unit numbers are supposed to be global cross all 
controllers and the microPDP-11/83 boot code assumes this. The boot code 
can only see the first unit n that is encountered and 2.11BSD can only 
see the drives with MSCP unit numbers less than 8.

If you only have one controller there is no problem. When you add 
multiple controllers, things get more complex because you can only boot 
the first 8 MSCP units if you want to be able to access them from 2.11BSD.

-chuck






 



^ permalink raw reply	[flat|nested] 7+ messages in thread

* [pups] Major/minor device numbers and device names for MSCP drives?
  2006-06-19  3:15 [pups] Major/minor device numbers and device names for MSCP drives? Robert Armstrong
                   ` (2 preceding siblings ...)
  2006-06-19 21:43 ` C. H. Dickman
@ 2006-06-19 21:53 ` C. H. Dickman
  3 siblings, 0 replies; 7+ messages in thread
From: C. H. Dickman @ 2006-06-19 21:53 UTC (permalink / raw)


Robert Armstrong wrote:
>   Probably this is documented somewhere, but I really need a pointer 
> or a brief tutorial on the major/minor device numbers for mknod() and 
> the device names for MSCP drives in 2.11bsd.
>  
>   If I have a really simple PDP with an RQDXn and one RDxx disk, then 
> the device name is conventionally /dev/ra0x and the first partition, 
> ra0a is (5,0), the second, ra0b, is (5,1), etc.  Pretty easy.
>  
>   If I have two drives on my single RQDXn, then the second hard disk 
> is /dev/ra1 and ra1a is (5,8), ra1b is (5,9), etc.  I guess the offset 
> of 8 must be the maximum number of partitions on a drive - OK, I'm 
> still with you.
>  
>   But what if I have a second MSCP controller?  Assuming that I've 
> built the kernel to handle it and modified dtab to autoconfigure it, 
> that is.  What are the usual names and mknod() numbers for the drives 
> on the second controller?
The second controller starts at ra8a (5, 8), and ra8a must be MSCP unit 0.
>   Worse, what if the MSCP controller isn't a RQDX but is a real 
> UDA/QDA ?  Now the drives have their own MSCP unit numbers that can be 
> anything from 0 to 250 - where does this figure in?
An MSCP unit number greater than 8 cannot be accessed from 2.11BSD.
>   Same question for TMSCP - what if I have more than one tape 
> controller?  This case is easier, though, since TMSCP controllers 
> normally have only one drive associated with them.
Don't know a think about it...
> Thanks,
> Bob Armstrong
>
-chuck




^ permalink raw reply	[flat|nested] 7+ messages in thread

* [pups] Major/minor device numbers and device names for MSCP drives?
  2006-06-19 21:43 ` C. H. Dickman
@ 2006-06-20 15:45   ` Robert Armstrong
  0 siblings, 0 replies; 7+ messages in thread
From: Robert Armstrong @ 2006-06-20 15:45 UTC (permalink / raw)


> C. H. Dickman writes:
>The 8 bit minor number has 3 parts: ...

  Thanks, Chuck - this is exactly what I wanted to know.  Now I've got to
try it out and see if I can get my SCSI ZIP drive talking to BSD.

Thanks again,
Bob






^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2006-06-20 15:45 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-06-19  3:15 [pups] Major/minor device numbers and device names for MSCP drives? Robert Armstrong
2006-06-19  6:57 ` Jochen Kunz
2006-06-19 14:51   ` Robert Armstrong
2006-06-19 15:08 ` Johnny Billquist
2006-06-19 21:43 ` C. H. Dickman
2006-06-20 15:45   ` Robert Armstrong
2006-06-19 21:53 ` C. H. Dickman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).