driver to driver communication NDIS

hi folks,

I have an IM driver for NDIS. From this driver , I need to…

  1. query whether the underlying miniport (3rd party) has RSS feature
    support.
  2. If it does, I need to some mechanism (maybe a MS defined OID) to disable
    it.

How do I do this task? Solution needs to work for NDIS 5.1,5.2,6.0

thanks in advance.

ap

A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available with 5.1.
My apologies for the typo.

On 8/16/07, A P wrote:
>
> hi folks,
>
> I have an IM driver for NDIS. From this driver , I need to…
>
> 1. query whether the underlying miniport (3rd party) has RSS feature
> support.
> 2. If it does, I need to some mechanism (maybe a MS defined OID) to
> disable it.
>
> How do I do this task? Solution needs to work for NDIS 5.1,5.2,6.0
>
>
> thanks in advance.
>
> ap
>

Read the WDK topics.

“Supporting RSS in Intermediate Drivers or Filter Drivers”

“RSS Configuration”

Thomas F. Divine

http://www.pcausa.com

From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of A P
Sent: Thursday, August 16, 2007 12:56 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] driver to driver communication NDIS

hi folks,

I have an IM driver for NDIS. From this driver , I need to…

  1. query whether the underlying miniport (3rd party) has RSS feature
    support.

  2. If it does, I need to some mechanism (maybe a MS defined OID) to disable
    it.

How do I do this task? Solution needs to work for NDIS 5.1,5.2,6.0

thanks in advance.

ap

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the
List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

> Solution needs to work for NDIS 5.1,5.2,6.0

A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available with 5.1.

First of all, RSS in itself is strictly NDIS 6 feature - it does not apply to earlier OS versions.

You should realize that NDIS 6 is naturally different from earlier NDIS versions. It introduced so-called lightweight filters (LWFs) that replace NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If you want your driver to work on pre-Vista versions, LWF is not the right option for you - it is just not going to work on earlier OS versions.

In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters as well. In practice it means that NDIS 5 filter may be bound to NDIS 6 miniport. Therefore, what you can do is to write NDIS 5 filter that watches OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets the NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check “RSS Configuration” artcicle in WDK documentation for more info on what has to be done in order to disable RSS)

If you do it this way, your driver will be able to work on all OS versions. However, please note that, once NDIS 6 parameters are naturally different from NDIS 5 ones, NDIS has to do parameter translation on every call from/to NDIS 5 filter that runs on Vista, which results in some overhead - the higher the link speed is, the more noticeable overhead becomes…

Anton Bassov

>First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
to earlier OS versions.

I have seen other OS drivers with the same feature, might be the vendors try
implementing a ‘pseudo rss feature’. thanks for disillutioning me.

One other thing I wanted to ask was, HOW DO I pass on the OIDS down to the
next driver. The way I can think of is, after binding to the driver below, I
can use the NdisRequest call to pass the OID down.

Is this the desirable way of doing things?

AP

On 8/17/07, xxxxx@hotmail.com wrote:
>
> > Solution needs to work for NDIS 5.1,5.2,6.0
> …
> > A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available with
> 5.1.

Is Ndislwf a sample of a LWF for vista? If not, kindly point me to a sample
please.

After reading this email, I think I need to maintain two different versions
of drivers for each of the NDIS verions 5.x and 6.0.

First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
> to earlier OS versions.
>
> You should realize that NDIS 6 is naturally different from earlier NDIS
> versions. It introduced so-called lightweight filters (LWFs) that replace
> NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If you
> want your driver to work on pre-Vista versions, LWF is not the right option
> for you - it is just not going to work on earlier OS versions.
>
> In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters as
> well. In practice it means that NDIS 5 filter may be bound to NDIS 6
> miniport. Therefore, what you can do is to write NDIS 5 filter that watches
> OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets the
> NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
> NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check “RSS
> Configuration” artcicle in WDK documentation for more info on what has to be
> done in order to disable RSS)
>
>
> If you do it this way, your driver will be able to work on all OS
> versions. However, please note that, once NDIS 6 parameters are naturally
> different from NDIS 5 ones, NDIS has to do parameter translation on every
> call from/to NDIS 5 filter that runs on Vista, which results in some
> overhead - the higher the link speed is, the more noticeable overhead
> becomes…
>
> Anton Bassov
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Certainly a filter driver can make its own NDIS request calls. The key thing
is to have a way to distinguish between requests that the filter driver
originated and requests that originated from higher levels when the request
completes.

The “Extended Passthru” sample driver at http://www.wd-3.com illustrates
this.

IIRC, NDIS 5.2 does include a “subset” of some higher-performance “NDIS 6”
features. IIRC, NDIS 5.2 is only supported on some OEM versions of Windows
Server 2003.

Good luck,

Thomas F. Divine

http://www/wd-3/com

From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of A P
Sent: Thursday, August 16, 2007 4:58 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] driver to driver communication NDIS

First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
to earlier OS versions.

I have seen other OS drivers with the same feature, might be the vendors try
implementing a ‘pseudo rss feature’. thanks for disillutioning me.

One other thing I wanted to ask was, HOW DO I pass on the OIDS down to the
next driver. The way I can think of is, after binding to the driver below, I
can use the NdisRequest call to pass the OID down.

Is this the desirable way of doing things?

AP

On 8/17/07, xxxxx@hotmail.com wrote:

> Solution needs to work for NDIS 5.1,5.2,6.0

> A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available with
5.1.

Is Ndislwf a sample of a LWF for vista? If not, kindly point me to a sample
please.

After reading this email, I think I need to maintain two different versions
of drivers for each of the NDIS verions 5.x and 6.0.

First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
to earlier OS versions.

You should realize that NDIS 6 is naturally different from earlier NDIS
versions. It introduced so-called lightweight filters (LWFs) that replace
NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If you
want your driver to work on pre-Vista versions, LWF is not the right option
for you - it is just not going to work on earlier OS versions.

In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters as
well. In practice it means that NDIS 5 filter may be bound to NDIS 6
miniport. Therefore, what you can do is to write NDIS 5 filter that watches
OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets the
NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check “RSS
Configuration” artcicle in WDK documentation for more info on what has to be
done in order to disable RSS)

If you do it this way, your driver will be able to work on all OS versions.
However, please note that, once NDIS 6 parameters are naturally different
from NDIS 5 ones, NDIS has to do parameter translation on every call from/to
NDIS 5 filter that runs on Vista, which results in some overhead - the
higher the link speed is, the more noticeable overhead becomes…

Anton Bassov


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the
List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

> One other thing I wanted to ask was, HOW DO I pass on the OIDS down to the

next driver. The way I can think of is, after binding to the driver below, I
can use the NdisRequest call to pass the OID down.

Is this the desirable way of doing things?

Well, this way is not only desirable, but, AFAIK, the only possible one - you pass OIDs to the miniport with NdisRequest(). You can pass both requests that have been originated by the bound protocols and the ones that have been originated by your IM. Just make sure your PtRequestComplete() makes a distinction between these 2 types…

Is Ndislwf a sample of a LWF for vista?

Indeed, it is…

After reading this email, I think I need to maintain two different versions
of drivers for each of the NDIS verions 5.x and 6.0.

This is exactly what I did in one of the projects I worked on - instead of trying to adjust NDIS 5 IM filter to Vista, I just wrote NDIS 6 LWF. I believe that, in the long run, this approach is better than trying to make NDIS 5 filter work under Vista…

Anton Bassov

thomas,

NDIS 5.2 does include a “subset” of some higher-performance “NDIS 6”
features. IIRC, NDIS 5.2 is only supported on some OEM versions of Windows
Server 2003

yes, the SNP for windows 2k3 makes it support Chimney. Also, I believe
Windows XP 64 bit does suport NDIS 5.2 and hence some of the features of
NDIS 6 as mentioned by you.

I might be wrong though.

I am currently reading up the extended passthrough code, i might ask you
some more questions once I am through with it.

thanks,

AP

On 8/17/07, Thomas F. Divine wrote:
>
> Certainly a filter driver can make its own NDIS request calls. The key
> thing is to have a way to distinguish between requests that the filter
> driver originated and requests that originated from higher levels when the
> request completes.
>
>
>
> The “Extended Passthru” sample driver at http://www.wd-3.com illustrates
> this.
>
>
>
> IIRC, NDIS 5.2 does include a “subset” of some higher-performance “NDIS 6”
> features. IIRC, NDIS 5.2 is only supported on some OEM versions of Windows
> Server 2003.
>
>
>
> Good luck,
>
>
>
> Thomas F. Divine
>
> http://www/wd-3/com
>
>
>
>
>
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] *On Behalf Of *A P
> Sent: Thursday, August 16, 2007 4:58 PM
> To: Windows System Software Devs Interest List
> Subject: Re: [ntdev] driver to driver communication NDIS
>
>
>
> >First of all, RSS in itself is strictly NDIS 6 feature - it does not
> apply to earlier OS versions.
>
>
>
>
> I have seen other OS drivers with the same feature, might be the vendors
> try implementing a ‘pseudo rss feature’. thanks for disillutioning me.
>
>
>
>
>
> One other thing I wanted to ask was, HOW DO I pass on the OIDS down to the
> next driver. The way I can think of is, after binding to the driver below, I
> can use the NdisRequest call to pass the OID down.
>
>
>
> Is this the desirable way of doing things?
>
>
>
>
>
> AP
>
>
>
>
>
>
>
> On 8/17/07, xxxxx@hotmail.com wrote:
>
> > Solution needs to work for NDIS 5.1,5.2,6.0
> …
> > A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available with
> 5.1.
>
>
>
> Is Ndislwf a sample of a LWF for vista? If not, kindly point me to a
> sample please.
>
>
>
>
>
> After reading this email, I think I need to maintain two different
> versions of drivers for each of the NDIS verions 5.x and 6.0.
>
>
>
>
>
>
>
> First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
> to earlier OS versions.
>
> You should realize that NDIS 6 is naturally different from earlier NDIS
> versions. It introduced so-called lightweight filters (LWFs) that replace
> NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If you
> want your driver to work on pre-Vista versions, LWF is not the right option
> for you - it is just not going to work on earlier OS versions.
>
> In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters as
> well. In practice it means that NDIS 5 filter may be bound to NDIS 6
> miniport. Therefore, what you can do is to write NDIS 5 filter that watches
> OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets the
> NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
> NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check “RSS
> Configuration” artcicle in WDK documentation for more info on what has to be
> done in order to disable RSS)
>
>
> If you do it this way, your driver will be able to work on all OS
> versions. However, please note that, once NDIS 6 parameters are naturally
> different from NDIS 5 ones, NDIS has to do parameter translation on every
> call from/to NDIS 5 filter that runs on Vista, which results in some
> overhead - the higher the link speed is, the more noticeable overhead
> becomes…
>
> Anton Bassov
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
>
> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
> the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

NDIS 5.2 is available to OEM’s and others to support faster NIC’s on 2003.
It definitely is different from NDIS 5.1 or NDIS 6.0. It should be noted
that Anton’s suggestion of disabling RSS can in some circumstances really
destroy networking performance, and turn a 10GB NIC into a 1GB NIC.


Don Burn (MVP, Windows DDK)
Windows 2k/XP/2k3 Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr
Remove StopSpam to reply

“A P” wrote in message news:xxxxx@ntdev…
> thomas,
>
>>NDIS 5.2 does include a “subset” of some higher-performance “NDIS 6”
> features. IIRC, NDIS 5.2 is only supported on some OEM versions of
> Windows
> Server 2003
>
> yes, the SNP for windows 2k3 makes it support Chimney. Also, I believe
> Windows XP 64 bit does suport NDIS 5.2 and hence some of the features of
> NDIS 6 as mentioned by you.
>
> I might be wrong though.
>
>
> I am currently reading up the extended passthrough code, i might ask you
> some more questions once I am through with it.
>
> thanks,
>
> AP
>
>
>
> On 8/17/07, Thomas F. Divine wrote:
>>
>> Certainly a filter driver can make its own NDIS request calls. The key
>> thing is to have a way to distinguish between requests that the filter
>> driver originated and requests that originated from higher levels when
>> the
>> request completes.
>>
>>
>>
>> The “Extended Passthru” sample driver at http://www.wd-3.com illustrates
>> this.
>>
>>
>>
>> IIRC, NDIS 5.2 does include a “subset” of some higher-performance “NDIS
>> 6”
>> features. IIRC, NDIS 5.2 is only supported on some OEM versions of
>> Windows
>> Server 2003.
>>
>>
>>
>> Good luck,
>>
>>
>>
>> Thomas F. Divine
>>
>> http://www/wd-3/com
>>
>>
>>
>>
>>
>> From: xxxxx@lists.osr.com [mailto:
>> xxxxx@lists.osr.com] *On Behalf Of *A P
>> Sent: Thursday, August 16, 2007 4:58 PM
>> To: Windows System Software Devs Interest List
>> Subject: Re: [ntdev] driver to driver communication NDIS
>>
>>
>>
>> >First of all, RSS in itself is strictly NDIS 6 feature - it does not
>> apply to earlier OS versions.
>>
>>
>>
>>
>> I have seen other OS drivers with the same feature, might be the vendors
>> try implementing a ‘pseudo rss feature’. thanks for disillutioning me.
>>
>>
>>
>>
>>
>> One other thing I wanted to ask was, HOW DO I pass on the OIDS down to
>> the
>> next driver. The way I can think of is, after binding to the driver
>> below, I
>> can use the NdisRequest call to pass the OID down.
>>
>>
>>
>> Is this the desirable way of doing things?
>>
>>
>>
>>
>>
>> AP
>>
>>
>>
>>
>>
>>
>>
>> On 8/17/07, xxxxx@hotmail.com
>> wrote:
>>
>> > Solution needs to work for NDIS 5.1,5.2,6.0
>> …
>> > A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available
>> > with
>> 5.1.
>>
>>
>>
>> Is Ndislwf a sample of a LWF for vista? If not, kindly point me to a
>> sample please.
>>
>>
>>
>>
>>
>> After reading this email, I think I need to maintain two different
>> versions of drivers for each of the NDIS verions 5.x and 6.0.
>>
>>
>>
>>
>>
>>
>>
>> First of all, RSS in itself is strictly NDIS 6 feature - it does not
>> apply
>> to earlier OS versions.
>>
>> You should realize that NDIS 6 is naturally different from earlier NDIS
>> versions. It introduced so-called lightweight filters (LWFs) that
>> replace
>> NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If
>> you
>> want your driver to work on pre-Vista versions, LWF is not the right
>> option
>> for you - it is just not going to work on earlier OS versions.
>>
>> In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters
>> as
>> well. In practice it means that NDIS 5 filter may be bound to NDIS 6
>> miniport. Therefore, what you can do is to write NDIS 5 filter that
>> watches
>> OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets
>> the
>> NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
>> NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check
>> “RSS
>> Configuration” artcicle in WDK documentation for more info on what has
>> to be
>> done in order to disable RSS)
>>
>>
>> If you do it this way, your driver will be able to work on all OS
>> versions. However, please note that, once NDIS 6 parameters are
>> naturally
>> different from NDIS 5 ones, NDIS has to do parameter translation on
>> every
>> call from/to NDIS 5 filter that runs on Vista, which results in some
>> overhead - the higher the link speed is, the more noticeable overhead
>> becomes…
>>
>> Anton Bassov
>>
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>>
>> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging
>> and
>> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
>> the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>

It seems that you want to disable RSS in any case. If this is indeed so,
than please note that on the tcpip parameters you can find a value
called EnableRSS. Set it to 0.

Thanks
Tzachi


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Thomas F. Divine
Sent: Thursday, August 16, 2007 8:13 PM
To: Windows System Software Devs Interest List
Subject: RE: [ntdev] driver to driver communication NDIS

Read the WDK topics.

“Supporting RSS in Intermediate Drivers or Filter Drivers”

“RSS Configuration”

Thomas F. Divine

http://www.pcausa.com

From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of A P
Sent: Thursday, August 16, 2007 12:56 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] driver to driver communication NDIS

hi folks,

I have an IM driver for NDIS. From this driver , I need to…

  1. query whether the underlying miniport (3rd party) has RSS
    feature support.

  2. If it does, I need to some mechanism (maybe a MS defined OID)
    to disable it.

How do I do this task? Solution needs to work for NDIS
5.1,5.2,6.0

thanks in advance.

ap

— NTDEV is sponsored by OSR For our schedule of WDF, WDM,
debugging and other seminars visit: http://www.osr.com/seminars To
unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars
visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

I thought of ndis5.2 a hybrid. For non-chimney path, it uses ndis_packet, for chimney offloaded path, it uses net_buffer_list/net_buffer. and yes, rss is supported in ndis5.2.

we’ve done a lot of work on advanced hw/sw features over the years and learned that RSS can significantly increase throughput as well as PEI in the case of:

  1. there are more than one cpu of course, and
  2. there are many active tcp connections, or
  3. you have LOADs of 1Gbe/10Gbe ports on a server blade and you have a smart teaming driver(a stateful Ndis IM LBFO) that at least understands RSS and TCP chimney.

However, RSS can also significantly degrade the overall networking performance in some scenarios. In such cases, it should be disabled. Note that on the other thread mentioning disabling RSS by messing with TCP registry is a bad advice. Use rss related OID instead.


Calvin Guan
Broadcom Corporation
Connecting Everything(r)
p.s. We’re looking for top notch Windows driver guys (networking, storage) to join us at Irvine, sunny Calif. Send me your resume to hguan__at__broadcom.com if you’re interested.

“Don Burn” wrote in message news:xxxxx@ntdev…

> NDIS 5.2 is available to OEM’s and others to support faster NIC’s on 2003.
> It definitely is different from NDIS 5.1 or NDIS 6.0. It should be noted
> that Anton’s suggestion of disabling RSS can in some circumstances really
> destroy networking performance, and turn a 10GB NIC into a 1GB NIC.
>
>
> –
> Don Burn (MVP, Windows DDK)
> Windows 2k/XP/2k3 Filesystem and Driver Consulting
> Website: http://www.windrvr.com
> Blog: http://msmvps.com/blogs/WinDrvr
> Remove StopSpam to reply
>
>
> “A P” wrote in message news:xxxxx@ntdev…
>> thomas,
>>
>>>NDIS 5.2 does include a “subset” of some higher-performance “NDIS 6”
>> features. IIRC, NDIS 5.2 is only supported on some OEM versions of
>> Windows
>> Server 2003
>>
>> yes, the SNP for windows 2k3 makes it support Chimney. Also, I believe
>> Windows XP 64 bit does suport NDIS 5.2 and hence some of the features of
>> NDIS 6 as mentioned by you.
>>
>> I might be wrong though.
>>
>>
>> I am currently reading up the extended passthrough code, i might ask you
>> some more questions once I am through with it.
>>
>> thanks,
>>
>> AP
>>
>>
>>
>> On 8/17/07, Thomas F. Divine wrote:
>>>
>>> Certainly a filter driver can make its own NDIS request calls. The key
>>> thing is to have a way to distinguish between requests that the filter
>>> driver originated and requests that originated from higher levels when
>>> the
>>> request completes.
>>>
>>>
>>>
>>> The “Extended Passthru” sample driver at http://www.wd-3.com illustrates
>>> this.
>>>
>>>
>>>
>>> IIRC, NDIS 5.2 does include a “subset” of some higher-performance “NDIS
>>> 6”
>>> features. IIRC, NDIS 5.2 is only supported on some OEM versions of
>>> Windows
>>> Server 2003.
>>>
>>>
>>>
>>> Good luck,
>>>
>>>
>>>
>>> Thomas F. Divine
>>>
>>> http://www/wd-3/com
>>>
>>>
>>>
>>>
>>>
>>> From: xxxxx@lists.osr.com [mailto:
>>> xxxxx@lists.osr.com] *On Behalf Of *A P
>>> Sent: Thursday, August 16, 2007 4:58 PM
>>> To: Windows System Software Devs Interest List
>>> Subject: Re: [ntdev] driver to driver communication NDIS
>>>
>>>
>>>
>>> >First of all, RSS in itself is strictly NDIS 6 feature - it does not
>>> apply to earlier OS versions.
>>>
>>>
>>>
>>>
>>> I have seen other OS drivers with the same feature, might be the vendors
>>> try implementing a ‘pseudo rss feature’. thanks for disillutioning me.
>>>
>>>
>>>
>>>
>>>
>>> One other thing I wanted to ask was, HOW DO I pass on the OIDS down to
>>> the
>>> next driver. The way I can think of is, after binding to the driver
>>> below, I
>>> can use the NdisRequest call to pass the OID down.
>>>
>>>
>>>
>>> Is this the desirable way of doing things?
>>>
>>>
>>>
>>>
>>>
>>> AP
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> On 8/17/07, xxxxx@hotmail.com
>>> wrote:
>>>
>>> > Solution needs to work for NDIS 5.1,5.2,6.0
>>> …
>>> > A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available
>>> > with
>>> 5.1.
>>>
>>>
>>>
>>> Is Ndislwf a sample of a LWF for vista? If not, kindly point me to a
>>> sample please.
>>>
>>>
>>>
>>>
>>>
>>> After reading this email, I think I need to maintain two different
>>> versions of drivers for each of the NDIS verions 5.x and 6.0.
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> First of all, RSS in itself is strictly NDIS 6 feature - it does not
>>> apply
>>> to earlier OS versions.
>>>
>>> You should realize that NDIS 6 is naturally different from earlier NDIS
>>> versions. It introduced so-called lightweight filters (LWFs) that
>>> replace
>>> NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If
>>> you
>>> want your driver to work on pre-Vista versions, LWF is not the right
>>> option
>>> for you - it is just not going to work on earlier OS versions.
>>>
>>> In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters
>>> as
>>> well. In practice it means that NDIS 5 filter may be bound to NDIS 6
>>> miniport. Therefore, what you can do is to write NDIS 5 filter that
>>> watches
>>> OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets
>>> the
>>> NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
>>> NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check
>>> “RSS
>>> Configuration” artcicle in WDK documentation for more info on what has
>>> to be
>>> done in order to disable RSS)
>>>
>>>
>>> If you do it this way, your driver will be able to work on all OS
>>> versions. However, please note that, once NDIS 6 parameters are
>>> naturally
>>> different from NDIS 5 ones, NDIS has to do parameter translation on
>>> every
>>> call from/to NDIS 5 filter that runs on Vista, which results in some
>>> overhead - the higher the link speed is, the more noticeable overhead
>>> becomes…
>>>
>>> Anton Bassov
>>>
>>>
>>> —
>>> NTDEV is sponsored by OSR
>>>
>>> For our schedule of WDF, WDM, debugging and other seminars visit:
>>> http://www.osr.com/seminars
>>>
>>> To unsubscribe, visit the List Server section of OSR Online at
>>> http://www.osronline.com/page.cfm?name=ListServer
>>>
>>>
>>> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging
>>> and
>>> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
>>> the List Server section of OSR Online at
>>> http://www.osronline.com/page.cfm?name=ListServer
>>>
>>> —
>>> NTDEV is sponsored by OSR
>>>
>>> For our schedule of WDF, WDM, debugging and other seminars visit:
>>> http://www.osr.com/seminars
>>>
>>> To unsubscribe, visit the List Server section of OSR Online at
>>> http://www.osronline.com/page.cfm?name=ListServer
>>>
>>
>
>
>

>>>NDIS 5.2 does include a “subset” of some higher-performance “NDIS 6”

> features. IIRC, NDIS 5.2 is only supported on some OEM versions of
> Windows
> Server 2003

My understanding is the SNP was rolled into W2K3 SP2, so a large percentage
of W2K3 systems should support NDIS 5.2. I believe SNP/SP2 also added
support for Intel’s NetDMA which allows the TCP stack to use DMA hardware on
certain newer motherboards to copy received packets from the low level
packet buffers into higher level application buffers.

Jan

>First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
to earlier OS versions.

IIRC, after installing the SNP on Windows 2k3 (SP2 release) we can make the
OS support Chimney and RSS. I think, WinXP 64 bit can also handle the same.

Regards,

AB

On 8/17/07, xxxxx@hotmail.com wrote:
>
> > Solution needs to work for NDIS 5.1,5.2,6.0
> …
> > A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available with
> 5.1.
>
>
>
> First of all, RSS in itself is strictly NDIS 6 feature - it does not apply
> to earlier OS versions.
>
> You should realize that NDIS 6 is naturally different from earlier NDIS
> versions. It introduced so-called lightweight filters (LWFs) that replace
> NDIS 5-style IM filters (i.e. miniport and protocol in one driver). If you
> want your driver to work on pre-Vista versions, LWF is not the right option
> for you - it is just not going to work on earlier OS versions.
>
> In addition to NDIS 6 LWFs, Vista supports “legacy”(i.e. 5x) IM filters as
> well. In practice it means that NDIS 5 filter may be bound to NDIS 6
> miniport. Therefore, what you can do is to write NDIS 5 filter that watches
> OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets the
> NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
> NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check “RSS
> Configuration” artcicle in WDK documentation for more info on what has to be
> done in order to disable RSS)
>
>
> If you do it this way, your driver will be able to work on all OS
> versions. However, please note that, once NDIS 6 parameters are naturally
> different from NDIS 5 ones, NDIS has to do parameter translation on every
> call from/to NDIS 5 filter that runs on Vista, which results in some
> overhead - the higher the link speed is, the more noticeable overhead
> becomes…
>
> Anton Bassov
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>



- amitr0

hi all,

This post is exclusively about the Powr Management tab for network adapters.

  1. can we have an IM driver have power capabilities, or atleast the ability
    to pass on the power capabilitis to the driver below it?
  2. would the OS even send power requests to this IM driver? Since it doesn’t
    have any real adapter.
  3. If I want to show the same power options as of the base adapter I am
    bound to in my IM (for the sake of simplicity lets assume i will bind to
    only one adapter), it that doable?

AP

On 8/19/07, amitr0 wrote:
>
> >First of all, RSS in itself is strictly NDIS 6 feature - it does not
> apply to earlier OS versions.
>
> IIRC, after installing the SNP on Windows 2k3 (SP2 release) we can make
> the OS support Chimney and RSS. I think, WinXP 64 bit can also handle the
> same.
>
> Regards,
>
> AB
>
>
>
> On 8/17/07, xxxxx@hotmail.com < xxxxx@hotmail.com> wrote:
> >
> > > Solution needs to work for NDIS 5.1,5.2,6.0
> > …
> > > A slight correction, I meant NDIS 5.2 and 6.0, RSS is not available
> > with 5.1.
> >
> >
> >
> > First of all, RSS in itself is strictly NDIS 6 feature - it does not
> > apply to earlier OS versions.
> >
> > You should realize that NDIS 6 is naturally different from earlier NDIS
> > versions. It introduced so-called lightweight filters (LWFs) that replace
> > NDIS 5-style IM filters ( i.e. miniport and protocol in one driver). If
> > you want your driver to work on pre-Vista versions, LWF is not the right
> > option for you - it is just not going to work on earlier OS versions.
> >
> > In addition to NDIS 6 LWFs, Vista supports “legacy”( i.e. 5x) IM filters
> > as well. In practice it means that NDIS 5 filter may be bound to NDIS 6
> > miniport. Therefore, what you can do is to write NDIS 5 filter that watches
> > OID_GEN_RECEIVE_SCALE_PARAMETERS if the OS version is Vista, and sets the
> > NDIS_RSS_PARAM_FLAG_DISABLE_RSS flag in the Flags member of the
> > NDIS_RECEIVE_SCALE_PARAMETERS structure in order to disable RSS (check “RSS
> > Configuration” artcicle in WDK documentation for more info on what has to be
> > done in order to disable RSS)
> >
> >
> > If you do it this way, your driver will be able to work on all OS
> > versions. However, please note that, once NDIS 6 parameters are naturally
> > different from NDIS 5 ones, NDIS has to do parameter translation on every
> > call from/to NDIS 5 filter that runs on Vista, which results in some
> > overhead - the higher the link speed is, the more noticeable overhead
> > becomes…
> >
> > Anton Bassov
> >
> >
> > —
> > NTDEV is sponsored by OSR
> >
> > For our schedule of WDF, WDM, debugging and other seminars visit:
> > http://www.osr.com/seminars
> >
> > To unsubscribe, visit the List Server section of OSR Online at
> > http://www.osronline.com/page.cfm?name=ListServer
> >
>
>
>
> –
>
> - amitr0 — NTDEV is sponsored by OSR For our schedule of WDF, WDM,
> debugging and other seminars visit: http://www.osr.com/seminars To
> unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer

hi all,

I am confused here.

I want to open the driver device for an ndis IM driver.

I read the passthruEx sample by PCAUSA, there I see IRP_MJ_CREATE/CLOSE/ and
other IRP handlers as well s device io control handlers being used to open
the device by the user mode application.

But, I read some where that NDIS drivers do not need to handle any IRPs at
all, NDIS takes care of them and internally passes on those calls to some
function pointers which are registered for the purpose.

So why do we then need those handlers in the sample said above?

I apologise for my ignorance.

AP

You only need them if you want user-mode interaction with your IM driver.

Of course, if you have no need for user-mode interaction with the IM driver,
then take I/O support out.

Thomas F. Divine

From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of A P
Sent: Friday, August 24, 2007 4:55 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] driver to driver communication NDIS

hi all,

I am confused here.

I want to open the driver device for an ndis IM driver.

I read the passthruEx sample by PCAUSA, there I see IRP_MJ_CREATE/CLOSE/ and
other IRP handlers as well s device io control handlers being used to open
the device by the user mode application.

But, I read some where that NDIS drivers do not need to handle any IRPs at
all, NDIS takes care of them and internally passes on those calls to some
function pointers which are registered for the purpose.

So why do we then need those handlers in the sample said above?

I apologise for my ignorance.

AP

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the
List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer

Thomas,

Doesn’t NDIS provide wrappers for those? We have a vista miniport FD, and
ofcourse we have an usermode GUI for that, we didn’t implement those IRP
handlers. Am I missing something here?

AB

On 8/25/07, Thomas F. Divine wrote:
>
> You only need them if you want user-mode interaction with your IM driver.
>
>
>
> Of course, if you have no need for user-mode interaction with the IM
> driver, then take I/O support out.
>
>
>
> Thomas F. Divine
>
>
>
>
>
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] *On Behalf Of *A P
> Sent: Friday, August 24, 2007 4:55 PM
> To: Windows System Software Devs Interest List
> Subject: Re: [ntdev] driver to driver communication NDIS
>
>
>
> hi all,
>
>
>
>
>
> I am confused here.
>
>
>
> I want to open the driver device for an ndis IM driver.
>
>
>
> I read the passthruEx sample by PCAUSA, there I see IRP_MJ_CREATE/CLOSE/
> and other IRP handlers as well s device io control handlers being used to
> open the device by the user mode application.
>
>
>
> But, I read some where that NDIS drivers do not need to handle any IRPs at
> all, NDIS takes care of them and internally passes on those calls to some
> function pointers which are registered for the purpose.
>
>
>
> So why do we then need those handlers in the sample said above?
>
>
>
>
>
> I apologise for my ignorance.
>
>
>
> AP
>
> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
> the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>



- amitr0

> I read the passthruEx sample by PCAUSA, there I see IRP_MJ_CREATE/CLOSE/ and

other IRP handlers as well s device io control handlers being used to open
the device by the user mode application.

But, I read some where that NDIS drivers do not need to handle any IRPs at
all, NDIS takes care of them and internally passes on those calls to some
function pointers which are registered for the purpose.

So why do we then need those handlers in the sample said above?

Normally non-NDIS components are not supposed to access miniport directly. However, if your miniport driver wants to be directly accessible by non-NDIS components , it can register a standalone device with NdisMRegisterDevice() , so that non-NDIS components can send IRPs to it, i.e. access it via a “regular” Dispatch interface. Please note that this device has nothing to do with a network stack.

Anton Bassov

anton,

your answer clears some of the mist. but i am ever more curious now. so if i
want to go by the book and write an user mode app that needs to communicate
with my ndis driver without me exposing the irp handlers, then how do i do
that? what all entry points do i tap?

ap

On 8/25/07, xxxxx@hotmail.com wrote:
>
> > I read the passthruEx sample by PCAUSA, there I see IRP_MJ_CREATE/CLOSE/
> and
> > other IRP handlers as well s device io control handlers being used to
> open
> > the device by the user mode application.
>
> > But, I read some where that NDIS drivers do not need to handle anyw do i
> do than ho IRPs at
> > all, NDIS takes care of them and internally passes on those calls to
> some
> > function pointers which are registered for the purpose.
>
> > So why do we then need those handlers in the sample said above?
>
>
> Normally non-NDIS components are not supposed to access miniport directly.
> However, if your miniport driver wants to be directly accessible by
> non-NDIS components , it can register a standalone device with
> NdisMRegisterDevice() , so that non-NDIS components can send IRPs to it,
> i.e. access it via a “regular” Dispatch interface. Please note that this
> device has nothing to do with a network stack.
>
> Anton Bassov
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Perhaps your miniport uses WMI interface to your application. You can do the
same with your IM driver.

IIRC, Part 2 of the Extended Passthru samples illustrates packet blocking.
There are two variations: 1.) I/O used to configure blocking and 2.) WMI
used to configure blocking.

Certainly if you are not interested in a conventional I/O interface to your
driver, take it out.

There is no “wrapper” for miniport IRP-based I/O that I know of.

Thomas

From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of amitr0
Sent: Friday, August 24, 2007 5:40 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] driver to driver communication NDIS

Thomas,

Doesn’t NDIS provide wrappers for those? We have a vista miniport FD, and
ofcourse we have an usermode GUI for that, we didn’t implement those IRP
handlers. Am I missing something here?

AB

On 8/25/07, Thomas F. Divine wrote:

You only need them if you want user-mode interaction with your IM driver.

Of course, if you have no need for user-mode interaction with the IM driver,
then take I/O support out.

Thomas F. Divine

From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of A P
Sent: Friday, August 24, 2007 4:55 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] driver to driver communication NDIS

hi all,

I am confused here.

I want to open the driver device for an ndis IM driver.

I read the passthruEx sample by PCAUSA, there I see IRP_MJ_CREATE/CLOSE/ and
other IRP handlers as well s device io control handlers being used to open
the device by the user mode application.

But, I read some where that NDIS drivers do not need to handle any IRPs at
all, NDIS takes care of them and internally passes on those calls to some
function pointers which are registered for the purpose.

So why do we then need those handlers in the sample said above?

I apologise for my ignorance.

AP

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the
List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer



- amitr0 — NTDEV is sponsored by OSR For our schedule of WDF, WDM,
debugging and other seminars visit: http://www.osr.com/seminars To
unsubscribe, visit the List Server section of OSR Online at
http://www.osronline.com/page.cfm?name=ListServer