TianoCore EDK2 master
Loading...
Searching...
No Matches
Ram.c File Reference
#include <Uefi/UefiBaseType.h>
#include <Uefi/UefiMultiPhase.h>
#include <Pi/PiBootMode.h>
#include <Pi/PiHob.h>
#include <Library/HobLib.h>
#include <Library/PL011UartLib.h>
#include <Library/PcdLib.h>
#include <Guid/EarlyPL011BaseAddress.h>
#include "Ram.h"
#include "Write.h"

Go to the source code of this file.

Functions

STATIC RETURN_STATUS Initialize (VOID)
 
UINTN DebugLibFdtPL011UartWrite (IN UINT8 *Buffer, IN UINTN NumberOfBytes)
 

Variables

UINTN mDebugLibFdtPL011UartAddress
 
RETURN_STATUS mDebugLibFdtPL011UartPermanentStatus = RETURN_SUCCESS
 

Detailed Description

Define DebugLibFdtPL011UartWrite() for modules that can only run from RAM.

Copyright (C) Red Hat

SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file Ram.c.

Function Documentation

◆ DebugLibFdtPL011UartWrite()

UINTN DebugLibFdtPL011UartWrite ( IN UINT8 *  Buffer,
IN UINTN  NumberOfBytes 
)

(Copied from SerialPortWrite() in "MdePkg/Include/Library/SerialPortLib.h" at commit c4547aefb3d0, with the Buffer non-nullity assertion removed:)

Write data from buffer to serial device.

Writes NumberOfBytes data bytes from Buffer to the serial device. The number of bytes actually written to the serial device is returned. If the return value is less than NumberOfBytes, then the write operation failed. If NumberOfBytes is zero, then return 0.

Parameters
BufferPointer to the data buffer to be written.
NumberOfBytesNumber of bytes to written to the serial device.
Return values
0NumberOfBytes is 0.
>0The number of bytes written to the serial device. If this value is less than NumberOfBytes, then the write operation failed.

Definition at line 111 of file Ram.c.

◆ Initialize()

STATIC RETURN_STATUS Initialize ( VOID  )

Statefully initialize both the library instance and the debug PL011 UART.

Definition at line 29 of file Ram.c.

Variable Documentation

◆ mDebugLibFdtPL011UartAddress

UINTN mDebugLibFdtPL011UartAddress

Definition at line 21 of file Ram.c.

◆ mDebugLibFdtPL011UartPermanentStatus

RETURN_STATUS mDebugLibFdtPL011UartPermanentStatus = RETURN_SUCCESS

Definition at line 22 of file Ram.c.