Changeset 4470e26 in mainline for uspace/lib/libc/generic/loader.c


Ignore:
Timestamp:
2008-09-24T10:57:21Z (17 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
0993087
Parents:
45454e9b
Message:

Separate load and run commands for loader. Update tracer - no events get missed on startup anymore.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/libc/generic/loader.c

    r45454e9b r4470e26  
    206206}
    207207
     208/** Instruct loader to load the program.
     209 *
     210 * If this function succeeds, the program has been successfully loaded
     211 * and is ready to be executed.
     212 *
     213 * @param ldr           Loader connection structure.
     214 * @return              Zero on success or negative error code.
     215 */
     216int loader_load_program(loader_t *ldr)
     217{
     218        int rc;
     219
     220        rc = async_req_0_0(ldr->phone_id, LOADER_LOAD);
     221        if (rc != EOK)
     222                return rc;
     223
     224        return EOK;
     225}
     226
    208227/** Instruct loader to execute the program.
     228 *
     229 * Note that this function blocks until the loader actually replies
     230 * so you cannot expect this function to return if you are debugging
     231 * the task and its thread is stopped.
    209232 *
    210233 * After using this function, no further operations must be performed
     
    214237 * @return              Zero on success or negative error code.
    215238 */
    216 int loader_start_program(loader_t *ldr)
     239int loader_run(loader_t *ldr)
    217240{
    218241        int rc;
     
    222245                return rc;
    223246
    224         ipc_hangup(ldr->phone_id);
    225247        return EOK;
    226248}
Note: See TracChangeset for help on using the changeset viewer.