EFI_USBFN_IO_PROTOCOL.SetEndpointPolicy

The SetEndpointPolicy function sets the configuration policy for the specified non-control endpoint.

Syntax

typedef
EFI_STATUS
(EFIAPI * EFI_USBFN_SET_ENDPOINT_POLICY) (
  IN EFI_USBFN_IO_PROTOCOL        *This,
  IN UINT8                        EndpointIndex,
  IN EFI_USBFN_ENDPOINT_DIRECTION Direction,
  IN EFI_USBFN_POLICY_TYPE        PolicyType,
  IN UINTN                        BufferSize,
  IN VOID                         *Buffer
  );

Parameters

This
A pointer to the EFI_USBFN_IO_PROTOCOL instance.

EndpointIndex
Indicates the non-control endpoint for which the policy needs to be set.

Direction
The direction of the endpoint. For more information, see EFI_USBFN_ENDPOINT_DIRECTION.

PolicyType
The policy type the user is trying to set for the specified non-control endpoint. For more information, see EFI_USBFN_POLICY_TYPE.

BufferSize
The size of Buffer in bytes.

Buffer
A pointer to the buffer that contains the new endpoint policy value. For more information about the size requirements of the policy types, see EFI_USBFN_POLICY_TYPE.

Return values

The function returns one of the following values:

Return code Description
EFI_SUCCESS The function returned successfully.
EFI_INVALID_PARAMETER A parameter is invalid.
EFI_DEVICE_ERROR The physical device reported an error.
EFI_UNSUPPORTED Changing this policy value is not supported.

Remarks

This function can be called only before EFI_USBFN_IO_PROTOCOL.StartController or after EFI_USBFN_IO_PROTOCOL.StopController has been called. This function is available starting in revision 0x00010001 of the EFI_USBFN_IO_PROTOCOL.

Requirements

Header: User generated