public
/
FUZIX.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
850fe19
)
process: enable uptime support
author
Alan Cox
<alan@linux.intel.com>
Sun, 24 May 2015 21:45:11 +0000
(22:45 +0100)
committer
Alan Cox
<alan@linux.intel.com>
Sun, 24 May 2015 21:45:11 +0000
(22:45 +0100)
Kernel/process.c
patch
|
blob
|
history
diff --git
a/Kernel/process.c
b/Kernel/process.c
index
f0726f3
..
9721c99
100644
(file)
--- a/
Kernel/process.c
+++ b/
Kernel/process.c
@@
-295,7
+295,7
@@
void load_average(void)
struct runload *r;
static uint8_t utick;
uint8_t i;
- uint
8
_t nr;
+ uint
16
_t nr;
utick++;
if (utick < 50)
@@
-310,7
+310,7
@@
void load_average(void)
while (i++ < 3) {
r->average = ((((r->average - (nr << 8)) * r->exponent) +
- (((u
nsigned long
)nr) << 16)) >> 8);
+ (((u
int32_t
)nr) << 16)) >> 8);
r++;
}
}
@@
-357,6
+357,7
@@
void timer_interrupt(void)
}
}
updatetod();
+ load_average();
#ifdef CONFIG_AUDIO
audio_tick();
#endif