pub fn create_subprocess(&self) -> RcProcess {
        let id = Process::next_id();

        assert!(!self.is_dead());

        let process = Process {
            id: id,
            pgid: self.pgid,
            name: self.name.clone(),
            state: State::Loading,
            hw_state: Box::into_raw(new_user_hw_state()),
            mem: self.mem.clone(),
            exit_status: 0,
            exit_wait: WaitQueue::new(),
        };

        debug!("New subprocess: {:?}", process);

        let rc_process = Arc::new(Spinlock::new(process));

        debug!("Process {} pointer {:p}", id, rc_process);

        global_state().lock().process_tree.insert(id, rc_process.clone());

        rc_process
    }
/// Creates a process sharing the same memory space and pgid.
Creates a process sharing the same memory space and pgid.
Creates a process sharing the same memory space and pgid .
pub fn create_subprocess(&self) -> RcProcess {
        let id = Process::next_id();
        assert!(!self.is_dead());
        let process = Process {
            id: id,
            pgid: self.pgid,
            name: self.name.clone(),
            state: State::Loading,
            hw_state: Box::into_raw(new_user_hw_state()),
            mem: self.mem.clone(),
            exit_status: 0,
            exit_wait: WaitQueue::new(),
        };
        debug!("New subprocess: {:?}", process);
        let rc_process = Arc::new(Spinlock::new(process));
        debug!("Process {} pointer {:p}", id, rc_process);
        global_state().lock().process_tree.insert(id, rc_process.clone());
        rc_process
    }
pub fn create_subprocess ( & self ) -> RcProcess { let id = Process :: next_id ( ) ; assert ! ( self is_dead ( ) ) ; let process = Process { id : id , pgid : self . pgid , name : self . name . clone ( ) , state : State :: Loading , hw_state : Box :: into_raw ( new_user_hw_state ( ) ) , mem : self . mem . clone ( ) , exit_status : 0 , exit_wait : WaitQueue :: new ( ) , } ; debug ! ( " " process ) ; let rc_process = Arc :: new ( Spinlock :: new ( process ) ) ; debug ! ( " " id rc_process ) ; global_state ( ) . lock ( ) . process_tree . insert ( id , rc_process . clone ( ) ) ; rc_process }
Creates a process sharing the same memory space and pgid.
Creates a process sharing the same memory space and pgid .
&self