// storport.h
ULONG StorPortReadRegistryKey(
PVOID HwDeviceExtension,
PWSTR AbsolutePath,
PWSTR KeyName,
ULONG ValueType,
PVOID *ValueData,
PULONG ValueDataLength
);
View the official Windows Driver Kit DDI referenceNo description available.
The StorPortReadRegistryKey function is used by the miniport to read the specified registry key. The caller provides the absolute path to the key to be read.
HwDeviceExtensionA pointer to the hardware device extension. This is specific to the miniport driver instance.
AbsolutePathThe absolute path to the key to be read.
KeyNameThe key path under the absolute path.
ValueTypeThe type of the registry key value in REG_XXXX format. Currently, only REG_DWORD value type is supported.
ValueDataPointer to the data buffer to receive the registry key value.
ValueDataLengthThe size of the ValueData, in bytes.
Returns a STOR_STATUS code as defined in storport.h.