10#ifndef __BASE_PECOFF_LIB_INTERNALS__
11#define __BASE_PECOFF_LIB_INTERNALS__
23#define RV_X(x, s, n) (((x) >> (s)) & ((1<<(n))-1))
24#define RISCV_IMM_BITS 12
25#define RISCV_IMM_REACH (1LL<<RISCV_IMM_BITS)
26#define RISCV_CONST_HIGH_PART(VALUE) \
27 (((VALUE) + (RISCV_IMM_REACH/2)) & ~(RISCV_IMM_REACH-1))
45 IN OUT CHAR8 **FixupData,
66 IN OUT CHAR8 **FixupData,
UINT16 PeCoffLoaderGetPeHeaderMagicValue(IN EFI_IMAGE_OPTIONAL_HEADER_PTR_UNION Hdr)
VOID * PeCoffLoaderImageAddress(IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext, IN UINTN Address, IN UINTN TeStrippedOffset)
RETURN_STATUS PeCoffLoaderGetPeHeader(IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext, OUT EFI_IMAGE_OPTIONAL_HEADER_PTR_UNION Hdr)
RETURN_STATUS PeHotRelocateImageEx(IN UINT16 *Reloc, IN OUT CHAR8 *Fixup, IN OUT CHAR8 **FixupData, IN UINT64 Adjust)
RETURN_STATUS PeCoffLoaderRelocateImageEx(IN UINT16 *Reloc, IN OUT CHAR8 *Fixup, IN OUT CHAR8 **FixupData, IN UINT64 Adjust)
BOOLEAN PeCoffLoaderImageFormatSupported(IN UINT16 Machine)