// wdfiotarget.h
VOID WDF_IO_TARGET_OPEN_PARAMS_INIT_OPEN_BY_NAME(
[out] PWDF_IO_TARGET_OPEN_PARAMS Params,
[in] PCUNICODE_STRING TargetDeviceName,
[in] ACCESS_MASK DesiredAccess
);
View the official Windows Driver Kit DDI reference
No description available.
[Applies to KMDF and UMDF]
The WDF_IO_TARGET_OPEN_PARAMS_INIT_OPEN_BY_NAME function initializes a driver's WDF_IO_TARGET_OPEN_PARAMS structure so the driver can open an I/O target by specifying the name of the device, file, or device interface. If the supplied name does not exist, the system will not try to create it.
Params
[out]A pointer to a driver-allocated WDF_IO_TARGET_OPEN_PARAMS structure, which the function initializes.
TargetDeviceName
[in]A value for the TargetDeviceName member of the WDF_IO_TARGET_OPEN_PARAMS structure.
DesiredAccess
[in]A value for the DesiredAccess member of the WDF_IO_TARGET_OPEN_PARAMS structure.
If TargetDeviceName specifies the name of a file that already exists, the system opens the existing file. If the file does not exist, the open operation fails.
The WDF_IO_TARGET_OPEN_PARAMS structure is used as input to the WdfIoTargetOpen method.
The WDF_IO_TARGET_OPEN_PARAMS_INIT_OPEN_BY_NAME function initializes the Size, Type, TargetDeviceName, DesiredAccess, CreateOptions, and CreateDisposition members of the specified WDF_IO_TARGET_OPEN_PARAMS structure.
KMDF The WDF_IO_TARGET_OPEN_PARAMS_INIT_OPEN_BY_NAME function initializes the CreateDisposition member to FILE_OPEN.
UMDF The WDF_IO_TARGET_OPEN_PARAMS_INIT_OPEN_BY_NAME function initializes the CreateDisposition member to OPEN_EXISTING.
For more information about I/O targets, see Using I/O Targets.
For a code example that uses WDF_IO_TARGET_OPEN_PARAMS_INIT_OPEN_BY_NAME, see WdfIoTargetOpen.
WDF_IO_TARGET_OPEN_PARAMS_INIT_CREATE_BY_NAME
WDF_IO_TARGET_OPEN_PARAMS_INIT_EXISTING_DEVICE