ddpi_elf_load_cu operation

The ddpi_elf_load_cu operation loads and relocates the ELF object file.

This operation verifies that the ELF object (inside the Ddpi_Elf object) has an MD5 signature that matches the CU that has been loaded into memory. If a match is found, the operation adjusts the relocatable physical addresses of the ELF object to correspond to the physical addresses of the CU that has been loaded into memory.

Prototype

int  ddpi_elf_load_cu(              
     Ddpi_Info           info,    
     Ddpi_Elf            pi_elf,  
     Ddpi_Error*         error); 

Parameters

info
Input. This input parameter accepts the Ddpi_Info processing object.
pi_elf
Input. This accepts the Ddpi_Elf object containing the file-specific ELF object.
error
See The libddpi error parameter.

Return values

DW_DLV_OK
This value is returned upon verification that the ELF object (inside the Ddpi_Elf object) has an MD5 signature that matches the CU that has been loaded in memory.
DW_DLV_ERROR
This value is returned if:
  • pi_elf is NULL
  • pi_elf does not have a valid ELF descriptor
  • The ELF descriptor contains invalid relocation types
  • There is insufficient memory
DW_DLV_NO_ENTRY
This value is returned if the MD5 signature does not match the CU that is loaded in memory.