[RFC PATCH 5/6] hrtimer: record more real start_site for timer_stats

From: Yong Zhang
Date: Sun Aug 29 2010 - 11:06:51 EST


From: Yong Zhang <yong.zhang@xxxxxxxxxxxxx>

Most call sites are showed as hrtimer_start_range_ns(). This gives us
not enough info about the start_site. Then call
timer_stats_hrtimer_set_start_info() in hrtimer_start*() to
record the upper caller.

Signed-off-by: Yong Zhang <yong.zhang0@xxxxxxxxx>
Cc: Thomas Gleixner <tglx@xxxxxxxxxxxxx>
Cc: Ingo Molnar <mingo@xxxxxxx>
Cc: Peter Zijlstra <a.p.zijlstra@xxxxxxxxx>
---
kernel/hrtimer.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/kernel/hrtimer.c b/kernel/hrtimer.c
index 2b79ab4..1820a83 100644
--- a/kernel/hrtimer.c
+++ b/kernel/hrtimer.c
@@ -1014,6 +1014,7 @@ int __hrtimer_start_range_ns(struct hrtimer *timer, ktime_t tim,
int hrtimer_start_range_ns(struct hrtimer *timer, ktime_t tim,
unsigned long delta_ns, const enum hrtimer_mode mode)
{
+ timer_stats_hrtimer_set_start_info(timer);
return __hrtimer_start_range_ns(timer, tim, delta_ns, mode, 1);
}
EXPORT_SYMBOL_GPL(hrtimer_start_range_ns);
@@ -1031,6 +1032,7 @@ EXPORT_SYMBOL_GPL(hrtimer_start_range_ns);
int
hrtimer_start(struct hrtimer *timer, ktime_t tim, const enum hrtimer_mode mode)
{
+ timer_stats_hrtimer_set_start_info(timer);
return __hrtimer_start_range_ns(timer, tim, 0, mode, 1);
}
EXPORT_SYMBOL_GPL(hrtimer_start);
--
1.7.0.4

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/