FN_VMB_PACKET_INITIALIZE callback function (vmbuskernelmodeclientlibapi.h)
[Some information relates to pre-released product which may be substantially modified before it's commercially released. Microsoft makes no warranties, express or implied, with respect to the information provided here.]
The VmbPacketInitialize function initializes a buffer to contain a VMBus packet.
Syntax
FN_VMB_PACKET_INITIALIZE FnVmbPacketInitialize;
NTSTATUS FnVmbPacketInitialize(
VMBCHANNEL Channel,
VMBPACKET VmbPacket,
UINT32 ByteCount
)
{...}
Parameters
Channel
A handle for a channel.
VmbPacket
The buffer to use to store the VMBus packet.
ByteCount
The size of Buffer, in bytes.
Return value
VmbPacketInitialize returns the following status codes:
Return code | Description |
---|---|
|
The function finished successfully. |
|
The value of ByteCount is not valid. It needs to be greater than the maximum packet size plus the size of a void pointer. |
Remarks
The size of the buffer must be at least the size calculated by using the VmbChannelSizeofPacket function.
VmbPacketInitialize is an alternative to the VmbPacketAllocate function. Use the current function if the caller supplies the memory for the packet object.
The packet's initial completion routine is invalid and must be set before sending the packet.
Important
This function is called through the VMBus Kernel Mode Client Library (KMCL) interface, provided by the Vmbkmcl.sys bus driver. This is a client function accessed from the KMCL_CLIENT_INTERFACE_V1 structure.
For more information, see the Remarks section of the KMCL_CLIENT_INTERFACE_V1.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows 10, version 1803 |
Header | vmbuskernelmodeclientlibapi.h |