The NdisMSetMiniportAttributes function replaces the NdisMSetAttributes and NdisMSetAttributesEx functions. The driver passes miniport adapter configuration attributes to NdisMSetMiniportAttributes, including the medium type, flags, check-for-hang time, and interface type.
The NDIS_MINIPORT_ADAPTER_ATTRIBUTES structure passed to NdisMSetMiniportAttributes is actually a pointer to one of the following structures:
NDIS_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES
NDIS_MINIPORT_ADAPTER_GENERAL_ATTRIBUTES
NDIS_MINIPORT_ADAPTER_OFFLOAD_ATTRIBUTES
The registration attributes flags of the miniport adapter are updated for NDIS 6.0.
All NDIS 6.0 and later miniport drivers are deserialized. Therefore, the NDIS_ATTRIBUTE_DESERIALIZE attribute flag is removed.
The following code sample shows initialization of a registration attributes structure:
MiniportAttributes.Header.Type = NDIS_OBJECT_TYPE_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES;
MiniportAttributes.Header.Revision = NDIS_MINIPORT_ADAPTER_REGISTRATION_ATTRIBUTES_REVISION_1;
MiniportAttributes.Header.Size = sizeof(MiniportAttributes);
MiniportAttributes.AttributeFlags = NDIS_MINIPORT_ATTRIBUTES_HARDWARE_DEVICE | NDIS_ATTRIBUTE_BUS_MASTER;
MiniportAttributes.CheckForHangTimeInSeconds = 2;
MiniportAttributes.InterfaceType = NdisInterfacePci;
For more information about setting miniport driver attributes, see Initializing an Adapter.