Serial_io.write() – Intel Extensible Firmware Interface User Manual

Page 358

Advertising
background image

Extensible Firmware Interface Specification

10-64

12/01/02

Version 1.10

SERIAL_IO.Write()

Summary

Writes data to a serial device.

Prototype

EFI_STATUS

(EFIAPI *EFI_SERIAL_WRITE) (

IN

SERIAL_IO_INTERFACE

*This,

IN OUT UINTN

*BufferSize,

IN

VOID

*Buffer

);

Parameters

This

A pointer to the

SERIAL_IO_INTERFACE

instance. Type

SERIAL_IO_INTERFACE

is defined in Section 10.12.

BufferSize

On input, the size of the

Buffer

. On output, the amount of

data actually written.

Buffer

The buffer of data to write.

Description

The

Write()

function writes the specified number of bytes to a serial device. If a time out error

occurs while data is being sent to the serial port, transmission of this buffer will terminate, and

EFI_TIMEOUT

will be returned. In all cases the number of bytes actually written to the serial

device is returned in

BufferSize

.

Status Codes Returned

EFI_SUCCESS

The data was written.

EFI_DEVICE_ERROR

The device reported an error.

EFI_TIMEOUT

The data write was stopped due to a timeout.

Advertising