Re: NDIS5.1 driver in Vista
- From: soviet_bloke@xxxxxxxxxxx
- Date: 12 Oct 2006 22:57:53 -0700
Amit,
For a workaround I created the device object using the IoCreateDeivce()
and further creating the Symbolic link using the
IoCreateSymbolicLink(), Offcourse I am taking care abt the distach
routines initialization for if not done it would crash..
With this workaround I am able to get the handle and setup a normal
behaviour...
Sorry, I just overlooked the fact that you were speaking about
Vista..... In Vista NdisMRegisterDevice() is not supported - this is
why you get STATUS_NOT_SUPPORTED. This is what I can tell you for sure,
although, unfortunately, I am unable to offer you any workaround -all
my statements about Vista are based upon MSDN, rather than upon my own
experience.
However, it looks like you made an interesting experiment.....
Do you mean that you actually managed to send the request to the device
this way??? In fact, I am not surprized that calls to IoCreateDeivce()
and IoCreateSymbolicLink() were successfull, but, in my experience, if
you do thing this way IRP_MJ_CREATE gets immediately followed by
IRP_MJ_CLOSE whenever you call ZwCreateFile() , so that the whole thing
is, for the practical purposes, unusable (in fact, I never tried
IoGetDeviceObjectPointer(), just because the failure seemed to be
inevitable, so that there is no need to waste time on the experiment).
This is how it works on W2K and XP. However, as it turns out, on
Vista it may work differently......
Anton Bassov
Amit wrote:
Hi ,
I am registering my mniport driver with NDIS as below,
Status = NdisMRegisterDevice(
NdisWrapperHandle,
&ustrDeviceName,
&ustrSymbolicName,
dispatch_table,
&Adapter->psDeviceObj,
&Adapter->NdisDeviceHandle);
using this method I am unable to get the device handle. ( call from
both IoGetDeviceObjectPointer() and CreateFile() FAIL) . I checked
even the Symbolic link with WinObj.exe and is created.
For a workaround I created the device object using the IoCreateDeivce()
and further creating the Symbolic link using the
IoCreateSymbolicLink(), Offcourse I am taking care abt the distach
routines initialization for if not done it would crash..
With this workaround I am able to get the handle and setup a normal
behaviour...But this workaround is not the right way to register...So
please help me to get a solution and what is the reason for such
behaviour?
Regards,
Amit
soviet_bloke@xxxxxxxxxxx wrote:
Hi mate
I am trying to get the handle using the IoGetDeviceObjectPointer()
function from another driver, But it always returns
STATUS_NOT_SUPPORTED. What could be the reason for such behaviour?
"The reason for such behaviour" is obvious-- you are just not supposed
to access miniport drivers this way. If you want someoene, apart from
NDIS library, to call your miniport driver, you have to register a
standalone device with NdisMRegisterDevice(), and forward all calls to
this device
Anton Bassov
Amit wrote:
Hi All,
I am using my NDIS 5.1 miniport driver written for WinXP prof in
Vista Build 5600 (Vista RC1).
The driver is running fine for it supports the backward compatibility,
but I am unable to get the handle for my network device for the driver
I have.
I am trying to get the handle using the IoGetDeviceObjectPointer()
function from another driver, But it always returns
STATUS_NOT_SUPPORTED. What could be the reason for such behaviour?
The same setup ( NDIS miniport driver and the other driver from which i
am trying to get the NDIS handle ) works fine.
Looking forward for your response.....
.
- Follow-Ups:
- Re: NDIS5.1 driver in Vista
- From: Amit
- Re: NDIS5.1 driver in Vista
- References:
- NDIS5.1 driver in Vista
- From: Amit
- Re: NDIS5.1 driver in Vista
- From: soviet_bloke
- Re: NDIS5.1 driver in Vista
- From: Amit
- NDIS5.1 driver in Vista
- Prev by Date: Re: NDIS Version question.
- Next by Date: Re: Regarding COM in the kernel
- Previous by thread: Re: NDIS5.1 driver in Vista
- Next by thread: Re: NDIS5.1 driver in Vista
- Index(es):
Relevant Pages
|