Tech Support > Microsoft Windows > Drivers > toaster IRP_MN_REGINFO flow
toaster IRP_MN_REGINFO flow
Posted by Vipin on May 18th, 2005


Hi,
I need some clarification on sequence for the IRP_MN_REGINFO.

In the AddDevice(...) of the toaster dispatch routine, the registering with
the WMI happens via
IoWMIRegistrationControl(...) and then saves the WMI information for later
processing when the kernel mode WMI component sends the IRP, yes that comes
via the IRP_MJ_SYSTEM_CONTROL dispatch routine. Now, what I am seeing is
when the devices are added during boot time, the WMI is not yet up. I can
understand it because the WMI service hasn't come up that early in the boot
when the devices are added to the bus.

Now my question, when the IoWMIRegistrationControl(...) is called, who
basically tracks the pending WMI registrations for later processing by the
WMI. I am assuming the IO subsystem would queue the resgitrations for
pushing later to the WMI component or the WMI kernel component would pick
from the I/O queue. There is virtually no documentation on what happens in
the DDK.

I see a topic on wmi registrations here:-
http://www.oneysoft.com/newerr.htm (When to call IoWMIRegistrationControl
[06/12/03]

In brief the summary of the above link.
"It differentiates between windows 2000 and XP. It says in 2000, one could
see a system crash if the WMI registration happens any time before the first
IRP_MN_START_DEVICE.
It also says on XP, a queueing mechanism is implemented which would queue
till it can safely be performed."

Well, the toaster sample has the registration happening in the AddDevice
dispatch routine and I don't see any crashes on windows 2000.

Thanks
Vipin


Posted by Doron Holan [MS] on May 18th, 2005


the crash would only occur if you expected data from start device to be
present when processing the reginfo request. the registration is pended
internally until wmi starts, there is not much more then that.

d

--
Please do not send e-mail directly to this alias. this alias is for
newsgroup purposes only.
This posting is provided "AS IS" with no warranties, and confers no rights.


"Vipin" <vipin@nospam.com> wrote in message
news:%235M1%23T4WFHA.2076@TK2MSFTNGP15.phx.gbl...



Similar Posts