Hello

Now, I'm getting desperate. I need to reload the settings for the NDIS
driver on Windows 2000 / XP. I use it for using the USB as a NIC and I have
to setup the IP address from a service. Unfortunately, these settings are
only read when starting the NDIS driver and I need a way to reload these
settings/loading the NDIS driver on Window 2000 / XP other than pulling the
cable out and reinserting it. I got it working on Windows CE.

Please help me.

Henrik

Re: Urgent : Reloading settings for NDIS driver by Maxim

Maxim
Wed May 26 04:26:31 CDT 2004

Try the INetCfg interface and friends.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com


"Henrik Sorensen" <taurus102@hotmail.com> wrote in message
news:eKWtAQvQEHA.396@TK2MSFTNGP12.phx.gbl...
> Hello
>
> Now, I'm getting desperate. I need to reload the settings for the NDIS
> driver on Windows 2000 / XP. I use it for using the USB as a NIC and I have
> to setup the IP address from a service. Unfortunately, these settings are
> only read when starting the NDIS driver and I need a way to reload these
> settings/loading the NDIS driver on Window 2000 / XP other than pulling the
> cable out and reinserting it. I got it working on Windows CE.
>
> Please help me.
>
> Henrik
>
>



Re: Urgent : Reloading settings for NDIS driver by bburgin

bburgin
Wed May 26 08:15:11 CDT 2004

------=_NextPart_0001_8E353556
Content-Type: text/plain
Content-Transfer-Encoding: 7bit



Also check out the IP Helper APIs in the SDK and NetSh. In a command
window, type "netsh ?". For each command, you can obtain additional help
via "netsh <cmd> ?", etc. To set an address, see "netsh ip set address ?".

HTH

Bryan S. Burgin
bburgin@microsoft.com

This posting is provided "AS IS" with no warranties, and confers no rights.
------=_NextPart_0001_8E353556
Content-Type: text/x-rtf
Content-Transfer-Encoding: 7bit

{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fprq2\fcharset0 MS Sans Serif;}}
\viewkind4\uc1\pard\f0\fs20
\par
\par Also check out the IP Helper APIs in the SDK and NetSh. In a command window, type "netsh ?". For each command, you can obtain additional help via "netsh <cmd> ?", etc. To set an address, see "netsh ip set address ?".
\par
\par HTH
\par
\par Bryan S. Burgin
\par bburgin@microsoft.com
\par
\par This posting is provided "AS IS" with no warranties, and confers no rights.
\par }
------=_NextPart_0001_8E353556--


Re: Urgent : Reloading settings for NDIS driver by Stephan

Stephan
Wed May 26 13:44:34 CDT 2004

On Wed, 26 May 2004 13:26:31 +0400, "Maxim S. Shatskih"
<maxim@storagecraft.com> wrote:

> Try the INetCfg interface and friends.

INetCfg does not allow for a network driver to get unloaded/reloaded.
SetupDi must be used instead.

INetCfg can, however, be used to bind/unbind protocol drivers.

Stephan

Re: Urgent : Reloading settings for NDIS driver by Stephan

Stephan
Wed May 26 13:48:22 CDT 2004

See also OID_GEN_NETWORK_LAYER_ADDRESSES.

Stephan
---
On Wed, 26 May 2004 09:35:19 +0200, "Henrik Sorensen"
<taurus102@hotmail.com> wrote:

>Hello
>
>Now, I'm getting desperate. I need to reload the settings for the NDIS
>driver on Windows 2000 / XP. I use it for using the USB as a NIC and I have
>to setup the IP address from a service. Unfortunately, these settings are
>only read when starting the NDIS driver and I need a way to reload these
>settings/loading the NDIS driver on Window 2000 / XP other than pulling the
>cable out and reinserting it. I got it working on Windows CE.
>
>Please help me.
>
>Henrik

Re: Urgent : Reloading settings for NDIS driver by Maxim

Maxim
Wed May 26 14:26:04 CDT 2004

> INetCfg does not allow for a network driver to get unloaded/reloaded.
> SetupDi must be used instead.
>
> INetCfg can, however, be used to bind/unbind protocol drivers.

Will it allow to change the IP address? Or IP helper APIs are necessary for
this?

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com



Re: Urgent : Reloading settings for NDIS driver by Maxim

Maxim
Wed May 26 14:26:32 CDT 2004

IIRC they are just a notification and provide no ability of changing the
address.

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com


"Stephan Wolf" <stewo68@hotmail.com> wrote in message
news:7jp9b01dbmb6o8f7n4bkmn3cn4afeu294l@4ax.com...
> See also OID_GEN_NETWORK_LAYER_ADDRESSES.
>
> Stephan
> ---
> On Wed, 26 May 2004 09:35:19 +0200, "Henrik Sorensen"
> <taurus102@hotmail.com> wrote:
>
> >Hello
> >
> >Now, I'm getting desperate. I need to reload the settings for the NDIS
> >driver on Windows 2000 / XP. I use it for using the USB as a NIC and I have
> >to setup the IP address from a service. Unfortunately, these settings are
> >only read when starting the NDIS driver and I need a way to reload these
> >settings/loading the NDIS driver on Window 2000 / XP other than pulling the
> >cable out and reinserting it. I got it working on Windows CE.
> >
> >Please help me.
> >
> >Henrik



Re: Urgent : Reloading settings for NDIS driver by Stephan

Stephan
Thu May 27 14:55:40 CDT 2004

On Wed, 26 May 2004 23:26:04 +0400, "Maxim S. Shatskih"
<maxim@storagecraft.com> wrote:

>> INetCfg can, however, be used to bind/unbind protocol drivers.
>
>Will it allow to change the IP address? Or IP helper APIs are necessary for
>this?

INetCfg has no concept of what IP is. It just binds "services" to
"protocols" to "adapters".

Stephan

Re: Urgent : Reloading settings for NDIS driver by Stephan

Stephan
Thu May 27 14:58:24 CDT 2004

On Wed, 26 May 2004 23:26:32 +0400, "Maxim S. Shatskih"
<maxim@storagecraft.com> wrote:

> IIRC they are just a notification and provide no ability of changing the
>address.

The OP said:

> I use it for using the USB as a NIC and I have
>to setup the IP address from a service.

So it seems a service is setting the IP address but he needs this
information in his NDIS driver. That's where
OID_GEN_NETWORK_LAYER_ADDRESSES comes into play.

Stephan

Re: Urgent : Reloading settings for NDIS driver by Thomas

Thomas
Thu May 27 16:50:53 CDT 2004


"Stephan Wolf" <stewo68@hotmail.com> wrote in message
news:evhcb01jncvis9bqq3kj03dg98icdj5bno@4ax.com...
> On Wed, 26 May 2004 23:26:32 +0400, "Maxim S. Shatskih"
> <maxim@storagecraft.com> wrote:
>
> > IIRC they are just a notification and provide no ability of changing
the
> >address.
>
> The OP said:
>
> > I use it for using the USB as a NIC and I have
> >to setup the IP address from a service.
>
> So it seems a service is setting the IP address but he needs this
> information in his NDIS driver. That's where
> OID_GEN_NETWORK_LAYER_ADDRESSES comes into play.
>

The real use of OID_GEN_NETWORK_LAYER_ADDRESSES isn't described. For sure,
it is an optional OID, which means that most NDIS components will not have
any interest in it.

Since it is passed to miniports - not to protocols - it is unlikely that
sending it will actually inform TCP/IP of anything.

The use of this OID is possibly related to NDIS task offload. Adapters that
support NDIS task offload may need the information.

I don't think that OID_GEN_NETWORK_LAYER_ADDRESSES will help the OP.

Thomas F. Divine

> Stephan



Re: Urgent : Reloading settings for NDIS driver by Maxim

Maxim
Thu May 27 23:11:52 CDT 2004

> INetCfg has no concept of what IP is. It just binds "services" to
> "protocols" to "adapters".

Is it possible to send the per-binding data by INetCfg?

--
Maxim Shatskih, Windows DDK MVP
StorageCraft Corporation
maxim@storagecraft.com
http://www.storagecraft.com



Re: Urgent : Reloading settings for NDIS driver by Stephan

Stephan
Fri May 28 04:40:31 CDT 2004

On Thu, 27 May 2004 17:50:53 -0400, "Thomas F. Divine [DDK MVP]"
<tdivine@NOpcausaSPAM.com> wrote:

>I don't think that OID_GEN_NETWORK_LAYER_ADDRESSES will help the OP.

Umm, maybe we talk about different things here. My understanding is
that the OP is already able to set the IP address (via some service).
But the network adapter driver (NDIS miniport) also needs to be aware
of this.

My *guess* is (and I don't like guessing too much) that the miniport
reads the IP(s) at startup from the registry somehow. But it does not
know when IP address(es) get changed *later*.

I think this could be done by watching
OID_GEN_NETWORK_LAYER_ADDRESSES.

Will the OP please provide more details?

Thanks, Stephan

Re: Urgent : Reloading settings for NDIS driver by Stephan

Stephan
Fri May 28 04:41:36 CDT 2004

On Fri, 28 May 2004 08:11:52 +0400, "Maxim S. Shatskih"
<maxim@storagecraft.com> wrote:

>Is it possible to send the per-binding data by INetCfg?

Umm, I think I don't get the question, sorry. Send which information?
And send it where?

Stephan

Re: Urgent : Reloading settings for NDIS driver by Thomas

Thomas
Fri May 28 06:26:21 CDT 2004


"Stephan Wolf" <stewo68@hotmail.com> wrote in message
news:i12eb0937lo65rkc7ad5coua1hi52asugb@4ax.com...
> On Thu, 27 May 2004 17:50:53 -0400, "Thomas F. Divine [DDK MVP]"
> <tdivine@NOpcausaSPAM.com> wrote:
>
> >I don't think that OID_GEN_NETWORK_LAYER_ADDRESSES will help the OP.
>
> Umm, maybe we talk about different things here. My understanding is
> that the OP is already able to set the IP address (via some service).
> But the network adapter driver (NDIS miniport) also needs to be aware
> of this.
>
> My *guess* is (and I don't like guessing too much) that the miniport
> reads the IP(s) at startup from the registry somehow. But it does not
> know when IP address(es) get changed *later*.
>
> I think this could be done by watching
> OID_GEN_NETWORK_LAYER_ADDRESSES.
>

You're right, Stephan. If this is a propritary thing, then certainly the OP
could use this OID (or a propritary one) to pass the information to his
miniport.

I was just musing that this OID can't be counted on to be generated by the
system in most cases - even when TCP/IP has acquired the IP addresses for
the interface.

Thomas F. Divine

> Will the OP please provide more details?
>
> Thanks, Stephan



Re: Urgent : Reloading settings for NDIS driver by bburgin

bburgin
Fri May 28 19:57:46 CDT 2004

------=_NextPart_0001_5E9B04C9
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Miniports, the target of a set or query OID, as the lowest two layers of
the OSI model (PHY & Link), at best, only care about the Ethernet, TR,
FDDI, etc, address and anything at the network or protocol layers,
including (in the case of IP) is nothing but payload. If you want to
affect TCPIP's IP address, you need an API that talks to TCPIP, like the IP
Helper APIs.

OIDs, since they talk to the miniport and not to TCPIP won't help you. Nor
will the INetCfg APIs, as they affect binding between networking components.

Remember, a miniport could be bound to any number of protocols, TCPIP being
the most common. But, excluding Ethernet NICs that do offload operations,
don't care anything past the Ethernet header.

HTH,

Bryan S. Burgin
bburgin@microsoft.com

This posting is provided "AS IS" with no warranties, and confers no rights.
------=_NextPart_0001_5E9B04C9
Content-Type: text/x-rtf
Content-Transfer-Encoding: 7bit

{\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fprq2\fcharset0 MS Sans Serif;}}
\viewkind4\uc1\pard\f0\fs20 Miniports, the target of a set or query OID, as the lowest two layers of the OSI model (PHY & Link), at best, only care about the Ethernet, TR, FDDI, etc, address and anything at the network or protocol layers, including (in the case of IP) is nothing but payload. If you want to affect TCPIP's IP address, you need an API that talks to TCPIP, like the IP Helper APIs.
\par
\par OIDs, since they talk to the miniport and not to TCPIP won't help you. Nor will the INetCfg APIs, as they affect binding between networking components.
\par
\par Remember, a miniport could be bound to any number of protocols, TCPIP being the most common. But, excluding Ethernet NICs that do offload operations, don't care anything past the Ethernet header.
\par
\par HTH,
\par
\par Bryan S. Burgin
\par bburgin@microsoft.com
\par
\par This posting is provided "AS IS" with no warranties, and confers no rights.
\par
\par }
------=_NextPart_0001_5E9B04C9--