Driver Reinitialize Routines

I wan’t my driver Reinitialize routine to be called until the system fully
boots. what is the efficient way to do this?
**************************************************************************
This email (including any attachments) is intended for the sole use of the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying or
distribution or forwarding of any or all of the contents in this message is
STRICTLY PROHIBITED. If you are not the intended recipient, please contact
the sender by email and delete all copies; your cooperation in this regard
is appreciated.
**************************************************************************

There is really no way to determine exactly at what time your system fully
boots. If you want to use some timing then use the timer and queue work
items.


Nar Ganapathy
Windows Core OS group
This posting is provided “AS IS” with no warranties, and confers no rights.
“Seshagiri_Babu” wrote in message
news:xxxxx@ntdev…
>
> I wan’t my driver Reinitialize routine to be called until the system fully
> boots. what is the efficient way to do this?
>
> This email (including any attachments) is intended for the sole use of the
> intended recipient/s and may contain material that is CONFIDENTIAL AND
> PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying
or
> distribution or forwarding of any or all of the contents in this message
is
> STRICTLY PROHIBITED. If you are not the intended recipient, please contact
> the sender by email and delete all copies; your cooperation in this regard
> is appreciated.
>

>
>

the best way to start is probably to better define “fully boots”. What
are you hoping to do in your reinitialization routine that requires
waiting. Do you expect the user to have already been able to log in, or
are you just waiting for some particular service to start up? Or are
you hoping the system will be idle and you can go do some background
work?

-p

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Friday, June 28, 2002 12:12 AM
To: NT Developers Interest List
Subject: [ntdev] Driver Reinitialize Routines

I wan’t my driver Reinitialize routine to be called until the system
fully boots. what is the efficient way to do this?
************************************************************************
**
This email (including any attachments) is intended for the sole use of
the intended recipient/s and may contain material that is CONFIDENTIAL
AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or
copying or distribution or forwarding of any or all of the contents in
this message is STRICTLY PROHIBITED. If you are not the intended
recipient, please contact the sender by email and delete all copies;
your cooperation in this regard is appreciated.
************************************************************************
**


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

Ok…my driver is of auto-start type and i wan’t to claim the serial ports
on whcih my devices are configured. Whats’ happening now is that serial.sys
is not enumerating the ports by the time my driver comes to a point where it
tries to claim Serial Ports.

And one more thing is that i can’t define my service as dependent on
serial.sys only because there are differenet drivers on different pc’s which
does this job of enumerarting serial ports.

By “FULLY BOOTS” I actually meant all the drivers getting started
:slight_smile:


From: Peter Wieland[SMTP:xxxxx@windows.microsoft.com]
Reply To: NT Developers Interest List
Sent: Friday, June 28, 2002 9:46 AM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

the best way to start is probably to better define “fully boots”. What
are you hoping to do in your reinitialization routine that requires
waiting. Do you expect the user to have already been able to log in, or
are you just waiting for some particular service to start up? Or are
you hoping the system will be idle and you can go do some background
work?

-p

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Friday, June 28, 2002 12:12 AM
To: NT Developers Interest List
Subject: [ntdev] Driver Reinitialize Routines

I wan’t my driver Reinitialize routine to be called until the system
fully boots. what is the efficient way to do this?
************************************************************************
**
This email (including any attachments) is intended for the sole use of
the intended recipient/s and may contain material that is CONFIDENTIAL
AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or
copying or distribution or forwarding of any or all of the contents in
this message is STRICTLY PROHIBITED. If you are not the intended
recipient, please contact the sender by email and delete all copies;
your cooperation in this regard is appreciated.
************************************************************************
**


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@satyam.com
To unsubscribe send a blank email to %%email.unsub%%

**************************************************************************
This email (including any attachments) is intended for the sole use of the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying or
distribution or forwarding of any or all of the contents in this message is
STRICTLY PROHIBITED. If you are not the intended recipient, please contact
the sender by email and delete all copies; your cooperation in this regard
is appreciated.
**************************************************************************

What you want to do is listen for the arrival of the COM port interface.
Register via IoRegisterPlugPlayNotification and use the GUID
GUID_DEVINTERFACE_COMPORT (in ntddser.h). The toaster example in the XP
shows how to do this. Once you open the com port, you will want to
register for pnp notifications on your file handle so that the com port
can be removed / disabled after you open it. You use the same function
for this; the toaster demonstrates this as well.

D

This posting is provided “AS IS” with no warranties, and confers no
rights.

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Sunday, June 30, 2002 9:26 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

Ok…my driver is of auto-start type and i wan’t to claim the serial
ports
on whcih my devices are configured. Whats’ happening now is that
serial.sys
is not enumerating the ports by the time my driver comes to a point
where it
tries to claim Serial Ports.

And one more thing is that i can’t define my service as dependent
on
serial.sys only because there are differenet drivers on different pc’s
which
does this job of enumerarting serial ports.

By “FULLY BOOTS” I actually meant all the drivers getting started
:slight_smile:


From: Peter Wieland[SMTP:xxxxx@windows.microsoft.com]
Reply To: NT Developers Interest List
Sent: Friday, June 28, 2002 9:46 AM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

the best way to start is probably to better define “fully boots”.
What
are you hoping to do in your reinitialization routine that requires
waiting. Do you expect the user to have already been able to log in,
or
are you just waiting for some particular service to start up? Or are
you hoping the system will be idle and you can go do some background
work?

-p

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Friday, June 28, 2002 12:12 AM
To: NT Developers Interest List
Subject: [ntdev] Driver Reinitialize Routines

I wan’t my driver Reinitialize routine to be called until the system
fully boots. what is the efficient way to do this?

************************************************************************

**
This email (including any attachments) is intended for the sole use of
the intended recipient/s and may contain material that is CONFIDENTIAL
AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or
copying or distribution or forwarding of any or all of the contents in
this message is STRICTLY PROHIBITED. If you are not the intended
recipient, please contact the sender by email and delete all copies;
your cooperation in this regard is appreciated.

************************************************************************

**


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@satyam.com
To unsubscribe send a blank email to %%email.unsub%%

************************************************************************
**
This email (including any attachments) is intended for the sole use of
the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying
or
distribution or forwarding of any or all of the contents in this message
is
STRICTLY PROHIBITED. If you are not the intended recipient, please
contact
the sender by email and delete all copies; your cooperation in this
regard
is appreciated.
************************************************************************
**


You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to %%email.unsub%%

Will i be able to distinguish between the COM port interfaces exposed when i
get the notification? I would like to claim only a specific COM port.


From: Doron Holan[SMTP:xxxxx@windows.microsoft.com]
Reply To: NT Developers Interest List
Sent: Sunday, June 30, 2002 11:31 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

What you want to do is listen for the arrival of the COM port interface.
Register via IoRegisterPlugPlayNotification and use the GUID
GUID_DEVINTERFACE_COMPORT (in ntddser.h). The toaster example in the XP
shows how to do this. Once you open the com port, you will want to
register for pnp notifications on your file handle so that the com port
can be removed / disabled after you open it. You use the same function
for this; the toaster demonstrates this as well.

D

This posting is provided “AS IS” with no warranties, and confers no
rights.

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Sunday, June 30, 2002 9:26 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

Ok…my driver is of auto-start type and i wan’t to claim the serial
ports
on whcih my devices are configured. Whats’ happening now is that
serial.sys
is not enumerating the ports by the time my driver comes to a point
where it
tries to claim Serial Ports.

And one more thing is that i can’t define my service as dependent
on
serial.sys only because there are differenet drivers on different pc’s
which
does this job of enumerarting serial ports.

By “FULLY BOOTS” I actually meant all the drivers getting started
:slight_smile:

> ----------
> From: Peter Wieland[SMTP:xxxxx@windows.microsoft.com]
> Reply To: NT Developers Interest List
> Sent: Friday, June 28, 2002 9:46 AM
> To: NT Developers Interest List
> Subject: [ntdev] RE: Driver Reinitialize Routines
>
> the best way to start is probably to better define “fully boots”.
What
> are you hoping to do in your reinitialization routine that requires
> waiting. Do you expect the user to have already been able to log in,
or
> are you just waiting for some particular service to start up? Or are
> you hoping the system will be idle and you can go do some background
> work?
>
> -p
>
> -----Original Message-----
> From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
> Sent: Friday, June 28, 2002 12:12 AM
> To: NT Developers Interest List
> Subject: [ntdev] Driver Reinitialize Routines
>
>
> I wan’t my driver Reinitialize routine to be called until the system
> fully boots. what is the efficient way to do this?
>
************************************************************************
> **
> This email (including any attachments) is intended for the sole use of
> the intended recipient/s and may contain material that is CONFIDENTIAL
> AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or
> copying or distribution or forwarding of any or all of the contents in
> this message is STRICTLY PROHIBITED. If you are not the intended
> recipient, please contact the sender by email and delete all copies;
> your cooperation in this regard is appreciated.
>
************************************************************************
> **
>
> —
> 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@satyam.com
> To unsubscribe send a blank email to %%email.unsub%%
>
************************************************************************
**
This email (including any attachments) is intended for the sole use of
the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying
or
distribution or forwarding of any or all of the contents in this message
is
STRICTLY PROHIBITED. If you are not the intended recipient, please
contact
the sender by email and delete all copies; your cooperation in this
regard
is appreciated.
************************************************************************
**


You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to %%email.unsub%%


You are currently subscribed to ntdev as: xxxxx@satyam.com
To unsubscribe send a blank email to %%email.unsub%%

**************************************************************************
This email (including any attachments) is intended for the sole use of the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying or
distribution or forwarding of any or all of the contents in this message is
STRICTLY PROHIBITED. If you are not the intended recipient, please contact
the sender by email and delete all copies; your cooperation in this regard
is appreciated.
**************************************************************************

Once you open the port, you can get the PDO. From there, open the
device parameters key and read the “PortName” value. Or I guess,
whenever a serial port comes online, you just open up the hardcoded COM
name and if it now succeeds, you are good to go.

d

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Monday, July 01, 2002 11:44 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

Will i be able to distinguish between the COM port interfaces exposed
when i
get the notification? I would like to claim only a specific COM port.


From: Doron Holan[SMTP:xxxxx@windows.microsoft.com]
Reply To: NT Developers Interest List
Sent: Sunday, June 30, 2002 11:31 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

What you want to do is listen for the arrival of the COM port
interface.
Register via IoRegisterPlugPlayNotification and use the GUID
GUID_DEVINTERFACE_COMPORT (in ntddser.h). The toaster example in the
XP
shows how to do this. Once you open the com port, you will want to
register for pnp notifications on your file handle so that the com
port
can be removed / disabled after you open it. You use the same
function
for this; the toaster demonstrates this as well.

D

This posting is provided “AS IS” with no warranties, and confers no
rights.

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Sunday, June 30, 2002 9:26 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

Ok…my driver is of auto-start type and i wan’t to claim the serial
ports
on whcih my devices are configured. Whats’ happening now is that
serial.sys
is not enumerating the ports by the time my driver comes to a point
where it
tries to claim Serial Ports.

And one more thing is that i can’t define my service as
dependent
on
serial.sys only because there are differenet drivers on different pc’s
which
does this job of enumerarting serial ports.

By “FULLY BOOTS” I actually meant all the drivers getting
started
:slight_smile:

> ----------
> From: Peter Wieland[SMTP:xxxxx@windows.microsoft.com]
> Reply To: NT Developers Interest List
> Sent: Friday, June 28, 2002 9:46 AM
> To: NT Developers Interest List
> Subject: [ntdev] RE: Driver Reinitialize Routines
>
> the best way to start is probably to better define “fully boots”.
What
> are you hoping to do in your reinitialization routine that requires
> waiting. Do you expect the user to have already been able to log
in,
or
> are you just waiting for some particular service to start up? Or
are
> you hoping the system will be idle and you can go do some background
> work?
>
> -p
>
> -----Original Message-----
> From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
> Sent: Friday, June 28, 2002 12:12 AM
> To: NT Developers Interest List
> Subject: [ntdev] Driver Reinitialize Routines
>
>
> I wan’t my driver Reinitialize routine to be called until the system
> fully boots. what is the efficient way to do this?
>

************************************************************************

> **
> This email (including any attachments) is intended for the sole use
of
> the intended recipient/s and may contain material that is
CONFIDENTIAL
> AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or
> copying or distribution or forwarding of any or all of the contents
in
> this message is STRICTLY PROHIBITED. If you are not the intended
> recipient, please contact the sender by email and delete all copies;
> your cooperation in this regard is appreciated.
>

************************************************************************

> **
>
> —
> 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@satyam.com
> To unsubscribe send a blank email to %%email.unsub%%
>

************************************************************************

**
This email (including any attachments) is intended for the sole use of
the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or
copying
or
distribution or forwarding of any or all of the contents in this
message
is
STRICTLY PROHIBITED. If you are not the intended recipient, please
contact
the sender by email and delete all copies; your cooperation in this
regard
is appreciated.

************************************************************************

**


You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to %%email.unsub%%


You are currently subscribed to ntdev as: xxxxx@satyam.com
To unsubscribe send a blank email to %%email.unsub%%

************************************************************************
**
This email (including any attachments) is intended for the sole use of
the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying
or
distribution or forwarding of any or all of the contents in this message
is
STRICTLY PROHIBITED. If you are not the intended recipient, please
contact
the sender by email and delete all copies; your cooperation in this
regard
is appreciated.
************************************************************************
**


You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to %%email.unsub%%

Hi Doron,
Can’t I know the Dos Device name without opening the port? (I need
to close it immediately if its not the one iam looking for). Say I have the
COM1-4 serial ports on my pc. I have my device configured for COM2. (The
configuration of a device to a COM port can be changed dynamically by the
user through a CPL app). Now using pnp notification, how can i determine
whether the notification i got is that of COM2’s arrival/removal?


From: Doron Holan[SMTP:xxxxx@windows.microsoft.com]
Reply To: NT Developers Interest List
Sent: Tuesday, July 02, 2002 12:10 AM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

Once you open the port, you can get the PDO. From there, open the
device parameters key and read the “PortName” value. Or I guess,
whenever a serial port comes online, you just open up the hardcoded COM
name and if it now succeeds, you are good to go.

d

-----Original Message-----
From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
Sent: Monday, July 01, 2002 11:44 PM
To: NT Developers Interest List
Subject: [ntdev] RE: Driver Reinitialize Routines

Will i be able to distinguish between the COM port interfaces exposed
when i
get the notification? I would like to claim only a specific COM port.

> ----------
> From: Doron Holan[SMTP:xxxxx@windows.microsoft.com]
> Reply To: NT Developers Interest List
> Sent: Sunday, June 30, 2002 11:31 PM
> To: NT Developers Interest List
> Subject: [ntdev] RE: Driver Reinitialize Routines
>
> What you want to do is listen for the arrival of the COM port
interface.
> Register via IoRegisterPlugPlayNotification and use the GUID
> GUID_DEVINTERFACE_COMPORT (in ntddser.h). The toaster example in the
XP
> shows how to do this. Once you open the com port, you will want to
> register for pnp notifications on your file handle so that the com
port
> can be removed / disabled after you open it. You use the same
function
> for this; the toaster demonstrates this as well.
>
> D
>
> This posting is provided “AS IS” with no warranties, and confers no
> rights.
>
> -----Original Message-----
> From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
> Sent: Sunday, June 30, 2002 9:26 PM
> To: NT Developers Interest List
> Subject: [ntdev] RE: Driver Reinitialize Routines
>
> Ok…my driver is of auto-start type and i wan’t to claim the serial
> ports
> on whcih my devices are configured. Whats’ happening now is that
> serial.sys
> is not enumerating the ports by the time my driver comes to a point
> where it
> tries to claim Serial Ports.
>
> And one more thing is that i can’t define my service as
dependent
> on
> serial.sys only because there are differenet drivers on different pc’s
> which
> does this job of enumerarting serial ports.
>
> By “FULLY BOOTS” I actually meant all the drivers getting
started
> :slight_smile:
>
> > ----------
> > From: Peter Wieland[SMTP:xxxxx@windows.microsoft.com]
> > Reply To: NT Developers Interest List
> > Sent: Friday, June 28, 2002 9:46 AM
> > To: NT Developers Interest List
> > Subject: [ntdev] RE: Driver Reinitialize Routines
> >
> > the best way to start is probably to better define “fully boots”.
> What
> > are you hoping to do in your reinitialization routine that requires
> > waiting. Do you expect the user to have already been able to log
in,
> or
> > are you just waiting for some particular service to start up? Or
are
> > you hoping the system will be idle and you can go do some background
> > work?
> >
> > -p
> >
> > -----Original Message-----
> > From: Seshagiri_Babu [mailto:xxxxx@Satyam.com]
> > Sent: Friday, June 28, 2002 12:12 AM
> > To: NT Developers Interest List
> > Subject: [ntdev] Driver Reinitialize Routines
> >
> >
> > I wan’t my driver Reinitialize routine to be called until the system
> > fully boots. what is the efficient way to do this?
> >
>
************************************************************************
> > **
> > This email (including any attachments) is intended for the sole use
of
> > the intended recipient/s and may contain material that is
CONFIDENTIAL
> > AND PRIVATE COMPANY INFORMATION. Any review or reliance by others or
> > copying or distribution or forwarding of any or all of the contents
in
> > this message is STRICTLY PROHIBITED. If you are not the intended
> > recipient, please contact the sender by email and delete all copies;
> > your cooperation in this regard is appreciated.
> >
>
************************************************************************
> > **
> >
> > —
> > 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@satyam.com
> > To unsubscribe send a blank email to %%email.unsub%%
> >
>
************************************************************************
> **
> This email (including any attachments) is intended for the sole use of
> the
> intended recipient/s and may contain material that is CONFIDENTIAL AND
> PRIVATE COMPANY INFORMATION. Any review or reliance by others or
copying
> or
> distribution or forwarding of any or all of the contents in this
message
> is
> STRICTLY PROHIBITED. If you are not the intended recipient, please
> contact
> the sender by email and delete all copies; your cooperation in this
> regard
> is appreciated.
>
************************************************************************
> **
>
> —
> You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
> To unsubscribe send a blank email to %%email.unsub%%
>
> —
> You are currently subscribed to ntdev as: xxxxx@satyam.com
> To unsubscribe send a blank email to %%email.unsub%%
>
************************************************************************
**
This email (including any attachments) is intended for the sole use of
the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying
or
distribution or forwarding of any or all of the contents in this message
is
STRICTLY PROHIBITED. If you are not the intended recipient, please
contact
the sender by email and delete all copies; your cooperation in this
regard
is appreciated.
************************************************************************
**


You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to %%email.unsub%%


You are currently subscribed to ntdev as: xxxxx@satyam.com
To unsubscribe send a blank email to %%email.unsub%%

**************************************************************************
This email (including any attachments) is intended for the sole use of the
intended recipient/s and may contain material that is CONFIDENTIAL AND
PRIVATE COMPANY INFORMATION. Any review or reliance by others or copying or
distribution or forwarding of any or all of the contents in this message is
STRICTLY PROHIBITED. If you are not the intended recipient, please contact
the sender by email and delete all copies; your cooperation in this regard
is appreciated.
**************************************************************************