Re: NDIS WDM driver installation for multi-port NIC



I looked again at the ndiswdm.inf and caught the line for Addservice. It's
the SPSVCINST_ASSOCSERVICE flags that I was missing. So this is the reason
why the netdrv.inf file installed both the ndiswdm driver and the pcidrv
driver at the same time--the ndiswdm driver was acting as a filter, but was
using the pcidrv driver as the function driver. Now that I have the infs
separate, each driver is acting as its own function driver.

I think I also understand now why the miniport got the device objects
differently. In the filter/function (ndiswdm/pcidrv) driver installation
combo, NdisMGetDeviceProperty would return back the function driver (pcidrv)
because the inf files linked the two driver togethers. However, when
installed as a separate function driver (ndiswdm only), the driver has to now
figure out who to talk to, depending on how it was installed.

Am I correct in undersstanding that in my case, because I've created a PDO
for the port from the c5ebus driver, the miniport can use the PDO to retrieve
the bus driver's FDO and send IRPs to that device object?

Does this also mean that when the miniport is not installed as a filter
driver but as a function driver, that any interfaces that the c5ebus
registers is now accessible once again by a user application since the c5ebus
driver is once again at the top of the device stack?

"Eliyas Yakub [MSFT]" wrote:

My suggestion would be to keep the bus driver separate from the ndis-wdm
driver. In other words, install the ndis-wdm driver as a function driver
for the ports that you enumerate and not use that as an upper filter of bus
driver for one of the ports.

This is what I would do:

1) Define a new setup class for your bus driver (C5eBus.sys) and install
that under that class. I wouldn't use System class. If you ever go to MS for
logo, they wouldn't like if you use System class for your PCI device. You
can use the first INF that you posted for this. You have to add
ClassInstall32 section to create your own class. Take a look at the
toaster.inf sample. Create a new guid to represent your class. You shouldn't
have any NDIS specific directive in this file such as characteristics,
BuyType. This bus driver would then do a static enumeration or enumerate
ports based on application command.

2) Install the ndisedge as a function driver for the child devices you
enumerate. Your second INF (Net Class) looks good to me. I suggest you don't
use ndisedge as the name of the miniport driver. This is the name of the
sample driver. If another vendor uses the same name for his driver then you
will run into issues. Come up with your own unique name.

Now the question is that how independent the child devices are. What if I
disable one child device, will the others devices get affected by that.

I don't think you have issues with sharing hardware resources because by
using NDIS-WDM driver, the miniport is going to send the data down and your
bus driver will interface with the hardware at the PDO level. Correct?

--
-Eliyas
This posting is provided "AS IS" with no warranties, and confers no rights.
http://www.microsoft.com/whdc/driver/tips/default.mspx


.



Relevant Pages

  • Re: XP HOME BOOT FAILURE
    ... you remove the driver for the graphics card, ... >> If you run a repair install as I initially described, ... A repair install should bypass that but it will ... >>>> on, follow the screens. ...
    (microsoft.public.windowsxp.accessibility)
  • Problems with Touchpad,keyboard and USB after Ideacom update (solu
    ... and keyboard .I have made fresh install of XP Home and have all updated ... recomended update from Driver detective,that i use offten. ... allready and when i do this it knocks off my USB mouse leaving me not able to ... 2.Mutil-Access driver HCT driver verify crash fix! ...
    (microsoft.public.windowsxp.general)
  • Re: INF file for an ACPI button filter
    ... I can't be certain but it looks like there was no function driver loaded on the devnode you are trying to add a filter driver to. ... You need to install a function driver first. ... driver "ACPI button Upper Device Filter" will be installed. ...
    (microsoft.public.development.device.drivers)
  • Re: XP update loses sound card
    ... I assume you tried a forced install of a soundcard? ... should try the sound card driver from Toshiba ... The WINMM WDM Audio driver is out of the list now. ... The sound is enabled and uninstalling the Microsoft WINMM WDM Audio ...
    (microsoft.public.windowsupdate)
  • OT: What do you do with your old computers?
    ... connected that to the WLAN as well, using a small USB wireless link. ... And what about backups for petesp4 and Bigblack? ... Once it was talking to the network, I decided to install the printer and the ... driver, and was marked as an unknown device. ...
    (comp.lang.cobol)