AtaPortRegistryControllerKeyWriteDeferred function (irb.h)
The AtaPortRegistryControllerKeyWriteDeferred routine writes the data asynchronously to the indicated value name under the registry key HKLM\CurrentControlSet\Services\<service name>\ControllerN
, where N is the number of the controller.
Syntax
BOOLEAN AtaPortRegistryControllerKeyWriteDeferred(
[in] PVOID ChannelExtension,
[in] UCHAR ControllerNumber,
[in] PCHAR ValueName,
[in] UCHAR ValueType,
[in] PUCHAR Buffer,
PULONG BufferLength
);
Parameters
[in] ChannelExtension
A pointer to the channel extension.
[in] ControllerNumber
Contains the controller number.
[in] ValueName
Contains the name of the registry value to write to.
[in] ValueType
Indicates the type of data that is contained in the registry value. This member should be assigned one of values indicated in the following table.
Value | Meaning |
---|---|
IDE_REG_DWORD | A 4-byte numeric value. |
IDE_REG_BINARY | Binary data. |
IDE_REG_SZ | A null-terminated, Unicode string. |
[in] Buffer
A pointer to the source buffer that contains the data to write to the registry value.
BufferLength
A pointer to the number of bytes of data to copy. If the operation fails, the location pointed to by Length will update to the length of data that was successfully copied to the registry.
Return value
AtaPortRegistryControllerKeyWriteDeferred returns TRUE if the operation succeeds. Otherwise, it returns FALSE. The routine also returns FALSE if the miniport driver does not call it from the correct routine.
Remarks
If the value name is not present, the AtaPortRegistryControllerKeyWriteDeferred routine creates an entry for the value name and stores the input data under the newly created value name.
The miniport driver can call the AtaPortRegistryControllerKeyWriteDeferred routine from any of the routines that are defined in the channel interface.
The buffer pointed to by Buffer must be allocated by using AtaPortRegistryAllocateBuffer. The miniport driver must not reuse this buffer after it calls AtaPortRegistryControllerKeyWriteDeferred because the port driver delays writing the key data. If the miniport driver reuses the buffer, it might overwrite the data in the buffer before the port driver has an opportunity to store it in the registry key. The port driver flushes the buffer when the miniport driver calls AtaPortRegistryFreeBuffer to free the buffer.
Requirements
Requirement | Value |
---|---|
Target Platform | Desktop |
Header | irb.h (include Ata.h, Irb.h) |