Changes in / [4585bda:fb04cd90] in mainline


Ignore:
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/include/proc/program.h

    r4585bda rfb04cd90  
    5050        struct task *task;           /**< Program task */
    5151        struct thread *main_thread;  /**< Program main thread */
    52         unsigned int loader_status;  /**< Binary loader error status */
    5352} program_t;
    5453
  • kernel/generic/src/lib/rd.c

    r4585bda rfb04cd90  
    3838 */
    3939
    40 #include <print.h>
    4140#include <lib/rd.h>
    4241#include <mm/frame.h>
     
    6766        sysinfo_set_item_val("rd.size", NULL, size);
    6867        sysinfo_set_item_val("rd.address.physical", NULL, (sysarg_t) base);
    69        
    70         printf("RAM disk at %p (size %zu bytes)\n", (void *) base, size);
    7168}
    7269
  • kernel/generic/src/main/kinit.c

    r4585bda rfb04cd90  
    201201                str_cpy(namebuf + INIT_PREFIX_LEN,
    202202                    TASK_NAME_BUFLEN - INIT_PREFIX_LEN, name);
    203                
     203
    204204                /*
    205205                 * Create virtual memory mappings for init task images.
     
    236236                        init_rd((void *) init.tasks[i].paddr, init.tasks[i].size);
    237237                } else
    238                         printf("init[%zu]: Init binary load failed "
    239                             "(error %d, loader status %u)\n", i, rc,
    240                             programs[i].loader_status);
     238                        printf("init[%zu]: Init binary load failed (error %d)\n", i, rc);
    241239        }
    242240       
  • kernel/generic/src/proc/program.c

    r4585bda rfb04cd90  
    8080        kernel_uarg->uspace_uarg = NULL;
    8181       
    82         prg->loader_status = EE_OK;
    8382        prg->task = task_create(as, name);
    8483        if (!prg->task)
     
    112111 * executable image. The task is returned in *task.
    113112 *
    114  * @param[in]  image_addr Address of an executable program image.
    115  * @param[in]  name       Name to set for the program's task.
    116  * @param[out] prg        Buffer for storing program info.
    117  *                        If image_addr points to a loader image,
    118  *                        prg->task will be set to NULL and EOK
    119  *                        will be returned.
     113 * @param image_addr Address of an executable program image.
     114 * @param name       Name to set for the program's task.
     115 * @param prg        Buffer for storing program info. If image_addr
     116 *                   points to a loader image, p->task will be set to
     117 *                   NULL and EOK will be returned.
    120118 *
    121119 * @return EOK on success or negative error code.
     
    128126                return ENOMEM;
    129127       
    130         prg->loader_status = elf_load((elf_header_t *) image_addr, as, 0);
    131         if (prg->loader_status != EE_OK) {
     128        unsigned int rc = elf_load((elf_header_t *) image_addr, as, 0);
     129        if (rc != EE_OK) {
    132130                as_destroy(as);
    133131                prg->task = NULL;
    134132                prg->main_thread = NULL;
    135133               
    136                 if (prg->loader_status != EE_LOADER)
     134                if (rc != EE_LOADER)
    137135                        return ENOTSUP;
    138136               
     
    142140               
    143141                program_loader = image_addr;
    144                 printf("Program loader at %p\n", (void *) image_addr);
     142                LOG("Registered program loader at %p",
     143                    (void *) image_addr);
    145144               
    146145                return EOK;
     
    172171        }
    173172       
    174         prg->loader_status = elf_load((elf_header_t *) program_loader, as,
     173        unsigned int rc = elf_load((elf_header_t *) program_loader, as,
    175174            ELD_F_LOADER);
    176         if (prg->loader_status != EE_OK) {
     175        if (rc != EE_OK) {
    177176                as_destroy(as);
    178                 printf("Cannot spawn loader (%s)\n",
    179                     elf_error(prg->loader_status));
     177                printf("Cannot spawn loader (%s)\n", elf_error(rc));
    180178                return ENOENT;
    181179        }
  • tools/toolchain.sh

    r4585bda rfb04cd90  
    149149        echo " sparc64    SPARC V9"
    150150        echo " all        build all targets"
    151         echo " parallel   same as 'all', but all in parallel"
    152         echo " 2-way      same as 'all', but 2-way parallel"
     151        echo " parallel   same as 'all', but in parallel"
    153152        echo
    154153        echo "The toolchain will be installed to the directory specified by"
     
    432431                wait
    433432                ;;
    434         "2-way")
    435                 prepare
    436                 build_target "amd64" "amd64-linux-gnu" &
    437                 build_target "arm32" "arm-linux-gnueabi" &
    438                 wait
    439                
    440                 build_target "ia32" "i686-pc-linux-gnu" &
    441                 build_target "ia64" "ia64-pc-linux-gnu" &
    442                 wait
    443                
    444                 build_target "mips32" "mipsel-linux-gnu" &
    445                 build_target "mips32eb" "mips-linux-gnu" &
    446                 wait
    447                
    448                 build_target "mips64" "mips64el-linux-gnu" &
    449                 build_target "ppc32" "ppc-linux-gnu" &
    450                 wait
    451                
    452                 build_target "ppc64" "ppc64-linux-gnu" &
    453                 build_target "sparc64" "sparc64-linux-gnu" &
    454                 wait
    455                 ;;
    456433        *)
    457434                show_usage
Note: See TracChangeset for help on using the changeset viewer.