2000-10-27 19:12:41

by chris parker

[permalink] [raw]
Subject: Question: multiple major numbers - one driver



I have a need for more than 256 minor numbers. I could add some
more major numbers, thus getting the number of majors * 256.
I would like to have only device driver loaded to handle the
multiple majors.
I thoought of the following things that would have to be changed:

1) make the new device descriptors
2) add the new majors to the register_blkdev and unregister
system calls
3) process multiple CURRENT q's when receiving a request
from the block device layer. Each unique major has
a seperate incoming q.

Does any know of anything else that would prevent me from doing
this ??


2000-10-27 20:39:29

by Andreas Dilger

[permalink] [raw]
Subject: Re: Question: multiple major numbers - one driver

Chris Parker writes:
> I have a need for more than 256 minor numbers. I could add some
> more major numbers, thus getting the number of majors * 256.
> I would like to have only device driver loaded to handle the
> multiple majors.

Look at the SCSI/IDE/COMPAQ Smart RAID/etc drivers that have multiple
major numbers registered (per Documentation/devices.txt). Some of
the storage drivers have been allocating blocks of 8 major numbers at
a time.

Cheers, Andreas
--
Andreas Dilger \ "If a man ate a pound of pasta and a pound of antipasto,
\ would they cancel out, leaving him still hungry?"
http://www-mddsp.enel.ucalgary.ca/People/adilger/ -- Dogbert