projects
/
powerpc.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ACPI: video: Add dev argument for backlight_device_register
[powerpc.git]
/
kernel
/
delayacct.c
diff --git
a/kernel/delayacct.c
b/kernel/delayacct.c
index
f05392d
..
36752f1
100644
(file)
--- a/
kernel/delayacct.c
+++ b/
kernel/delayacct.c
@@
-19,15
+19,15
@@
#include <linux/sysctl.h>
#include <linux/delayacct.h>
#include <linux/sysctl.h>
#include <linux/delayacct.h>
-int delayacct_on __read_mostly
;
/* Delay accounting turned on/off */
+int delayacct_on __read_mostly
= 1;
/* Delay accounting turned on/off */
kmem_cache_t *delayacct_cache;
kmem_cache_t *delayacct_cache;
-static int __init delayacct_setup_
en
able(char *str)
+static int __init delayacct_setup_
dis
able(char *str)
{
{
- delayacct_on =
1
;
+ delayacct_on =
0
;
return 1;
}
return 1;
}
-__setup("
delayacct", delayacct_setup_en
able);
+__setup("
nodelayacct", delayacct_setup_dis
able);
void delayacct_init(void)
{
void delayacct_init(void)
{
@@
-41,24
+41,11
@@
void delayacct_init(void)
void __delayacct_tsk_init(struct task_struct *tsk)
{
void __delayacct_tsk_init(struct task_struct *tsk)
{
- spin_lock_init(&tsk->delays_lock);
- /* No need to acquire tsk->delays_lock for allocation here unless
- __delayacct_tsk_init called after tsk is attached to tasklist
- */
tsk->delays = kmem_cache_zalloc(delayacct_cache, SLAB_KERNEL);
if (tsk->delays)
spin_lock_init(&tsk->delays->lock);
}
tsk->delays = kmem_cache_zalloc(delayacct_cache, SLAB_KERNEL);
if (tsk->delays)
spin_lock_init(&tsk->delays->lock);
}
-void __delayacct_tsk_exit(struct task_struct *tsk)
-{
- struct task_delay_info *delays = tsk->delays;
- spin_lock(&tsk->delays_lock);
- tsk->delays = NULL;
- spin_unlock(&tsk->delays_lock);
- kmem_cache_free(delayacct_cache, delays);
-}
-
/*
* Start accounting for a delay statistic using
* its starting timestamp (@start)
/*
* Start accounting for a delay statistic using
* its starting timestamp (@start)
@@
-118,8
+105,6
@@
int __delayacct_add_tsk(struct taskstats *d, struct task_struct *tsk)
struct timespec ts;
unsigned long t1,t2,t3;
struct timespec ts;
unsigned long t1,t2,t3;
- spin_lock(&tsk->delays_lock);
-
/* Though tsk->delays accessed later, early exit avoids
* unnecessary returning of other data
*/
/* Though tsk->delays accessed later, early exit avoids
* unnecessary returning of other data
*/
@@
-161,7
+146,6
@@
int __delayacct_add_tsk(struct taskstats *d, struct task_struct *tsk)
spin_unlock(&tsk->delays->lock);
done:
spin_unlock(&tsk->delays->lock);
done:
- spin_unlock(&tsk->delays_lock);
return 0;
}
return 0;
}