ZwSetInformationEnlistment routine

The ZwSetInformationEnlistment routine sets information for a specified enlistment object.

Syntax


NTSTATUS ZwSetInformationEnlistment(
  _In_  HANDLE EnlistmentHandle,
  _In_  ENLISTMENT_INFORMATION_CLASS EnlistmentInformationClass,
  _In_  PVOID EnlistmentInformation,
  _In_  ULONG EnlistmentInformationLength
);

Parameters

EnlistmentHandle [in]

A handle to an enlistment object that was obtained by a previous call to ZwCreateEnlistment or ZwOpenEnlistment. The handle must have ENLISTMENT_SET_INFORMATION access to the object.

EnlistmentInformationClass [in]

A ENLISTMENT_INFORMATION_CLASS-typed enumeration value that specifies the type of information to be set. This value must be EnlistmentRecoveryInformation.

The enumeration's EnlistmentBasicInformation and EnlistmentFullInformation values are not used with ZwSetInformationEnlistment.

EnlistmentInformation [in]

A pointer to a caller-allocated buffer that contains caller-defined recovery information for the enlistment.

EnlistmentInformationLength [in]

The length, in bytes, of the buffer that the EnlistmentInformation parameter points to.

Return value

ZwSetInformationEnlistment returns STATUS_SUCCESS if the operation succeeds. Otherwise, this routine might return one of the following values:

Return codeDescription
STATUS_OBJECT_TYPE_MISMATCH

The specified handle is not a handle to an enlistment object.

STATUS_INVALID_HANDLE

The object handle is invalid.

STATUS_INVALID_INFO_CLASS

The EnlistmentInformationClass parameter's value is invalid.

STATUS_INFO_LENGTH_MISMATCH

The EnlistmentInformationLength parameter's value is invalid.

STATUS_ACCESS_DENIED

The caller does not have appropriate access to the enlistment object.

 

The routine might return other NTSTATUS values.

Remarks

A resource manager can use the ZwSetInformationEnlistment routine to set recovery information for an enlistment. KTM writes the recovery information to the log stream, and the resource manager can call ZwQueryInformationEnlistment to read this information from the log stream at any time.

Each subsequent call to ZwSetInformationEnlistment deletes the recovery information that the previous call specified before it stores the new recovery information.

For more information about how to use ZwSetInformationEnlistment, see Using Log Streams with KTM.

Requirements

Version

Available in Windows Vista and later operating system versions.

Header

Wdm.h (include Wdm.h, Ntddk.h, or Ntifs.h)

Library

Ntoskrnl.lib

IRQL

PASSIVE_LEVEL

DDI compliance rules

PowerIrpDDis, HwStorPortProhibitedDDIs

See also

ENLISTMENT_INFORMATION_CLASS
ZwCreateEnlistment
ZwOpenEnlistment
ZwQueryInformationEnlistment

 

 

Send comments about this topic to Microsoft

Show:
© 2015 Microsoft