Changeset a33f0a6 in mainline for uspace/lib/c/include/elf/elf_load.h


Ignore:
Timestamp:
2011-08-03T17:34:57Z (14 years ago)
Author:
Oleg Romanenko <romanenko.oleg@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
1940326
Parents:
52a79081 (diff), 3fab770 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge from mainline

File:
1 moved

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/include/elf/elf_load.h

    r52a79081 ra33f0a6  
    11/*
     2 * Copyright (c) 2006 Sergey Bondari
    23 * Copyright (c) 2008 Jiri Svoboda
    34 * All rights reserved.
     
    3839
    3940#include <arch/elf.h>
     41#include <elf/elf.h>
    4042#include <sys/types.h>
    4143#include <loader/pcb.h>
    4244
    43 #include "elf.h"
     45/**
     46 * ELF error return codes
     47 */
     48#define EE_OK                   0       /* No error */
     49#define EE_INVALID              1       /* Invalid ELF image */
     50#define EE_MEMORY               2       /* Cannot allocate address space */
     51#define EE_INCOMPATIBLE         3       /* ELF image is not compatible with current architecture */
     52#define EE_UNSUPPORTED          4       /* Non-supported ELF (e.g. dynamic ELFs) */
     53#define EE_LOADER               5       /* The image is actually a program loader. */
     54#define EE_IRRECOVERABLE        6
     55
     56typedef enum {
     57        /** Leave all segments in RW access mode. */
     58        ELDF_RW = 1
     59} eld_flags_t;
    4460
    4561/**
     
    6783        uintptr_t bias;
    6884
     85        /** Flags passed to the ELF loader. */
     86        eld_flags_t flags;
     87
    6988        /** A copy of the ELF file header */
    7089        elf_header_t *header;
     
    7493} elf_ld_t;
    7594
    76 int elf_load_file(const char *file_name, size_t so_bias, elf_info_t *info);
    77 void elf_run(elf_info_t *info, pcb_t *pcb);
    78 void elf_create_pcb(elf_info_t *info, pcb_t *pcb);
     95extern const char *elf_error(unsigned int);
     96extern int elf_load_file(const char *, size_t, eld_flags_t, elf_info_t *);
     97extern void elf_create_pcb(elf_info_t *, pcb_t *);
    7998
    8099#endif
Note: See TracChangeset for help on using the changeset viewer.