ehci.h

来自「EFI BIOS是Intel提出的下一代的BIOS标准。这里上传的Edk源代码是」· C头文件 代码 · 共 2,735 行 · 第 1/4 页

H
2,735
字号

Routine Description:

  Read  Ehc Capabitlity register

Arguments:

  HcDev             - USB2_HC_DEV
  CapabiltiyRegAddr - Ehc Capability register address
  Data              - A pointer to data read from register

Returns:

  EFI_SUCCESS        Success
  EFI_DEVICE_ERROR   Fail

--*/
;

EFI_STATUS
ReadEhcOperationalReg (
  IN USB2_HC_DEV             *HcDev,
  IN UINT32                  OperationalRegAddr,
  IN OUT UINT32              *Data
  )
/*++

Routine Description:

  Read  Ehc Operation register

Arguments:

  HcDev                - USB2_HC_DEV
  OperationalRegAddr   - Ehc Operation register address
  Data                 - A pointer to data read from register

Returns:

  EFI_SUCCESS        Success
  EFI_DEVICE_ERROR   Fail

--*/
;

EFI_STATUS
WriteEhcOperationalReg (
  IN USB2_HC_DEV             *HcDev,
  IN UINT32                  OperationalRegAddr,
  IN UINT32                  Data
  )
/*++

Routine Description:

  Write  Ehc Operation register

Arguments:

  HcDev                - USB2_HC_DEV
  OperationalRegAddr   - Ehc Operation register address
  Data                 - 32bit write to register

Returns:

  EFI_SUCCESS        Success
  EFI_DEVICE_ERROR   Fail

--*/
;

EFI_STATUS
SetEhcDoorbell (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Set Ehc door bell bit

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
SetFrameListLen (
  IN USB2_HC_DEV     *HcDev,
  IN UINTN           Length
  )
/*++

Routine Description:

  Set the length of Frame List

Arguments:

  HcDev    - USB2_HC_DEV
  Length   - the required length of frame list

Returns:

  EFI_SUCCESS            Success
  EFI_INVALID_PARAMETER  Invalid parameter
  EFI_DEVICE_ERROR       Fail

--*/
;

BOOLEAN
IsFrameListProgrammable (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Whether frame list is programmable

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  TRUE   Programmable
  FALSE  Unprogrammable

--*/
;

BOOLEAN
IsPeriodicScheduleEnabled (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Whether periodic schedule is enabled

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  TRUE   Enabled
  FALSE  Disabled

--*/
;

BOOLEAN
IsAsyncScheduleEnabled (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Whether asynchronous schedule is enabled

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  TRUE   Enabled
  FALSE  Disabled

--*/
;

BOOLEAN
IsEhcPortEnabled (
  IN  USB2_HC_DEV     *HcDev,
  IN  UINT8           PortNum
  )
/*++

Routine Description:

  Whether port is enabled

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  TRUE   Enabled
  FALSE  Disabled

--*/
;

BOOLEAN
IsEhcReseted (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Whether Ehc is halted

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  TRUE   Reseted
  FALSE  Unreseted

--*/
;

BOOLEAN
IsEhcHalted (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Whether Ehc is halted

Arguments:

  HcDev  - USB2_HC_DEV

Returns:

  TRUE   Halted
  FALSE  Not halted

--*/
;

BOOLEAN
IsEhcSysError (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Whether Ehc is system error

Arguments:

  HcDev  - USB2_HC_DEV

Returns:

  TRUE   System error
  FALSE  No system error

--*/
;

BOOLEAN
IsHighSpeedDevice (
  IN EFI_USB2_HC_PROTOCOL *This,
  IN UINT8                PortNum
  )
/*++

Routine Description:

  Whether high speed device attached

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  TRUE   High speed
  FALSE  Full speed

--*/
;

EFI_STATUS
WaitForEhcReset (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  wait for Ehc reset or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForEhcHalt (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  wait for Ehc halt or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForEhcNotHalt (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  wait for Ehc not halt or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForEhcDoorbell (
  IN  USB2_HC_DEV            *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  Wait for periodic schedule disable or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForAsyncScheduleEnable (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  Wait for Ehc asynchronous schedule enable or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForAsyncScheduleDisable (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  Wait for Ehc asynchronous schedule disable or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForPeriodicScheduleEnable (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  Wait for Ehc periodic schedule enable or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
WaitForPeriodicScheduleDisable (
  IN USB2_HC_DEV             *HcDev,
  IN UINTN                   Timeout
  )
/*++

Routine Description:

  Wait for periodic schedule disable or timeout

Arguments:

  HcDev   - USB2_HC_DEV
  Timeout - timeout threshold

Returns:

  EFI_SUCCESS    Success
  EFI_TIMEOUT    Timeout

--*/
;

EFI_STATUS
GetCapabilityLen (
  IN USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Get the length of capability register

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
SetFrameListBaseAddr (
  IN USB2_HC_DEV     *HcDev,
  IN UINT32          FrameBuffer
  )
/*++

Routine Description:

  Set base address of frame list first entry

Arguments:

  HcDev       - USB2_HC_DEV
  FrameBuffer - base address of first entry of frame list

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
SetAsyncListAddr (
  IN USB2_HC_DEV        *HcDev,
  IN EHCI_QH_ENTITY     *QhPtr
  )
/*++

Routine Description:

  Set address of first Async schedule Qh

Arguments:

  HcDev    - USB2_HC_DEV
  QhPtr    - A pointer to first Qh in the Async schedule

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
SetCtrlDataStructSeg (
  IN USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Set address of first Async schedule Qh

Arguments:

  HcDev    - USB2_HC_DEV
  QhPtr    - A pointer to first Qh in the Async schedule

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
SetPortRoutingEhc (
  IN USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Set Ehc port routing bit

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
EnablePeriodicSchedule (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Enable periodic schedule

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
DisablePeriodicSchedule (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Disable periodic schedule

Arguments:

  HcDev - USB2_HC_DEV

Returns:

  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
EnableAsynchronousSchedule (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Enable asynchrounous schedule

Arguments:

  HcDev - USB2_HC_DEV

Returns:


  EFI_SUCCESS       Success
  EFI_DEVICE_ERROR  Fail

--*/
;

EFI_STATUS
DisableAsynchronousSchedule (
  IN  USB2_HC_DEV     *HcDev
  )
/*++

Routine Description:

  Disable asynchrounous schedule

Arguments:

  HcDev - USB2_HC_DEV

Returns:

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?