Ignore:
Timestamp:
2012-06-20T16:18:37Z (12 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
8b36bf2, f22dc820
Parents:
abfc9f3
Message:

cleanup thread_create() and thread_t structure

  • remove 'flag' bitfield from thread_t, use individual boolean flags (can be optimized later on by adding : 1)
  • use an enum for call flags, add THREAD_FLAG_NONE
  • remove the 'uncounted' argument in favour of a call flag
  • introduce thread_wire() to setup wired threads
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/udebug/udebug_ops.c

    rabfc9f3 r6eef3c4  
    9595       
    9696        /* Verify that 'thread' is a userspace thread. */
    97         if ((thread->flags & THREAD_FLAG_USPACE) == 0) {
     97        if (!thread->uspace) {
    9898                /* It's not, deny its existence */
    9999                irq_spinlock_unlock(&thread->lock, true);
     
    200200               
    201201                mutex_lock(&thread->udebug.lock);
    202                 if ((thread->flags & THREAD_FLAG_USPACE) != 0) {
     202                if (thread->uspace) {
    203203                        thread->udebug.active = true;
    204204                        mutex_unlock(&thread->udebug.lock);
     
    393393               
    394394                irq_spinlock_lock(&thread->lock, false);
    395                 int flags = thread->flags;
     395                bool uspace = thread->uspace;
    396396                irq_spinlock_unlock(&thread->lock, false);
    397397               
    398398                /* Not interested in kernel threads. */
    399                 if ((flags & THREAD_FLAG_USPACE) == 0)
     399                if (!uspace)
    400400                        continue;
    401401               
Note: See TracChangeset for help on using the changeset viewer.