Changeset 101 for trunk/kernel/syscalls


Ignore:
Timestamp:
Jun 29, 2017, 4:44:52 PM (7 years ago)
Author:
alain
Message:

euh...

Location:
trunk/kernel/syscalls
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/syscalls/sys_clock.c

    r23 r101  
    2424#include <hal_types.h>
    2525#include <hal_uspace.h>
     26#include <hal_special.h>
    2627#include <errno.h>
    2728#include <core.h>
     
    5354
    5455    // call relevant core function
    55         k_cycles = core_get_cycles( this->core );
     56        k_cycles = hal_get_cycles();
    5657
    5758    // copy to user space
  • trunk/kernel/syscalls/sys_exec.c

    r53 r101  
    225225                 " / target_cluster = %x / cycle %d\n",
    226226                 __FUNCTION__, process->pid , CURRENT_CORE->lid,
    227                  cxy_client, cxy_server, hal_time_stamp());
    228 
    229     // initialize exec_info structure
    230     exec_info.pid         = process->pid;
    231     exec_info.ppid        = process->ppid;
    232     exec_info.fd_array_xp = XPTR( local_cxy , &process->fd_array );
    233     exec_info.vfs_root_xp = process->vfs_root_xp;
    234     exec_info.vfs_cwd_xp  = process->vfs_cwd_xp;
    235     exec_info.vfs_bin_xp  = process->vfs_bin_xp;
     227                 cxy_client, cxy_server, hal_get_cycles());
     228
     229    // register reference parent process in exec_info
     230    exec_info.parent_xp   = process->ref_xp;
    236231
    237232        // check pathname and store it in exec_info structure
     
    266261       
    267262    exec_dmsg("\n[INFO] %s starts exec for process %x at cycle %d\n",
    268               __FUNCTION__, process->pid, hal_time_stamp() );
     263              __FUNCTION__, process->pid, hal_get_cycles() );
    269264
    270265    if( is_local )  error = process_make_exec( &exec_info );
     
    280275
    281276    exec_dmsg("\n[INFO] %s completes exec for process %x at cycle %d\n",
    282               __FUNCTION__, process->pid , hal_time_stamp() );
     277              __FUNCTION__, process->pid , hal_get_cycles() );
    283278
    284279    // delete the calling thread an process
  • trunk/kernel/syscalls/sys_fork.c

    r23 r101  
    6464
    6565        fork_dmsg("\n[INFO] %s : enters for process %d at cycle [%d]\n",
    66                   __FUNCTION__, parent_process->pid, hal_time_stamp());
     66                  __FUNCTION__, parent_process->pid, hal_get_cycles());
    6767
    6868    // save FPU state in fpu_context if parent process is FPU owner
     
    214214
    215215        fork_dmsg("\n[INFO] %s : completed / parent pid = %x / child pid = %x / at cycle [%d]\n",
    216                   __FUNCTION__, parent_process->pid, child_process->pid, hal_time_stamp() );
     216                  __FUNCTION__, parent_process->pid, child_process->pid, hal_get_cycles() );
    217217
    218218        return child_process->pid;
  • trunk/kernel/syscalls/sys_thread_create.c

    r23 r101  
    6161        uint32_t         tm_end;
    6262
    63         tm_start = hal_time_stamp();
     63        tm_start = hal_get_cycles();
    6464
    6565    // get parent thead pointer, extended pointer, and process pointer
     
    160160        thread_child_parent_link( parent_xp , child_xp );
    161161
    162         tm_end = hal_time_stamp();
     162        tm_end = hal_get_cycles();
    163163
    164164        thread_dmsg("\n[INFO] %s created thread %x for process %x in cluster %x\n"
  • trunk/kernel/syscalls/sys_thread_sleep.c

    r50 r101  
    3131{
    3232    thread_dmsg("\n[INFO] %s : thread %x in process %x goes to sleep at cycle %d\n",
    33                 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_PROCESS->pid, hal_time_stamp() );
     33                __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_PROCESS->pid, hal_get_cycles() );
    3434
    3535    thread_block( CURRENT_THREAD , THREAD_BLOCKED_GLOBAL );
     
    3737
    3838    thread_dmsg("\n[INFO] %s : thread %x in process %x resume at cycle\n",
    39                 __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_PROCESS->pid, hal_time_stamp() );
     39                __FUNCTION__, CURRENT_THREAD->trdid, CURRENT_PROCESS->pid, hal_get_cycles() );
    4040
    4141        return 0;
Note: See TracChangeset for help on using the changeset viewer.