Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/proc/thread.c

    rc0699467 r26aafe8  
    3939#include <proc/thread.h>
    4040#include <proc/task.h>
     41#include <proc/uarg.h>
    4142#include <mm/frame.h>
    4243#include <mm/page.h>
     
    4445#include <arch/cycle.h>
    4546#include <arch.h>
     47#include <synch/synch.h>
    4648#include <synch/spinlock.h>
    4749#include <synch/waitq.h>
     
    5355#include <time/clock.h>
    5456#include <time/timeout.h>
    55 #include <time/delay.h>
    5657#include <config.h>
    5758#include <arch/interrupt.h>
     
    258259         */
    259260       
    260         list_append(&thread->rq_link, &cpu->rq[i].rq);
     261        list_append(&thread->rq_link, &cpu->rq[i].rq_head);
    261262        cpu->rq[i].n++;
    262263        irq_spinlock_unlock(&(cpu->rq[i].lock), true);
     
    320321        thread->cpu = NULL;
    321322        thread->flags = flags;
    322         thread->nomigrate = 0;
    323323        thread->state = Entering;
    324324       
     
    421421                atomic_inc(&task->lifecount);
    422422       
    423         list_append(&thread->th_link, &task->threads);
     423        list_append(&thread->th_link, &task->th_head);
    424424       
    425425        irq_spinlock_pass(&task->lock, &threads_lock);
     
    481481        /* Not reached */
    482482        while (true);
    483 }
    484 
    485 /** Prevent the current thread from being migrated to another processor. */
    486 void thread_migration_disable(void)
    487 {
    488         ASSERT(THREAD);
    489 
    490         THREAD->nomigrate++;
    491 }
    492 
    493 /** Allow the current thread to be migrated to another processor. */
    494 void thread_migration_enable(void)
    495 {
    496         ASSERT(THREAD);
    497         ASSERT(THREAD->nomigrate > 0);
    498 
    499         THREAD->nomigrate--;
    500483}
    501484
     
    929912}
    930913
    931 sysarg_t sys_thread_udelay(uint32_t usec)
    932 {
    933         delay(usec);
    934         return 0;
    935 }
    936 
    937914/** @}
    938915 */
Note: See TracChangeset for help on using the changeset viewer.