git://ftp.safe.ca
/
safe
/
jmp
/
linux-2.6
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
timer stats: Optimize by adding quick check to avoid function calls
[safe/jmp/linux-2.6]
/
kernel
/
timer.c
diff --git
a/kernel/timer.c
b/kernel/timer.c
index
54d3912
..
0b36b9e
100644
(file)
--- a/
kernel/timer.c
+++ b/
kernel/timer.c
@@
-380,6
+380,8
@@
static void timer_stats_account_timer(struct timer_list *timer)
{
unsigned int flag = 0;
+ if (likely(!timer->start_site))
+ return;
if (unlikely(tbase_get_deferrable(timer->base)))
flag |= TIMER_STATS_FLAG_DEFERRABLE;