Bagikan melalui


NdisMFreeMapRegisters function

Note   NDIS 5. x has been deprecated and is superseded by NDIS 6. x. For new NDIS driver development, see Network Drivers Starting with Windows Vista. For information about porting NDIS 5. x drivers to NDIS 6. x, see Porting NDIS 5.x Drivers to NDIS 6.0.

NdisMFreeMapRegisters releases a set of map registers that were allocated during initialization with NdisMAllocateMapRegisters by a bus-master DMA NIC driver.

Syntax

VOID NdisMFreeMapRegisters(
  _In_ NDIS_HANDLE MiniportAdapterHandle
);

Parameters

Return value

None

Remarks

If it has already made a successful call to NdisMAllocateMapRegisters, the NIC driver of a bus-master DMA device calls NdisMFreeMapRegisters if any of the following occurs:

  • Its MiniportInitialize function is unable to initialize the NIC, so this function must release all existing claims on hardware resources for that NIC before it returns control.

  • The NIC for which the miniport driver allocated the map registers is being removed.

  • The driver is being unloaded, either because the system is shutting down or because the user reconfigured the network components used in the machine.

As soon as it calls NdisMFreeMapRegisters, the driver of a bus-master DMA NIC can no longer use the map registers it previously allocated.

NdisMFreeMapRegisters can be called only from a NIC driver's MiniportInitialize and MiniportHalt functions.

Before calling NdisMFreeMapRegisters, a NIC driver must free any shared memory that it previously allocated. A driver frees shared memory by calling NdisMFreeSharedMemory.

Requirements

Target platform

Universal

Version

Not supported for NDIS 6.0 drivers in Windows Vista. Supported for NDIS 5.1 drivers in Windows Vista and Windows XP.

Header

Ndis.h (include Ndis.h)

Library

Ndis.lib

IRQL

PASSIVE_LEVEL

See also

MiniportHalt

MiniportInitialize

NdisMAllocateMapRegisters

NdisMFreeSharedMemory

 

 

Send comments about this topic to Microsoft