PcForwardIrpSynchronous function (portcls.h)

The PcForwardIrpSynchronous function is used by IRP handlers to forward Plug and Play IRPs to the physical device object (PDO).

Syntax

PORTCLASSAPI NTSTATUS PcForwardIrpSynchronous(
  [in] PDEVICE_OBJECT DeviceObject,
  [in] PIRP           Irp
);

Parameters

[in] DeviceObject

Pointer to the audio device's device object. This parameter must point to a system structure of type DEVICE_OBJECT.

[in] Irp

Pointer to the IRP that is to be forwarded

Return value

PcForwardIrpSynchronous returns STATUS_SUCCESS if the call was successful. Otherwise, it returns an appropriate error code.

Remarks

PcForwardIrpSynchronous causes the next PDO to receive the IRP and block until the IRP has been completed by the physical device driver. At that point, PcForwardIrpSynchronous unblocks and returns to the caller. The caller (an IRP handler) should eventually return--possibly with a status of STATUS_PENDING. In general, any IRP handler that calls this function must specify the action IRP_ACTION_FINISH upon returning. Any other action would result in the IRP being forwarded to the physical device a second time.

The PcCompleteIrp function is used when an IRP handler returns STATUS_PENDING and the IRP must be completed later.

Requirements

Requirement Value
Minimum supported client The PortCls system driver implements the PcForwardIrpSynchronous function in Microsoft Windows 98/Me and in Windows 2000 and later operating systems.
Target Platform Universal
Header portcls.h (include Portcls.h)
Library Portcls.lib
IRQL PASSIVE_LEVEL

See also

DEVICE_OBJECT

IRP

PcCompleteIrp