コード例 #1
0
ファイル: PL011SerialPortExtLib.c プロジェクト: B-Rich/edk2
/**
  Get the serial device control bits.

  @param  Control                 Control signals read from the serial device.

  @retval EFI_SUCCESS             The control bits were read from the serial device.
  @retval EFI_DEVICE_ERROR        The serial device is not functioning correctly.

**/
RETURN_STATUS
EFIAPI
SerialPortGetControl (
  OUT UINT32                  *Control
  )
{
  return PL011UartGetControl ((UINTN)PcdGet64 (PcdSerialRegisterBase), Control);
}
コード例 #2
0
ファイル: FdtPL011SerialPortLib.c プロジェクト: MattDevo/edk2
/**
  Retrieve the status of the control bits on a serial device.

  @param Control                A pointer to return the current control signals from the serial device.

  @retval RETURN_SUCCESS        The control bits were read from the serial device.
  @retval RETURN_UNSUPPORTED    The serial device does not support this operation.
  @retval RETURN_DEVICE_ERROR   The serial device is not functioning correctly.

**/
RETURN_STATUS
EFIAPI
SerialPortGetControl (
  OUT UINT32 *Control
  )
{
  RETURN_STATUS Status;

  if (mSerialBaseAddress == 0) {
    Status = RETURN_UNSUPPORTED;
  } else {
    Status = PL011UartGetControl (mSerialBaseAddress, Control);
  }

  return Status;
}