22.4.3 SetControl() and GetControl() Implementation

GetControl() and SetControl() are used to view and modify respectively the control bits on the serial device. All of the values listed in the following table can be read back with GetControl(), but some cannot be modified with SetControl(). If a non-modifiable bit is attempted to be set with SetControl() then EFI_UNSUPPORTED must be returned.

The Mode pointer should be updated in this function when success has been determined, but not modified if there is an error.

Table 35-Serial I/O protocol control bits

Control Bit #define

Modifiable with SetControl()

EFI_SERIAL_CLEAR_TO_SEND

NO

EFI_SERIAL_DATA_SET_READY

NO

EFI_SERIAL_RING_INDICATE

NO

EFI_SERIAL_CARRIER_DETECT

NO

EFI_SERIAL_REQUEST_TO_SEND

YES

EFI_SERIAL_DATA_TERMINAL_READY

YES

EFI_SERIAL_INPUT_BUFFER_EMPTY

NO

EFI_SERIAL_OUTPUT_BUFFER_EMPTY

NO

EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE

YES

EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE

YES

EFI_SERIAL_HARDWARE_FLOW_CONTROL_ENABLE

YES