// ndis.h
ALLOCATE_SHARED_MEMORY_HANDLER AllocateSharedMemoryHandler;
NDIS_STATUS AllocateSharedMemoryHandler(
[in] NDIS_HANDLE ProviderContext,
[in] PNDIS_SHARED_MEMORY_PARAMETERS SharedMemoryParameters,
[in, out] PNDIS_HANDLE pSharedMemoryProviderContext
)
{...}
View the official Windows Driver Kit DDI reference
No description available.
The NetAllocateSharedMemory function (ALLOCATE_SHARED_MEMORY_HANDLER entry point) is called by NDIS when a driver allocates shared memory from a shared memory provider.
ProviderContext
[in]An NDIS_HANDLE to a block of driver-allocated context information that identifies the provider. The provider supplied this information in the ProviderContext member of the NDIS_SHARED_MEMORY_PROVIDER_CHARACTERISTICS structure.
SharedMemoryParameters
[in]A pointer to an NDIS_SHARED_MEMORY_PARAMETERS structure that defines the requested attributes for the shared memory.
pSharedMemoryProviderContext
[in, out]A pointer to a handle for a shared memory context area. The shared memory provider provides a handle that identifies the shared memory that it allocated.
NetAllocateSharedMemory can return the following status values:
Return code | Description |
---|---|
NDIS_STATUS_SUCCESS | The operation completed successfully. |
NDIS_STATUS_RESOURCES | The operation failed because there were insufficient resources to complete the operation. |
NDIS_STATUS_INVALID_PARAMETER | The operation failed because of an invalid input parameter. |
NDIS_STATUS_FAILURE | The operation failed for unspecified reasons. |
NDIS calls the NetAllocateSharedMemory function of a shared memory provider when a driver calls the NdisAllocateSharedMemory function.
The shared memory provider specified the entry point (ALLOCATE_SHARED_MEMORY_HANDLER) for NetAllocateSharedMemory in the NDIS_SHARED_MEMORY_PROVIDER_CHARACTERISTICS structure.
NDIS_SHARED_MEMORY_PROVIDER_CHARACTERISTICS