Let me see if I understand: He wants to prevent a disk from mounting
until a later point in time. One suggestion is to flag the media as
removable in the SCSI filter. On CHECK_VERIFY command, you can return a
status indicating no media.
If this is not suitable, simply return an error code on the SRBs that
will force Windows to mark the disk offline. Then through a special SRB
(vendor specific) you can tell the device to come on-line whenever you
want.
Jamey
-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Peter Wieland
Sent: Friday, July 26, 2002 12:56 PM
To: NT Developers Interest List
Subject: [ntdev] Re: How to avoid FS mounting.
a “lower filter” is still above the PDO and still sees SRBs. There’s no
good way to insert yourself between the miniport and the hardware. If
he were to write an upper filter he would be loaded above the FDO and
thus would be unable to trap operations as they went up to the class
driver.
I wouldn’t normally want my first driver to be a file system, but that’s
because full-blown file systems are very complex. This wouldn’t be any
such thing. I do think it would be the best place for someone to block
mounts if they’re really not experienced with storage drivers, storage
devices, SCSI, tracking & updating the state of the device, backdoors
used by ASPI and the like, device specific inconsistancies in the way
they report new media, culling out false media change indications
(devices which report changes even though none occurred) and the general
architecture of the storage stack.
For an FS they only need to worry about one component.
-p
-----Original Message-----
From: Stu Bell [mailto:xxxxx@dataplay.com]
Sent: Friday, July 26, 2002 12:27 PM
To: NT Developers Interest List
Subject: [ntdev] Re: How to avoid FS mounting.
Peter Wieland wrote…
being a lower filter won’t keep all i/o requests from getting to the
device. ASPI (for example) goes around behind the disk driver’s back
and sends requests directly to the port driver’s FDO…
The original poster said he had a lower filter on the SCSI driver rather
than the class driver. Even so, what you say makes sense.
Perhaps an upper filter on the SCSI driver would be better, since at
that point all of the calls will be SRBs and URBs instead of hardware
controller stuff dependent on the miniport implementation.
Even so, at least one CD-writing tool that I heard of ties into the
stack as a SCSI filter driver. That definitely limits the options if
the original poster is trying to support CD media.
writing a simple file system which only allows DASD access to
the media is probably not that hard. The RAW filesystem in NT
is only about 3000 lines of code and it does much of what I think
you’d want to do.
Cool - is there source on that in the IFS kit? If not, I would not
recommend it to a neophyte. The original poster did not seem to have
much background in driver writing (I could be wrong), so I was steering
him away from IFS. I certainly wouldn’t want an FS to be MY first intro
to driver writing!
Stu Bell
You are currently subscribed to ntdev as: xxxxx@microsoft.com To
unsubscribe send a blank email to %%email.unsub%%
You are currently subscribed to ntdev as: xxxxx@storagecraft.com
To unsubscribe send a blank email to %%email.unsub%%