Handling IRPs in NDIS Intermidiate Driver???

Hi people,
I have this NDIS passthru Intermidiate Driver for Win2k . I am
registering both upper edge and lower egde functions.

My problem is as follows.

I want to implement WMI in my code. So while registering it as WMI provider
using IoWMIRegistraxxx, I have to handle IRP_MJ_SYSTEM_CONTROL. So What i
did was i created a device object successfully and then I have given a
dispatch entry point as

DriverObject->MajorFunction[IRP_MJ_SYSTEM_CONTROL]=WmiDispatchSystemControl;

But every time my driver crashes showing this error in WinDbg,

Access violation - code c0000005 (!!! second chance !!!)
NDIS!ndisWMIDispatch+23:
fe516b9a 833900 cmp dword ptr [ecx],0x0

What I want to know is that, should i handle Create and Close Dispatch
routines also or is it that since my driver is inside the NDIS wrapper the
IRP is getting mapped into something else. Is my way of creating
DeviceObject and handling this IRP is correct???.

Please let me know.

Thank you all,
Regards,
Mohasin

==================================================
Syed Mohasin Zaki
Engineer-Software

Wipro Technologies
475A, Old Mahabalipuram Road,
Sholinganallur,
Chennai - 600 119. INDIA
Tel : 91-44-4500200 to 212 Extn:2284
Fax : 91-44-4500250
xxxxx@wipro.com
www.wipro.com
World’s First SEI CMM LEVEL5 Software Services Company


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

You should probably try to create a device at your IM’s miniport edge
using NdisMRegisterDevice and then use this device with your
IoWMIRegistraxxx.
On the other side, wouldn’t it be easier to use custom NDIS_GUID OID stuff
in your case? Just a thought.

  • Vitaly

On 05/23/01, ““Mohasin Zaki Syed” ” wrote:
> Hi people,
> I have this NDIS passthru Intermidiate Driver for Win2k . I am
> registering both upper edge and lower egde functions.
>
> My problem is as follows.
>
> I want to implement WMI in my code. So while registering it as WMI provider
> using IoWMIRegistraxxx, I have to handle IRP_MJ_SYSTEM_CONTROL. So What i
> did was i created a device object successfully and then I have given a
> dispatch entry point as
>
> DriverObject->MajorFunction[IRP_MJ_SYSTEM_CONTROL]=WmiDispatchSystemControl;
>
> But every time my driver crashes showing this error in WinDbg,
>
> Access violation - code c0000005 (!!! second chance !!!)
> NDIS!ndisWMIDispatch+23:
> fe516b9a 833900 cmp dword ptr [ecx],0x0
>
> What I want to know is that, should i handle Create and Close Dispatch
> routines also or is it that since my driver is inside the NDIS wrapper the
> IRP is getting mapped into something else. Is my way of creating
> DeviceObject and handling this IRP is correct???.
>
> Please let me know.
>
> Thank you all,
> Regards,
> Mohasin
>
>
> ==================================================
> Syed Mohasin Zaki
> Engineer-Software
>
> Wipro Technologies
> 475A, Old Mahabalipuram Road,
> Sholinganallur,
> Chennai - 600 119. INDIA
> Tel : 91-44-4500200 to 212 Extn:2284
> Fax : 91-44-4500250
> xxxxx@wipro.com
> www.wipro.com
> World’s First SEI CMM LEVEL5 Software Services Company
> ==================================================
>
>
> —
> You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
> To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com