SCSI Miniport on 9x

I know it is not the standard practice to use any other than ScsiPortxxx APIs in SCSI miniports. However, I tried to use some ‘WDM’ exported functions (like getting other driver device object, creating IRP, and calling another driver with that irp.) And it worked like a charm. So, before getting deeper into the rabbit hole, I am curious, is 9x miniport (actually NT miniport, running on 9x) uses VxD VMM, or is it living on WDM world? Then does the class part of the driver uses any VxD services?
The reasoning behind this is to use KeWaitForSingleObject on event inside the miniport driver. However, I know if VxD services get’s used, then this wait would hang an arbitrary thread on 9x,… and the system will die…

Thanks in advance,

Paul

I’ll say it … not recommended. Serialization and synchronization is
handled by SCSIPORT, and it m akes absolutely no allowance for edges that
might be linked with the DDK. You have no way of serializing access with
SCSIPORT. Methinks that what you are doing, waiting in your won thread is
simply going to throw a monkey wrench into wobbly gears. Sometimes you won’t
know the wrench was there … other times you are going to wonder why you
are looking at a BSOD.


Gary G. Little
Have Computer, Will Travel …
909-698-3191
909-551-2105

wrote in message news:xxxxx@ntdev…
>
> I know it is not the standard practice to use any other than ScsiPortxxx
APIs in SCSI miniports. However, I tried to use some ‘WDM’ exported
functions (like getting other driver device object, creating IRP, and
calling another driver with that irp.) And it worked like a charm. So,
before getting deeper into the rabbit hole, I am curious, is 9x miniport
(actually NT miniport, running on 9x) uses VxD VMM, or is it living on WDM
world? Then does the class part of the driver uses any VxD services?
> The reasoning behind this is to use KeWaitForSingleObject on event inside
the miniport driver. However, I know if VxD services get’s used, then this
wait would hang an arbitrary thread on 9x,… and the system will die…
>
> Thanks in advance,
>
> Paul
>
>
>

Hm… interesting, I’ll have to keep an eye on those gears I guess with vigorous testing…
Now, do you know if the SCSIPORT uses any at all VxD services on 9x?

Paul

-----Original Message-----
From: Gary G. Little [mailto:xxxxx@inland.net]
Sent: Thursday, January 16, 2003 2:25 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

I’ll say it … not recommended. Serialization and synchronization is
handled by SCSIPORT, and it m akes absolutely no allowance for edges that
might be linked with the DDK. You have no way of serializing access with
SCSIPORT. Methinks that what you are doing, waiting in your won thread is
simply going to throw a monkey wrench into wobbly gears. Sometimes you won’t
know the wrench was there … other times you are going to wonder why you
are looking at a BSOD.


Gary G. Little
Have Computer, Will Travel …
909-698-3191
909-551-2105

wrote in message news:xxxxx@ntdev…
>
> I know it is not the standard practice to use any other than ScsiPortxxx
APIs in SCSI miniports. However, I tried to use some ‘WDM’ exported
functions (like getting other driver device object, creating IRP, and
calling another driver with that irp.) And it worked like a charm. So,
before getting deeper into the rabbit hole, I am curious, is 9x miniport
(actually NT miniport, running on 9x) uses VxD VMM, or is it living on WDM
world? Then does the class part of the driver uses any VxD services?
> The reasoning behind this is to use KeWaitForSingleObject on event inside
the miniport driver. However, I know if VxD services get’s used, then this
wait would hang an arbitrary thread on 9x,… and the system will die…
>
> Thanks in advance,
>
> Paul
>
>
>


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

wrote in message news:xxxxx@ntdev…
>
> Hm… interesting, I’ll have to keep an eye on those gears I guess with
vigorous testing…
> Now, do you know if the SCSIPORT uses any at all VxD services on 9x?
>
> Paul

Run dumpbin /imports over the SCSIPORT and that will tell you what it uses.

I had an ATA/ATAPI SCSI miniport at Intel that did all kinds of things that
you aren’t supposed to do, such as memory allocation and registry access.
However, this one was never intended to be more than a technology demo, and
it never shipped to a customer or end user. If you intend to ship it to
customers, or you intend to get it WHQL’ed for WinMe, don’t color outside
the lines.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.

On 98SE I’ve only found Scsi1Hlp.VxD, ScsiPort.Pdr, and Portcls.sys, but no scsiport.sys. It looks to me that the ScsiPort.pdr is the winner to be a classport for NT miniport, am I right? If so, then I am in deep sh.t, bacause it is a plain VxD… and I can’t use ‘any legal’ NT kernel api’s…

-----Original Message-----
From: Phil Barila [mailto:xxxxx@Seagate.com]
Sent: Thursday, January 16, 2003 3:27 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

wrote in message news:xxxxx@ntdev…
>
> Hm… interesting, I’ll have to keep an eye on those gears I guess with
vigorous testing…
> Now, do you know if the SCSIPORT uses any at all VxD services on 9x?
>
> Paul

Run dumpbin /imports over the SCSIPORT and that will tell you what it uses.

I had an ATA/ATAPI SCSI miniport at Intel that did all kinds of things that
you aren’t supposed to do, such as memory allocation and registry access.
However, this one was never intended to be more than a technology demo, and
it never shipped to a customer or end user. If you intend to ship it to
customers, or you intend to get it WHQL’ed for WinMe, don’t color outside
the lines.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.


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

wrote in message news:xxxxx@ntdev…
>
> On 98SE I’ve only found Scsi1Hlp.VxD, ScsiPort.Pdr, and Portcls.sys, but
> no scsiport.sys. It looks to me that the ScsiPort.pdr is the winner to be
> a classport for NT miniport, am I right? If so, then I am in deep sh.t,
> bacause it is a plain VxD… and I can’t use ‘any legal’ NT kernel
> api’s…

ScsiPort.Pdr is the port driver, I don’t know what the other two do, and I
don’t want to get near enough to a Win9X box to find out.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.

That is right, scsiport.pdr is the SCSIPORT; it is implemented as a port
driver VxD.

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Phil Barila
Sent: Thursday, January 16, 2003 3:28 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

wrote in message news:xxxxx@ntdev…
>
> On 98SE I’ve only found Scsi1Hlp.VxD, ScsiPort.Pdr, and Portcls.sys,
but
> no scsiport.sys. It looks to me that the ScsiPort.pdr is the winner
to be
> a classport for NT miniport, am I right? If so, then I am in deep
sh.t,
> bacause it is a plain VxD… and I can’t use ‘any legal’ NT kernel
> api’s…

ScsiPort.Pdr is the port driver, I don’t know what the other two do, and
I
don’t want to get near enough to a Win9X box to find out.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.


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

So, my next question would be - is there a way from VxD to call WDM driver using standard IRP techniques (i.e. using IoCallDriver, but without using KEVENT for building synchronous IoBuildDeviceIoControlRequest ioctl IRP? 'cause VxD can’t really handle KeWaitForSingleObject on event properly?

Thanks in Advance,

Paul

-----Original Message-----
From: Jamey Kirby [mailto:xxxxx@storagecraft.com]
Sent: Thursday, January 16, 2003 6:37 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

That is right, scsiport.pdr is the SCSIPORT; it is implemented as a port
driver VxD.

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Phil Barila
Sent: Thursday, January 16, 2003 3:28 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

wrote in message news:xxxxx@ntdev…
>
> On 98SE I’ve only found Scsi1Hlp.VxD, ScsiPort.Pdr, and Portcls.sys,
but
> no scsiport.sys. It looks to me that the ScsiPort.pdr is the winner
to be
> a classport for NT miniport, am I right? If so, then I am in deep
sh.t,
> bacause it is a plain VxD… and I can’t use ‘any legal’ NT kernel
> api’s…

ScsiPort.Pdr is the port driver, I don’t know what the other two do, and
I
don’t want to get near enough to a Win9X box to find out.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.


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@krollontrack.com
To unsubscribe send a blank email to xxxxx@lists.osr.com

I suspect it is possible, but it would take longer to do this than to
just implement your own SCSI port driver for 9x; I have done it in the
past and it is not so difficult.

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@KrollOntrack.com
Sent: Friday, January 17, 2003 10:18 AM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

So, my next question would be - is there a way from VxD to call WDM
driver using standard IRP techniques (i.e. using IoCallDriver, but
without using KEVENT for building synchronous
IoBuildDeviceIoControlRequest ioctl IRP? 'cause VxD can’t really handle
KeWaitForSingleObject on event properly?

Thanks in Advance,

Paul

-----Original Message-----
From: Jamey Kirby [mailto:xxxxx@storagecraft.com]
Sent: Thursday, January 16, 2003 6:37 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

That is right, scsiport.pdr is the SCSIPORT; it is implemented as a port
driver VxD.

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Phil Barila
Sent: Thursday, January 16, 2003 3:28 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

wrote in message news:xxxxx@ntdev…
>
> On 98SE I’ve only found Scsi1Hlp.VxD, ScsiPort.Pdr, and Portcls.sys,
but
> no scsiport.sys. It looks to me that the ScsiPort.pdr is the winner
to be
> a classport for NT miniport, am I right? If so, then I am in deep
sh.t,
> bacause it is a plain VxD… and I can’t use ‘any legal’ NT kernel
> api’s…

ScsiPort.Pdr is the port driver, I don’t know what the other two do, and
I
don’t want to get near enough to a Win9X box to find out.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.


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@krollontrack.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

My own port on 9x?! Hm… do you mean making it WDM port instead of OSes VxD one?

-----Original Message-----
From: Jamey Kirby [mailto:xxxxx@storagecraft.com]
Sent: Friday, January 17, 2003 12:31 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

I suspect it is possible, but it would take longer to do this than to
just implement your own SCSI port driver for 9x; I have done it in the
past and it is not so difficult.

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of
xxxxx@KrollOntrack.com
Sent: Friday, January 17, 2003 10:18 AM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

So, my next question would be - is there a way from VxD to call WDM
driver using standard IRP techniques (i.e. using IoCallDriver, but
without using KEVENT for building synchronous
IoBuildDeviceIoControlRequest ioctl IRP? 'cause VxD can’t really handle
KeWaitForSingleObject on event properly?

Thanks in Advance,

Paul

-----Original Message-----
From: Jamey Kirby [mailto:xxxxx@storagecraft.com]
Sent: Thursday, January 16, 2003 6:37 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

That is right, scsiport.pdr is the SCSIPORT; it is implemented as a port
driver VxD.

Jamey

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Phil Barila
Sent: Thursday, January 16, 2003 3:28 PM
To: NT Developers Interest List
Subject: [ntdev] Re: SCSI Miniport on 9x

wrote in message news:xxxxx@ntdev…
>
> On 98SE I’ve only found Scsi1Hlp.VxD, ScsiPort.Pdr, and Portcls.sys,
but
> no scsiport.sys. It looks to me that the ScsiPort.pdr is the winner
to be
> a classport for NT miniport, am I right? If so, then I am in deep
sh.t,
> bacause it is a plain VxD… and I can’t use ‘any legal’ NT kernel
> api’s…

ScsiPort.Pdr is the port driver, I don’t know what the other two do, and
I
don’t want to get near enough to a Win9X box to find out.

Phil

Philip D. Barila
Seagate Technology, LLC
(720) 684-1842
As if I need to say it: Not speaking for Seagate.


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@krollontrack.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


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

You cannot, since SCSIPORT calls the miniport in a nasty context with
spinlocks held.
You will need a full SCSI port driver for such.

Max

----- Original Message -----
From:
To: “NT Developers Interest List”
Sent: Thursday, January 16, 2003 9:46 PM
Subject: [ntdev] SCSI Miniport on 9x

> I know it is not the standard practice to use any other than
ScsiPortxxx APIs in SCSI miniports. However, I tried to use some
‘WDM’ exported functions (like getting other driver device object,
creating IRP, and calling another driver with that irp.) And it
worked like a charm. So, before getting deeper into the rabbit hole,
I am curious, is 9x miniport (actually NT miniport, running on 9x)
uses VxD VMM, or is it living on WDM world? Then does the class part
of the driver uses any VxD services?
> The reasoning behind this is to use KeWaitForSingleObject on event
inside the miniport driver. However, I know if VxD services get’s
used, then this wait would hang an arbitrary thread on 9x,… and the
system will die…
>
> Thanks in advance,
>
> Paul
>
>
> —
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to xxxxx@lists.osr.com
>