HvDisconnectPort function
The HvDisconnectPort function severs a connection that was previously created by the HvConnectPort function.
Syntax
HV_STATUS HvDisconnectPort( _In_ HV_PARTITION_ID ConnectionPartition, _In_ HV_CONNECTION_ID ConnectionId );
Parameters
- ConnectionPartition [in]
-
An HV_PARTITION_ID value that identifies the partition that was sending messages or signal events by using the connection that HvDisconnectPort severs. HV_PARTITION_ID is defined as an unsigned 64-bit (UINT64) value.
- ConnectionId [in]
-
An HV_CONNECTION_ID value that specifies an identifier that is unique among all connection identifiers for the partition that the ConnectionPartition parameter specifies. The connection identifier is used to refer to the connection that HvDisconnectPort severs.
Return value
HvDisconnectPort returns one of the following values. In addition to these values, HvDisconnectPort can also return one of the values that are specified in Common Hypercall Status Codes.
Return code | Description |
---|---|
|
HvDisconnectPort successfully severed a connection to a port. |
|
Neither of the following is true:
|
|
The specified connection-partition identifier is invalid. |
|
The specified connection identifier is invalid. |
|
The specified connection partition is not in the active state. |
Remarks
When severing a connection, any messages that are present in the port's message queue will be unaffected.
HvDisconnectPort has the following restrictions:
-
The caller must possess the ConnectPort privilege.
-
The partition that is specified by ConnectionPartition must be in the active state.
-
The caller must be the parent of the partition that is specified by ConnectionPartition, or the caller must specify its own partition identifier.
Native Interface
HvDisconnectPort [fast] | |
---|---|
Call Code = 0x005B | |
Input Parameters | |
0 |
ConnectionPartition (8 bytes) |
8 |
ConnectionId (4 bytes) Padding (4 bytes) |
Requirements
Version | HvDisconnectPort is available in version 1.0 and later versions of the hypervisor. |
---|---|
Header |
|
IRQL | Any level |
Send comments about this topic to Microsoft
Build date: 11/16/2013