Changeset c47e1a8 in mainline for kernel/generic/src/time/clock.c


Ignore:
Timestamp:
2010-05-21T07:50:04Z (16 years ago)
Author:
Lenka Trochtova <trochtova.lenka@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
d51ee2b
Parents:
cf8cc36 (diff), 15b592b (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

merge mainline changes (rev. 451)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/time/clock.c

    rcf8cc36 rc47e1a8  
    8686        uptime->seconds1 = 0;
    8787        uptime->seconds2 = 0;
    88         uptime->useconds = 0; 
     88        uptime->useconds = 0;
    8989
    9090        clock_parea.pbase = (uintptr_t) faddr;
     
    137137        size_t missed_clock_ticks = CPU->missed_clock_ticks;
    138138        unsigned int i;
     139
     140        /* Account lost ticks to CPU usage */
     141        if (CPU->idle) {
     142                CPU->idle_ticks += missed_clock_ticks + 1;
     143        } else {
     144                CPU->busy_ticks += missed_clock_ticks + 1;
     145        }
     146        CPU->idle = false;
    139147
    140148        /*
     
    187195                spinlock_unlock(&THREAD->lock);
    188196               
    189                 if (!ticks && !PREEMPTION_DISABLED) {
     197                if ((!ticks) && (!PREEMPTION_DISABLED)) {
    190198#ifdef CONFIG_UDEBUG
    191199                        istate_t *istate;
Note: See TracChangeset for help on using the changeset viewer.