[profile]: [15/23] h8300 profiling cleanups

From: William Lee Irwin III
Date: Tue Jun 22 2004 - 11:30:37 EST


Convert h8300 to use profiling_on() and profile_tick().

Index: prof-2.6.7/arch/h8300/kernel/time.c
===================================================================
--- prof-2.6.7.orig/arch/h8300/kernel/time.c 2004-06-15 22:19:10.000000000 -0700
+++ prof-2.6.7/arch/h8300/kernel/time.c 2004-06-22 07:25:55.750687776 -0700
@@ -38,20 +38,8 @@

static inline void do_profile (unsigned long pc)
{
- if (prof_buffer && current->pid) {
- extern int _stext;
- pc -= (unsigned long) &_stext;
- pc >>= prof_shift;
- if (pc < prof_len)
- ++prof_buffer[pc];
- else
- /*
- * Don't ignore out-of-bounds PC values silently,
- * put them into the last histogram slot, so if
- * present, they will show up as a sharp peak.
- */
- ++prof_buffer[prof_len-1];
- }
+ if (current->pid)
+ profile_tick(pc);
}

/*
Index: prof-2.6.7/arch/v850/kernel/time.c
===================================================================
--- prof-2.6.7.orig/arch/v850/kernel/time.c 2004-06-15 22:19:37.000000000 -0700
+++ prof-2.6.7/arch/v850/kernel/time.c 2004-06-22 07:25:55.752687472 -0700
@@ -42,20 +42,8 @@

static inline void do_profile (unsigned long pc)
{
- if (prof_buffer && current->pid) {
- extern int _stext;
- pc -= (unsigned long) &_stext;
- pc >>= prof_shift;
- if (pc < prof_len)
- ++prof_buffer[pc];
- else
- /*
- * Don't ignore out-of-bounds PC values silently,
- * put them into the last histogram slot, so if
- * present, they will show up as a sharp peak.
- */
- ++prof_buffer[prof_len-1];
- }
+ if (current->pid)
+ profile_tick(pc);
}

/*
-
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/