Eric Kohl wrote:
Wouldn't it be better if WrapperConfigurationContext in the call to NdisMQueryAdapterResources was a pointer to the physical device objects device node rather than a handle to the miniport drivers registry key?
No. In fact it was registry handle till NDIS4 and since NDIS5 it's a structure. I have this part partly rewritten in my tree.
In this case NdisMQueryAdapterResource could retrieve the current resource list from the device node and other information, like the device instance id, are eaily accessible too.
Incidentally I have NdisMQueryAdapterResource implemented in my local tree. It gets the resources from the AllocatedResources field in the NDIS_MINIPORT_BLOCK structure which is itself filled in the IRP_MN_START_DEVICE dispatch code. There are two problems with this: 1) The PnP resource assigning in kernel isn't implemented yet (only the untraslated boot configuration is reported to device now, but it might be enough for this case) We need to assign the resources to each device based on the resource requirements (see IRP_MN_QUERY_RESOURCE_REQUIREMENTS, IRP_MN_FILTER_RESOURCE_REQUIREMENTS and _DEVICE_NODE) and then translate them to bus neutral form. (I've written the translation code, but I seriously doubt it's correct.) 2) Currently the RTL8193 card isn't found by our PCI driver (which reports the resources) and so we need this too to proceed further. (Gerard/Hartmut, if you want to help me with this problem, please run http://www.volny.cz/xnavara/devcon.zip on your system under Windows and send me the results back).
Regards, Filip