Function to find if system is fully initialized

Hello,

Is there any function I can call in my Win2K Bus Driver, to find out if the
system has been fully initialized ?

Thanks
Puja

Define fully initialized. Does you driver have to wait for another driver to
load?

Jim

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@usa.net
Sent: Tuesday, May 30, 2000 3:00 PM
To: NT Developers Interest List
Subject: [ntdev] Function to find if system is fully initialized

Hello,

Is there any function I can call in my Win2K Bus Driver, to find out if the
system has been fully initialized ?

Thanks
Puja


You are currently subscribed to ntdev as: xxxxx@youngendeavors.com
To unsubscribe send a blank email to $subst(‘Email.Unsub’)

No my driver does NOT have to wait for another driver to load. The problem
is that I was creating a RealTime thread in my Bus Driver (priority
HIGH_PRIORITY),
and everything would work fine if my driver was loaded when the system was
up and running.

But if the system was rebooted with my driver, then it would (appear to)
hang at initialization time. I verified that this was because of the RT
thread (as soon as I NOT set the priority of my thread to RT, the system
boots fine).

So I would like to modify my driver such that it waits for the system to
fully initialize (I’m hoping there’s some function I can call to check
this), and then sets the priority of my thread to RT.

Any suggestions are appreciated!

Thanks
Puja

On 05/30/00, ““Jim Young” ” wrote:
> Define fully initialized. Does you driver have to wait for another driver to
> load?
>
> Jim
>
> -----Original Message-----
> From: xxxxx@lists.osr.com
> [mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@usa.net
> Sent: Tuesday, May 30, 2000 3:00 PM
> To: NT Developers Interest List
> Subject: [ntdev] Function to find if system is fully initialized
>
>
> Hello,
>
> Is there any function I can call in my Win2K Bus Driver, to find out if the
> system has been fully initialized ?
>
> Thanks
> Puja
>
> —
> You are currently subscribed to ntdev as: xxxxx@youngendeavors.com
> To unsubscribe send a blank email to $subst(‘Email.Unsub’)

I hope you are not setting your startup paramater for the driver to
be boot time startup.

You can setup the Group order for the driver so that it starts up in some
sequence which will work fine,

alternatively,

if you want to change the priority of your thread after system boots up
then you can add an I/O request in your driver which changes the priority
of the thread and call it through an application.

sachin

-----Original Message-----
From: xxxxx@usa.net [mailto:xxxxx@usa.net]
Sent: Monday, May 29, 2000 6:00 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Function to find if system is fully initialized

No my driver does NOT have to wait for another driver to
load. The problem
is that I was creating a RealTime thread in my Bus Driver (priority
HIGH_PRIORITY),
and everything would work fine if my driver was loaded when
the system was
up and running.

But if the system was rebooted with my driver, then it would
(appear to)
hang at initialization time. I verified that this was
because of the RT
thread (as soon as I NOT set the priority of my thread to RT,
the system
boots fine).

So I would like to modify my driver such that it waits for
the system to
fully initialize (I’m hoping there’s some function I can call
to check
this), and then sets the priority of my thread to RT.

Any suggestions are appreciated!

Thanks
Puja

On 05/30/00, ““Jim Young” ” wrote:
> > Define fully initialized. Does you driver have to wait for
> another driver to
> > load?
> >
> > Jim
> >
> > -----Original Message-----
> > From: xxxxx@lists.osr.com
> > [mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@usa.net
> > Sent: Tuesday, May 30, 2000 3:00 PM
> > To: NT Developers Interest List
> > Subject: [ntdev] Function to find if system is fully initialized
> >
> >
> > Hello,
> >
> > Is there any function I can call in my Win2K Bus Driver, to
> find out if the
> > system has been fully initialized ?
> >
> > Thanks
> > Puja
> >
> > —
> > You are currently subscribed to ntdev as: xxxxx@youngendeavors.com
> > To unsubscribe send a blank email to $subst(‘Email.Unsub’)
>
> —
> You are currently subscribed to ntdev as: xxxxx@efi.com
> To unsubscribe send a blank email to $subst(‘Email.Unsub’)
>

Hi Sachin,

The “LoadOrderGroup” parameter in my INF file is set to “Extended Base”.
What are the other possible values for this and their meaning ?

What is the “Startup” parameter you are referring to ? “StartType” in my
case is “SERVICE_DEMAND_START”.

Basically I want my Bus to be enumerated by the PNP Manager, should this
be done at a particular time ? If so, when ?

Thanks
Puja

On 05/30/00, “Sachin Maheshwari ” wrote:
> This message is in MIME format. Since your mail reader does not understand
> this format, some or all of this message may not be legible.
>
> ------_=_NextPart_001_01BFCA8E.B8BF7E6C
> Content-Type: text/plain;
> charset=“iso-8859-1”
>
> I hope you are not setting your startup paramater for the driver to
> be boot time startup.
>
> You can setup the Group order for the driver so that it starts up in some
> sequence which will work fine,
>
> alternatively,
>
> if you want to change the priority of your thread after system boots up
> then you can add an I/O request in your driver which changes the priority
> of the thread and call it through an application.
>
> sachin
>
> > -----Original Message-----
> > From: xxxxx@usa.net [mailto:xxxxx@usa.net]
> > Sent: Monday, May 29, 2000 6:00 PM
> > To: NT Developers Interest List
> > Subject: [ntdev] RE: Function to find if system is fully initialized
> >
> >
> >
> > No my driver does NOT have to wait for another driver to
> > load. The problem
> > is that I was creating a RealTime thread in my Bus Driver (priority
> > HIGH_PRIORITY),
> > and everything would work fine if my driver was loaded when
> > the system was
> > up and running.
> >
> > But if the system was rebooted with my driver, then it would
> > (appear to)
> > hang at initialization time. I verified that this was
> > because of the RT
> > thread (as soon as I NOT set the priority of my thread to RT,
> > the system
> > boots fine).
> >
> > So I would like to modify my driver such that it waits for
> > the system to
> > fully initialize (I’m hoping there’s some function I can call
> > to check
> > this), and then sets the priority of my thread to RT.
> >
> > Any suggestions are appreciated!
> >
> > Thanks
> > Puja
> >
> >
> > On 05/30/00, ““Jim Young” ” wrote:
> > > Define fully initialized. Does you driver have to wait for
> > another driver to
> > > load?
> > >
> > > Jim
> > >
> > > -----Original Message-----
> > > From: xxxxx@lists.osr.com
> > > [mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@usa.net
> > > Sent: Tuesday, May 30, 2000 3:00 PM
> > > To: NT Developers Interest List
> > > Subject: [ntdev] Function to find if system is fully initialized
> > >
> > >
> > > Hello,
> > >
> > > Is there any function I can call in my Win2K Bus Driver, to
> > find out if the
> > > system has been fully initialized ?
> > >
> > > Thanks
> > > Puja
> > >

If you aren’t a BootStart PnP driver then load order is determined by the
undisclosed enumeration ordering of the PnP Manager, i.e. it is unspecified
and out of your control. The rules are somewhat different for BootStart PnP
drivers. Your driver entry routine, if I recall correctly will behave like
an NT4 driver with respect to group, tag etc. Your AddDevice routine will
behave like any other PnP driver: its called when the PnP Manager feels like
it as a result of enumeration.

Might I suggest that a small service application would be sufficient to
inform your driver about when it would be a good time to start or activate
your real time thread? This would guarantee that the system is operational
enough to permit user space applications. You can simply clone the available
C++ or C templates for service applications and build the puppy in a day or
less. Search MSDN and you will find sample source code.

Mark Roddy
Windows 2000/NT Consultant
Hollis Technology Solutions
www.hollistech.com

-----Original Message-----
From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@usa.net
Sent: Tuesday, May 30, 2000 8:22 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Function to find if system is fully initialized

Hi Sachin,

The “LoadOrderGroup” parameter in my INF file is set to “Extended Base”.
What are the other possible values for this and their meaning ?

What is the “Startup” parameter you are referring to ? “StartType” in my
case is “SERVICE_DEMAND_START”.

Basically I want my Bus to be enumerated by the PNP Manager, should this
be done at a particular time ? If so, when ?

Thanks
Puja

On 05/30/00, “Sachin Maheshwari ” wrote:
> This message is in MIME format. Since your mail reader does not understand
> this format, some or all of this message may not be legible.
>
> ------_=_NextPart_001_01BFCA8E.B8BF7E6C
> Content-Type: text/plain;
> charset=“iso-8859-1”
>
> I hope you are not setting your startup paramater for the driver to
> be boot time startup.
>
> You can setup the Group order for the driver so that it starts up in some
> sequence which will work fine,
>
> alternatively,
>
> if you want to change the priority of your thread after system boots up
> then you can add an I/O request in your driver which changes the priority
> of the thread and call it through an application.
>
> sachin
>
> > -----Original Message-----
> > From: xxxxx@usa.net [mailto:xxxxx@usa.net]
> > Sent: Monday, May 29, 2000 6:00 PM
> > To: NT Developers Interest List
> > Subject: [ntdev] RE: Function to find if system is fully initialized
> >
> >
> >
> > No my driver does NOT have to wait for another driver to
> > load. The problem
> > is that I was creating a RealTime thread in my Bus Driver (priority
> > HIGH_PRIORITY),
> > and everything would work fine if my driver was loaded when
> > the system was
> > up and running.
> >
> > But if the system was rebooted with my driver, then it would
> > (appear to)
> > hang at initialization time. I verified that this was
> > because of the RT
> > thread (as soon as I NOT set the priority of my thread to RT,
> > the system
> > boots fine).
> >
> > So I would like to modify my driver such that it waits for
> > the system to
> > fully initialize (I’m hoping there’s some function I can call
> > to check
> > this), and then sets the priority of my thread to RT.
> >
> > Any suggestions are appreciated!
> >
> > Thanks
> > Puja
> >
> >
> > On 05/30/00, ““Jim Young” ” wrote:
> > > Define fully initialized. Does you driver have to wait for
> > another driver to
> > > load?
> > >
> > > Jim
> > >
> > > -----Original Message-----
> > > From: xxxxx@lists.osr.com
> > > [mailto:xxxxx@lists.osr.com]On Behalf Of xxxxx@usa.net
> > > Sent: Tuesday, May 30, 2000 3:00 PM
> > > To: NT Developers Interest List
> > > Subject: [ntdev] Function to find if system is fully initialized
> > >
> > >
> > > Hello,
> > >
> > > Is there any function I can call in my Win2K Bus Driver, to
> > find out if the
> > > system has been fully initialized ?
> > >
> > > Thanks
> > > Puja
> > >


You are currently subscribed to ntdev as: xxxxx@wattanuck.mv.com
To unsubscribe send a blank email to $subst(‘Email.Unsub’)

> So I would like to modify my driver such that it waits for the system to

fully initialize (I’m hoping there’s some function I can call to check
this), and then sets the priority of my thread to RT.

Maybe IoRegisterDriverReinitialization can help?

Max

> If you aren’t a BootStart PnP driver then load order is determined by the

undisclosed enumeration ordering of the PnP Manager, i.e. it is
unspecified
and out of your control. The rules are somewhat different for BootStart
PnP

IIRC it is not advisable to have any load order dependencies in the PnP
world.
If you have 2 drivers - A and B - then they must be designed to work OK
regardless of their load order.
Registering a device interface in A and a device interface arrival
notification
in B is a way to do this. Any inter-driver binding must be done by B in the
device interface arrival notification routine by opening the A’s device
object
and sending IRPs to it.
Unbinding is done in the similar way.
The disk stack in w2k (PartMgr and friends) uses this approach.

If your driver has load-order dependency on other driver which is not
yours -
maybe this is a good idea to write a proxy driver A and register it as
UpperFilter for the third-party driver.

Max