Ignore:
Timestamp:
Mar 28, 2018, 2:40:29 PM (6 years ago)
Author:
alain
Message:

Fix various bugs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/kernel/kern/process.c

    r436 r437  
    366366    xptr_t      children_lock_xp;
    367367
     368    pid_t       pid = process->pid;
     369
    368370        assert( (process->th_nr == 0) , __FUNCTION__ ,
    369     "process %x in cluster %x has still active threads", process->pid , local_cxy );
     371    "process %x in cluster %x has still active threads", pid , local_cxy );
    370372
    371373#if CONFIG_DEBUG_PROCESS_DESTROY
     
    373375if( CONFIG_DEBUG_PROCESS_DESTROY )
    374376printk("\n[DBG] %s : thread %x enter to destroy process %x (pid = %x) / cycle %d\n",
    375 __FUNCTION__ , CURRENT_THREAD , process, process->pid , cycle );
     377__FUNCTION__ , CURRENT_THREAD , process, pid , cycle );
     378#endif
     379
     380#if CONFIG_DEBUG_PROCESS_DESTROY
     381if( CONFIG_DEBUG_PROCESS_DESTROY  & 1 )
     382cluster_processes_display( CXY_FROM_PID( pid ) );
    376383#endif
    377384
     
    383390
    384391    // remove process from children_list if process is in owner cluster
    385     if( CXY_FROM_PID( process->pid ) == local_cxy )
     392    if( CXY_FROM_PID( pid ) == local_cxy )
    386393    {
    387394        // get pointers on parent process
     
    400407
    401408    // release the process PID to cluster manager
    402     cluster_pid_release( process->pid );
     409    cluster_pid_release( pid );
    403410
    404411    // FIXME close all open files and update dirty [AG]
     
    419426if( CONFIG_DEBUG_PROCESS_DESTROY )
    420427printk("\n[DBG] %s : thread %x exit / destroyed process %x (pid = %x) / cycle %d\n",
    421 __FUNCTION__ , CURRENT_THREAD , process, process->pid, cycle );
     428__FUNCTION__ , CURRENT_THREAD , process, pid, cycle );
    422429#endif
    423430
Note: See TracChangeset for help on using the changeset viewer.