How to properly install a disk class driver??

I am developing a driver based on disk.sys which will claim certain disks
and use them for other purposes outside of the normal Disk Administrator.

The question I have involves installation and calling order. When the
system is booted, it is essential that my driver be allowed to claim disks
prior to the normal disk.sys. Also, when a new disk is added the same
applies.

This probably seems like a stupid question, but how do I go about making
sure that my driver gets called before disk.sys??

I am also curious to know if I could do this with a filter driver and
avoid the whole problem. At first I thought this was the way to do it, but
then I read that filter drivers are not allowed to claim disks.

Thanks in advance for any suggetsions,

Don

It is difficult to tell what you are really trying to do here, but a clone
of disk.sys is unlikely to work as you seem to require. The problem is PnP
enumeration, which is always going to choose disk.sys for PDOs that are
enumerated as type GenericDisk, ScsiDisk, etc. You could of course somehow
convince the system that your PDOs of interest have a different enumeration
string (e.g. EdvalsonDisk,) and make your EdvalsonDiskClone driver the FDO
for things enumerated as EdvalsonDisk, then you could do whatever you want
with these specific disks.

-----Original Message-----
From: Don Edvalson [mailto:xxxxx@pinnaclesys.com]
Sent: Tuesday, May 13, 2003 4:10 PM
To: NT Developers Interest List
Subject: [ntdev] How to properly install a disk class driver??

I am developing a driver based on disk.sys which will claim
certain disks and use them for other purposes outside of the
normal Disk Administrator.

The question I have involves installation and calling order.
When the system is booted, it is essential that my driver be
allowed to claim disks prior to the normal disk.sys. Also,
when a new disk is added the same applies.

This probably seems like a stupid question, but how do I go
about making sure that my driver gets called before disk.sys??

I am also curious to know if I could do this with a filter
driver and avoid the whole problem. At first I thought this
was the way to do it, but then I read that filter drivers are
not allowed to claim disks.

Thanks in advance for any suggetsions,

Don


You are currently subscribed to ntdev as:
xxxxx@stratus.com To unsubscribe send a blank email to
xxxxx@lists.osr.com

Or use the SetupDI API to change the service on the disks you’re
interested in to EdvalsonDisk.sys instead of disk.sys

-p

-----Original Message-----
From: Roddy, Mark [mailto:xxxxx@stratus.com]
Sent: Tuesday, May 13, 2003 1:31 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

It is difficult to tell what you are really trying to do here, but a
clone of disk.sys is unlikely to work as you seem to require. The
problem is PnP enumeration, which is always going to choose disk.sys for
PDOs that are enumerated as type GenericDisk, ScsiDisk, etc. You could
of course somehow convince the system that your PDOs of interest have a
different enumeration string (e.g. EdvalsonDisk,) and make your
EdvalsonDiskClone driver the FDO for things enumerated as EdvalsonDisk,
then you could do whatever you want with these specific disks.

-----Original Message-----
From: Don Edvalson [mailto:xxxxx@pinnaclesys.com]
Sent: Tuesday, May 13, 2003 4:10 PM
To: NT Developers Interest List
Subject: [ntdev] How to properly install a disk class driver??

I am developing a driver based on disk.sys which will claim certain
disks and use them for other purposes outside of the normal Disk
Administrator.

The question I have involves installation and calling order.
When the system is booted, it is essential that my driver be allowed
to claim disks prior to the normal disk.sys. Also, when a new disk is
added the same applies.

This probably seems like a stupid question, but how do I go about
making sure that my driver gets called before disk.sys??

I am also curious to know if I could do this with a filter driver and
avoid the whole problem. At first I thought this was the way to do it,

but then I read that filter drivers are not allowed to claim disks.

Thanks in advance for any suggetsions,

Don


You are currently subscribed to ntdev as:
xxxxx@stratus.com To unsubscribe send a blank email to
xxxxx@lists.osr.com


You are currently subscribed to ntdev as: xxxxx@microsoft.com To
unsubscribe send a blank email to xxxxx@lists.osr.com

Peter’s suggestion will work only if the disks you’re interested in are
presented to the host when you run this program (which calls SetupDI
API’s). I don’t think it will work for newly added disks. For that you
might have to write a filter to change service. Sounds like you might
need more than 1 driver for what you need to do.

Rupin

-----Original Message-----
From: Peter Wieland [mailto:xxxxx@windows.microsoft.com]
Sent: Tuesday, May 13, 2003 4:35 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

Or use the SetupDI API to change the service on the disks you’re
interested in to EdvalsonDisk.sys instead of disk.sys

-p

-----Original Message-----
From: Roddy, Mark [mailto:xxxxx@stratus.com]
Sent: Tuesday, May 13, 2003 1:31 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

It is difficult to tell what you are really trying to do here, but a
clone of disk.sys is unlikely to work as you seem to require. The
problem is PnP enumeration, which is always going to choose disk.sys for
PDOs that are enumerated as type GenericDisk, ScsiDisk, etc. You could
of course somehow convince the system that your PDOs of interest have a
different enumeration string (e.g. EdvalsonDisk,) and make your
EdvalsonDiskClone driver the FDO for things enumerated as EdvalsonDisk,
then you could do whatever you want with these specific disks.

-----Original Message-----
From: Don Edvalson [mailto:xxxxx@pinnaclesys.com]
Sent: Tuesday, May 13, 2003 4:10 PM
To: NT Developers Interest List
Subject: [ntdev] How to properly install a disk class driver??

I am developing a driver based on disk.sys which will claim certain
disks and use them for other purposes outside of the normal Disk
Administrator.

The question I have involves installation and calling order.
When the system is booted, it is essential that my driver be allowed
to claim disks prior to the normal disk.sys. Also, when a new disk is
added the same applies.

This probably seems like a stupid question, but how do I go about
making sure that my driver gets called before disk.sys??

I am also curious to know if I could do this with a filter driver and
avoid the whole problem. At first I thought this was the way to do it,

but then I read that filter drivers are not allowed to claim disks.

Thanks in advance for any suggetsions,

Don


You are currently subscribed to ntdev as:
xxxxx@stratus.com To unsubscribe send a blank email to
xxxxx@lists.osr.com


You are currently subscribed to ntdev as: xxxxx@microsoft.com To
unsubscribe send a blank email to xxxxx@lists.osr.com


You are currently subscribed to ntdev as: rupin.mohan@hp.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

You could use a SCSI filter and trap the INQUIRY path. Doing this, you
can do one of several things:

  • Simply remove the device from the INQUIRY data before returning to the
    caller. This will completely remove the device and your filter would
    need to have a special interface (or SRB path) to allow you to talk to
    this disk; since the disk class driver will not see it; nor bill any
    SCSI bus enumerator.

  • Change the device type to some new device type. For example, if you
    wanted the disk to show up as a tape device and implement a tape
    command-set, change the type in the return INQUIRY data and then hook
    the SRB path to support this new device type.

Depending on what you are doing, you may need to do some experimenting
to understand the interfaces and all of their quirks.

It may help to know what you are emulating; CD, DVD, Tape…

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Don Edvalson
Sent: Tuesday, May 13, 2003 1:10 PM
To: NT Developers Interest List
Subject: [ntdev] How to properly install a disk class driver??

I am developing a driver based on disk.sys which will claim certain
disks
and use them for other purposes outside of the normal Disk
Administrator.

The question I have involves installation and calling order. When the
system is booted, it is essential that my driver be allowed to claim
disks
prior to the normal disk.sys. Also, when a new disk is added the same
applies.

This probably seems like a stupid question, but how do I go about making
sure that my driver gets called before disk.sys??

I am also curious to know if I could do this with a filter driver and
avoid the whole problem. At first I thought this was the way to do it,
but
then I read that filter drivers are not allowed to claim disks.

Thanks in advance for any suggetsions,

Don


You are currently subscribed to ntdev as: xxxxx@storagecraft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

I guess I should have been more specific in describing what I was trying
to do.

I am only interested in disks. I have no interest in CDs, Tapes, etc. What
I am trying to acomplish is actually two fold.

First, I want to make some disks disappear as far as normal disk
management is concerned. Ideally, they should not even appear in the Disk
Manager applet. I think maybe I can do this with an upper filter driver
that simply prevents AddDevice requests from ever getting to disk.sys.
However I don’t know yet if this will work with devices that are already
there at boot time.

Second, I want to make psuedo disks that are various combinations or
subsets of the disks that I made disappear. Ideally, these would appear in
the disk manager applet. I think I can do this with a disk.sys clone that
creates these psuedo disk devices.

Again, any comments or suggestions will be greatly appreciated.

Thanks,

Don

Don,

  1. Writing your own class driver is a bad idea. Is there a need to get
    this driver WHQL’d? Good luck.
  2. Sounds like you need a bus driver and a filter driver.
  3. Be prepared to write utilities that will do registry cleaning for
    disks that have already been seen by OS.

Rupin

-----Original Message-----
From: Don Edvalson [mailto:xxxxx@pinnaclesys.com]
Sent: Tuesday, May 13, 2003 5:50 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

I guess I should have been more specific in describing what I was trying
to do.

I am only interested in disks. I have no interest in CDs, Tapes, etc.
What I am trying to acomplish is actually two fold.

First, I want to make some disks disappear as far as normal disk
management is concerned. Ideally, they should not even appear in the
Disk Manager applet. I think maybe I can do this with an upper filter
driver that simply prevents AddDevice requests from ever getting to
disk.sys. However I don’t know yet if this will work with devices that
are already there at boot time.

Second, I want to make psuedo disks that are various combinations or
subsets of the disks that I made disappear. Ideally, these would appear
in the disk manager applet. I think I can do this with a disk.sys clone
that creates these psuedo disk devices.

Again, any comments or suggestions will be greatly appreciated.

Thanks,

Don


You are currently subscribed to ntdev as: rupin.mohan@hp.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

This is precisely how FTDISK works. Well, this is how it worked under NT
4.0. It is a little more complex under 2K and XP.

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Don Edvalson
Sent: Tuesday, May 13, 2003 2:50 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

I guess I should have been more specific in describing what I was trying
to do.

I am only interested in disks. I have no interest in CDs, Tapes, etc.
What
I am trying to acomplish is actually two fold.

First, I want to make some disks disappear as far as normal disk
management is concerned. Ideally, they should not even appear in the
Disk
Manager applet. I think maybe I can do this with an upper filter driver
that simply prevents AddDevice requests from ever getting to disk.sys.
However I don’t know yet if this will work with devices that are already
there at boot time.

Second, I want to make psuedo disks that are various combinations or
subsets of the disks that I made disappear. Ideally, these would appear
in
the disk manager applet. I think I can do this with a disk.sys clone
that
creates these psuedo disk devices.

Again, any comments or suggestions will be greatly appreciated.

Thanks,

Don


You are currently subscribed to ntdev as: xxxxx@storagecraft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

Ah yes… You guy have that Virtual storage thing you inherited from
DEC/Compaq :slight_smile:

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Mohan, Rupin
Sent: Tuesday, May 13, 2003 3:17 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

Don,

  1. Writing your own class driver is a bad idea. Is there a need to get
    this driver WHQL’d? Good luck.
  2. Sounds like you need a bus driver and a filter driver.
  3. Be prepared to write utilities that will do registry cleaning for
    disks that have already been seen by OS.

Rupin

-----Original Message-----
From: Don Edvalson [mailto:xxxxx@pinnaclesys.com]
Sent: Tuesday, May 13, 2003 5:50 PM
To: NT Developers Interest List
Subject: [ntdev] RE: How to properly install a disk class driver??

I guess I should have been more specific in describing what I was trying
to do.

I am only interested in disks. I have no interest in CDs, Tapes, etc.
What I am trying to acomplish is actually two fold.

First, I want to make some disks disappear as far as normal disk
management is concerned. Ideally, they should not even appear in the
Disk Manager applet. I think maybe I can do this with an upper filter
driver that simply prevents AddDevice requests from ever getting to
disk.sys. However I don’t know yet if this will work with devices that
are already there at boot time.

Second, I want to make psuedo disks that are various combinations or
subsets of the disks that I made disappear. Ideally, these would appear
in the disk manager applet. I think I can do this with a disk.sys clone
that creates these psuedo disk devices.

Again, any comments or suggestions will be greatly appreciated.

Thanks,

Don


You are currently subscribed to ntdev as: rupin.mohan@hp.com
To unsubscribe send a blank email to xxxxx@lists.osr.com


You are currently subscribed to ntdev as: xxxxx@storagecraft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

What are the “certain” disks? The disks with certain SCSI INQUIRY
data? then install your driver as a PnP function driver with an INF
file for particular SCSI device ID, the Disk.sys is for GenDisk only,
better match must play.

Max

----- Original Message -----
From: “Don Edvalson”
To: “NT Developers Interest List”
Sent: Wednesday, May 14, 2003 12:09 AM
Subject: [ntdev] How to properly install a disk class driver??

> I am developing a driver based on disk.sys which will claim certain
disks
> and use them for other purposes outside of the normal Disk
Administrator.
>
> The question I have involves installation and calling order. When
the
> system is booted, it is essential that my driver be allowed to claim
disks
> prior to the normal disk.sys. Also, when a new disk is added the
same
> applies.
>
> This probably seems like a stupid question, but how do I go about
making
> sure that my driver gets called before disk.sys??
>
> I am also curious to know if I could do this with a filter driver
and
> avoid the whole problem. At first I thought this was the way to do
it, but
> then I read that filter drivers are not allowed to claim disks.
>
> Thanks in advance for any suggetsions,
>
> Don
>
>
> —
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to
xxxxx@lists.osr.com

Actually they are any disks with certain data on them. There is a signature
that we look for.

“Maxim S. Shatskih” wrote in message
news:xxxxx@ntdev…
>
> What are the “certain” disks? The disks with certain SCSI INQUIRY
> data? then install your driver as a PnP function driver with an INF
> file for particular SCSI device ID, the Disk.sys is for GenDisk only,
> better match must play.
>
> Max
>
> ----- Original Message -----
> From: “Don Edvalson”
> To: “NT Developers Interest List”
> Sent: Wednesday, May 14, 2003 12:09 AM
> Subject: [ntdev] How to properly install a disk class driver??
>
>
> > I am developing a driver based on disk.sys which will claim certain
> disks
> > and use them for other purposes outside of the normal Disk
> Administrator.
> >
> > The question I have involves installation and calling order. When
> the
> > system is booted, it is essential that my driver be allowed to claim
> disks
> > prior to the normal disk.sys. Also, when a new disk is added the
> same
> > applies.
> >
> > This probably seems like a stupid question, but how do I go about
> making
> > sure that my driver gets called before disk.sys??
> >
> > I am also curious to know if I could do this with a filter driver
> and
> > avoid the whole problem. At first I thought this was the way to do
> it, but
> > then I read that filter drivers are not allowed to claim disks.
> >
> > Thanks in advance for any suggetsions,
> >
> > Don
> >
> >
> > —
> > You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> > To unsubscribe send a blank email to
> xxxxx@lists.osr.com
>
>
>
>

Then write a disk filter, which will be idle pass-down on any disks
except yours.

Max

----- Original Message -----
From: “Don”
Newsgroups: ntdev
To: “NT Developers Interest List”
Sent: Wednesday, May 14, 2003 11:53 PM
Subject: [ntdev] Re: How to properly install a disk class driver??

> Actually they are any disks with certain data on them. There is a
signature
> that we look for.
>
>
> “Maxim S. Shatskih” wrote in message
> news:xxxxx@ntdev…
> >
> > What are the “certain” disks? The disks with certain SCSI INQUIRY
> > data? then install your driver as a PnP function driver with an
INF
> > file for particular SCSI device ID, the Disk.sys is for GenDisk
only,
> > better match must play.
> >
> > Max
> >
> > ----- Original Message -----
> > From: “Don Edvalson”
> > To: “NT Developers Interest List”
> > Sent: Wednesday, May 14, 2003 12:09 AM
> > Subject: [ntdev] How to properly install a disk class driver??
> >
> >
> > > I am developing a driver based on disk.sys which will claim
certain
> > disks
> > > and use them for other purposes outside of the normal Disk
> > Administrator.
> > >
> > > The question I have involves installation and calling order.
When
> > the
> > > system is booted, it is essential that my driver be allowed to
claim
> > disks
> > > prior to the normal disk.sys. Also, when a new disk is added the
> > same
> > > applies.
> > >
> > > This probably seems like a stupid question, but how do I go
about
> > making
> > > sure that my driver gets called before disk.sys??
> > >
> > > I am also curious to know if I could do this with a filter
driver
> > and
> > > avoid the whole problem. At first I thought this was the way to
do
> > it, but
> > > then I read that filter drivers are not allowed to claim disks.
> > >
> > > Thanks in advance for any suggetsions,
> > >
> > > Don
> > >
> > >
> > > —
> > > You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> > > To unsubscribe send a blank email to
> > xxxxx@lists.osr.com
> >
> >
> >
> >
>
>
>
> —
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to
xxxxx@lists.osr.com