Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-11 Thread Martin Peschke
Peter Zijlstra wrote: On Wed, 2007-06-06 at 23:34 +0200, Martin Peschke wrote: +#ifdef CONFIG_LOCK_STAT +enum lock_stat_enum { + LOCK_STAT_CONT, + LOCK_STAT_WAIT_READ, + LOCK_STAT_WAIT_WRITE, + LOCK_STAT_HOLD_READ, + LOCK_STAT_HOLD_WRITE, + _LOCK_STAT_NUMBER

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-11 Thread Martin Peschke
Bill Huey (hui) wrote: > However, I don't understand why all of this > is so heavy weight when the current measurements that Peter makes is > completely sufficient for any reasonable purpose I can think of at the > moment. It wasn't meant to be or to stay heavy weight. To make the best of my

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-11 Thread Martin Peschke
Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:37 +0200, Martin Peschke wrote: Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:18 +0200, Martin Peschke wrote: Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:00 +0200, Martin Peschke wrote: Peter Zijlstra wrote: I'm confused as to where

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-11 Thread Martin Peschke
Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:37 +0200, Martin Peschke wrote: Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:18 +0200, Martin Peschke wrote: Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:00 +0200, Martin Peschke wrote: Peter Zijlstra wrote: I'm confused as to where

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-11 Thread Martin Peschke
Bill Huey (hui) wrote: However, I don't understand why all of this is so heavy weight when the current measurements that Peter makes is completely sufficient for any reasonable purpose I can think of at the moment. It wasn't meant to be or to stay heavy weight. To make the best of my recent

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-11 Thread Martin Peschke
Peter Zijlstra wrote: On Wed, 2007-06-06 at 23:34 +0200, Martin Peschke wrote: +#ifdef CONFIG_LOCK_STAT +enum lock_stat_enum { + LOCK_STAT_CONT, + LOCK_STAT_WAIT_READ, + LOCK_STAT_WAIT_WRITE, + LOCK_STAT_HOLD_READ, + LOCK_STAT_HOLD_WRITE, + _LOCK_STAT_NUMBER

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:18 +0200, Martin Peschke wrote: Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:00 +0200, Martin Peschke wrote: Peter Zijlstra wrote: I'm confused as to where the class->stat objects are initialised? Is that done in lock_stat_init()? If

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Peter Zijlstra wrote: On Wed, 2007-06-06 at 23:34 +0200, Martin Peschke wrote: +struct statistic_info lock_stat_info[_LOCK_STAT_NUMBER] = { + [LOCK_STAT_CONT] = { + .name = "contentions", + .x_unit = "instruction_pointer", +

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Peter Zijlstra wrote: I'm confused as to where the class->stat objects are initialised? Is that done in lock_stat_init()? If so, then you have a bug. static struct lock_class lock_classes[MAX_LOCKDEP_KEYS]; I assume this gets us class structures containing all zeros, doesn't it? Then

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Ingo Molnar wrote: > Firstly, submit cleanup patches that _do not change the output_. If you > have any output changes, do it as a separate patch, ontop of the cleanup > patch. Mixing material changes and cleanups into a single patch is a > basic patch submission mistake that will only earn you

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Ingo Molnar wrote: if the infrastructure your are advocating does not allow us to keep the existing output then it's simply not flexible enough. Let's be precise. If "keep the existing output" means any format change is unacceptible to you, then I broke things. If it means that my method

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Ingo Molnar wrote: if the infrastructure your are advocating does not allow us to keep the existing output then it's simply not flexible enough. Let's be precise. If keep the existing output means any format change is unacceptible to you, then I broke things. If it means that my method

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Ingo Molnar wrote: Firstly, submit cleanup patches that _do not change the output_. If you have any output changes, do it as a separate patch, ontop of the cleanup patch. Mixing material changes and cleanups into a single patch is a basic patch submission mistake that will only earn you

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Peter Zijlstra wrote: On Wed, 2007-06-06 at 23:34 +0200, Martin Peschke wrote: +struct statistic_info lock_stat_info[_LOCK_STAT_NUMBER] = { + [LOCK_STAT_CONT] = { + .name = contentions, + .x_unit = instruction_pointer, + .y_unit

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Peter Zijlstra wrote: I'm confused as to where the class-stat objects are initialised? Is that done in lock_stat_init()? If so, then you have a bug. static struct lock_class lock_classes[MAX_LOCKDEP_KEYS]; I assume this gets us class structures containing all zeros, doesn't it? Then

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-08 Thread Martin Peschke
Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:18 +0200, Martin Peschke wrote: Peter Zijlstra wrote: On Fri, 2007-06-08 at 19:00 +0200, Martin Peschke wrote: Peter Zijlstra wrote: I'm confused as to where the class-stat objects are initialised? Is that done in lock_stat_init()? If so

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-07 Thread Martin Peschke
Bill Huey (hui) wrote: > There are roughly about 400 locks in a normal kernel for a desktop. The > list is rather cumbersome anyways so, IMO, it really should be handled > by parsing tools, etc... There could be more properties attached to each > lock especially if you intend to get this to work

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-07 Thread Martin Peschke
Peter Zijlstra wrote: On Thu, 2007-06-07 at 02:17 +0200, Martin Peschke wrote: Ingo Molnar wrote: * Martin Peschke <[EMAIL PROTECTED]> wrote: The output has changed from a terribly wide table to an enormously long list (just the generic way the statistics code prints data). Sigh, wh

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-07 Thread Martin Peschke
Peter Zijlstra wrote: On Thu, 2007-06-07 at 02:17 +0200, Martin Peschke wrote: Ingo Molnar wrote: * Martin Peschke [EMAIL PROTECTED] wrote: The output has changed from a terribly wide table to an enormously long list (just the generic way the statistics code prints data). Sigh, why dont

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-07 Thread Martin Peschke
Bill Huey (hui) wrote: There are roughly about 400 locks in a normal kernel for a desktop. The list is rather cumbersome anyways so, IMO, it really should be handled by parsing tools, etc... There could be more properties attached to each lock especially if you intend to get this to work on

Re: [RFC] [Patch 1/4] statistics: no include hell for users

2007-06-06 Thread Martin Peschke
Dave Hansen wrote: On Wed, 2007-06-06 at 23:33 +0200, Martin Peschke wrote: struct statistic_interface { /* private: */ struct list_head list; - struct dentry *debugfs_dir; - struct dentry *data_file; - struct dentry *def_file

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
Ingo Molnar wrote: * Martin Peschke <[EMAIL PROTECTED]> wrote: - lock_time_inc() vs. statistic_add_util() please fix the coding style in lib/statistic.c. It's full of: { unsigned long long i; if (value <= stat->u.histogram.range_min) return 0; p

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
Ingo Molnar wrote: * Martin Peschke <[EMAIL PROTECTED]> wrote: The output has changed from a terribly wide table to an enormously long list (just the generic way the statistics code prints data). Sigh, why dont you _ask_ before doing such stuff? A nice diffstat is always worth

[RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
nimum 0 clocksource_lock hold_read average 0.000 clocksource_lock hold_read maximum 0 clocksource_lock hold_read variance 0.000 clocksource_lock hold_write samples 308908 clocksource_lock hold_write minimum 188 clocksource_lock hold_write average 435.165 clocksource_lock hold_write maximum 2485654

[RFC] [Patch 3/4] statistics: sets of statistics in single file

2007-06-06 Thread Martin Peschke
another_statistic average 0.000 my_entity_2 another_statistic maximum 0 my_entity_2 another_statistic variance 0.000 Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- include/linux/statistic.h | 47 lib/statistic.c | 444 -- 2

[RFC] [Patch 1/4] statistics: no include hell for users

2007-06-06 Thread Martin Peschke
rid of seq_file as parameter to the label-function. Now we just pass a buffer to the label-function. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- include/linux/statistic.h | 11 --- lib/statistic.c | 23 +++ 2 files changed, 23 insertions(

[RFC] [Patch 2/4] statistics: cleanups

2007-06-06 Thread Martin Peschke
Statistics code cleanups. Would not have been needed for the following changes - just done along the way. - make function void - found more handy names for a few identifiers Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- drivers/s390/scsi/zfcp_def.h |4 include/linux/stati

[RFC] [Patch 0/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
library functions have been dropped, because a couple more users would be nice.) Ah, and you might need to add CONFIG_STATISTICS to Kconfig of the architecture of your choice (see s390). Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> - To unsubscribe from this list: send the line "

[RFC] [Patch 0/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
library functions have been dropped, because a couple more users would be nice.) Ah, and you might need to add CONFIG_STATISTICS to Kconfig of the architecture of your choice (see s390). Signed-off-by: Martin Peschke [EMAIL PROTECTED] - To unsubscribe from this list: send the line unsubscribe linux

[RFC] [Patch 1/4] statistics: no include hell for users

2007-06-06 Thread Martin Peschke
rid of seq_file as parameter to the label-function. Now we just pass a buffer to the label-function. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/statistic.h | 11 --- lib/statistic.c | 23 +++ 2 files changed, 23 insertions(+), 11

[RFC] [Patch 2/4] statistics: cleanups

2007-06-06 Thread Martin Peschke
Statistics code cleanups. Would not have been needed for the following changes - just done along the way. - make function void - found more handy names for a few identifiers Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- drivers/s390/scsi/zfcp_def.h |4 include/linux/statistic.h

[RFC] [Patch 3/4] statistics: sets of statistics in single file

2007-06-06 Thread Martin Peschke
another_statistic average 0.000 my_entity_2 another_statistic maximum 0 my_entity_2 another_statistic variance 0.000 Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/statistic.h | 47 lib/statistic.c | 444 -- 2 files

[RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
variance 86184020.322 snip Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/lockdep.h | 35 ++--- kernel/lockdep.c| 122 ++- kernel/lockdep_proc.c | 294 +++- 3 files changed, 76 insertions(+), 375

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
Ingo Molnar wrote: * Martin Peschke [EMAIL PROTECTED] wrote: The output has changed from a terribly wide table to an enormously long list (just the generic way the statistics code prints data). Sigh, why dont you _ask_ before doing such stuff? A nice diffstat is always worth a try, isn't

Re: [RFC] [Patch 4/4] lock contention tracking slimmed down

2007-06-06 Thread Martin Peschke
Ingo Molnar wrote: * Martin Peschke [EMAIL PROTECTED] wrote: - lock_time_inc() vs. statistic_add_util() please fix the coding style in lib/statistic.c. It's full of: { unsigned long long i; if (value = stat-u.histogram.range_min) return 0; put a newline

Re: [RFC] [Patch 1/4] statistics: no include hell for users

2007-06-06 Thread Martin Peschke
Dave Hansen wrote: On Wed, 2007-06-06 at 23:33 +0200, Martin Peschke wrote: struct statistic_interface { /* private: */ struct list_head list; - struct dentry *debugfs_dir; - struct dentry *data_file; - struct dentry *def_file

Re: 2.6.22-rc3-mm1: __attribute__((weak)) considered harmful

2007-06-04 Thread Martin Peschke
Andrew Morton wrote: On Sat, 2 Jun 2007 19:14:25 +0200 Adrian Bunk <[EMAIL PROTECTED]> wrote: statistics-infrastructure-make-printk_clock-a-generic-kernel-wide-nsec-resolution.patch shows why __attribute__((weak)) is harmful because you don't see if a required non-weak implemtation is

Re: 2.6.22-rc3-mm1: __attribute__((weak)) considered harmful

2007-06-04 Thread Martin Peschke
Andrew Morton wrote: On Sat, 2 Jun 2007 19:14:25 +0200 Adrian Bunk [EMAIL PROTECTED] wrote: statistics-infrastructure-make-printk_clock-a-generic-kernel-wide-nsec-resolution.patch shows why __attribute__((weak)) is harmful because you don't see if a required non-weak implemtation is missing:

Re: + timer_stats-slimmed-down-using-statistics-infrastucture.patch added to -mm tree

2007-05-15 Thread Martin Peschke
Arjan van de Ven wrote: On Mon, 2007-05-14 at 10:26 +0200, Martin Peschke wrote: [EMAIL PROTECTED] timer_stats]# cat data this patch changes the userspace API though, and breaks PowerTOP :( Though I think it was unfortunate to add the "old" proc API in 2.6.21. timer_stats is clear

Re: 2.6.21-mm2 - CONFIG_STATISTIC and Intel PowerTOP...

2007-05-15 Thread Martin Peschke
[EMAIL PROTECTED] wrote: On Wed, 09 May 2007 01:23:22 PDT, Andrew Morton said: ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.21/2.6.21-mm2/ So I'm trying to get the Intel PowerTop stuff working, and discovered that / proc/timer_stats and/or /proc/tstats has moved to /debug

Re: 2.6.21-mm2 - CONFIG_STATISTIC and Intel PowerTOP...

2007-05-15 Thread Martin Peschke
[EMAIL PROTECTED] wrote: On Wed, 09 May 2007 01:23:22 PDT, Andrew Morton said: ftp://ftp.kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.21/2.6.21-mm2/ So I'm trying to get the Intel PowerTop stuff working, and discovered that / proc/timer_stats and/or /proc/tstats has moved to /debug

Re: + timer_stats-slimmed-down-using-statistics-infrastucture.patch added to -mm tree

2007-05-15 Thread Martin Peschke
Arjan van de Ven wrote: On Mon, 2007-05-14 at 10:26 +0200, Martin Peschke wrote: [EMAIL PROTECTED] timer_stats]# cat data this patch changes the userspace API though, and breaks PowerTOP :( Though I think it was unfortunate to add the old proc API in 2.6.21. timer_stats is clearly labeled

Re: + timer_stats-slimmed-down-using-statistics-infrastucture.patch added to -mm tree

2007-05-14 Thread Martin Peschke
to use Documentation/SubmitChecklist when testing your code *** See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this -- Subject: timer_stats slimmed down: using statistics infrastucture From: Martin

Re: + timer_stats-slimmed-down-using-statistics-infrastucture.patch added to -mm tree

2007-05-14 Thread Martin Peschke
to use Documentation/SubmitChecklist when testing your code *** See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this -- Subject: timer_stats slimmed down: using statistics infrastucture From: Martin

Re: [RFC] [Patch 3/3] readahead statistics slimmed down

2007-05-07 Thread Martin Peschke
Fengguang Wu wrote: 2007/5/3, Martin Peschke <[EMAIL PROTECTED]>: This patch implements the bulk of the existing the adaptive readahead statistics with lib/statistics.c. The output format differs somewhat as the the statistics code just emits lists of items and doesn't do

Re: [RFC] [Patch 3/3] readahead statistics slimmed down

2007-05-07 Thread Martin Peschke
Fengguang Wu wrote: 2007/5/3, Martin Peschke [EMAIL PROTECTED]: This patch implements the bulk of the existing the adaptive readahead statistics with lib/statistics.c. The output format differs somewhat as the the statistics code just emits lists of items and doesn't do tables. It is feasible

[RFC] [Patch 1/3] readahead statistics slimmed down, statistics prereq

2007-05-03 Thread Martin Peschke
looks like: Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- include/linux/statistic.h | 16 +++--- lib/statistic.c | 72 +- 2 files changed, 38 insertions(+), 50 deletions(-) Index: linux/include/linux/stati

[RFC] [Patch 2/3] readahead statistics slimmed down, adapt zfcp

2007-05-03 Thread Martin Peschke
This patch adapts zfcp to the counter changes in lib/statistics.c. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- zfcp_ccw.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Index: linux/drivers/s390/scsi/zfcp

[RFC] [Patch 3/3] readahead statistics slimmed down

2007-05-03 Thread Martin Peschke
0 Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- readahead.c | 170 1 file changed, 34 insertions(+), 136 deletions(-) Index: linux/mm/reada

[RFC] [Patch 0/3] readahead statistics slimmed down

2007-05-03 Thread Martin Peschke
zfcp [RFC] [Patch 3/3] readahead statistics slimmed down Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/maj

[RFC] [Patch 0/3] readahead statistics slimmed down

2007-05-03 Thread Martin Peschke
zfcp [RFC] [Patch 3/3] readahead statistics slimmed down Signed-off-by: Martin Peschke [EMAIL PROTECTED] - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please

[RFC] [Patch 1/3] readahead statistics slimmed down, statistics prereq

2007-05-03 Thread Martin Peschke
looks like: statistic name samples total Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/statistic.h | 16 +++--- lib/statistic.c | 72 +- 2 files changed, 38 insertions(+), 50 deletions(-) Index: linux/include

[RFC] [Patch 2/3] readahead statistics slimmed down, adapt zfcp

2007-05-03 Thread Martin Peschke
This patch adapts zfcp to the counter changes in lib/statistics.c. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- zfcp_ccw.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Index: linux/drivers/s390/scsi/zfcp_ccw.c

[RFC] [Patch 3/3] readahead statistics slimmed down

2007-05-03 Thread Martin Peschke
0 Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- readahead.c | 170 1 file changed, 34 insertions(+), 136 deletions(-) Index: linux/mm/readahead.c

[RFC] [Patch 4/4] timer_stats slimmed down: using statistics infrastucture

2007-04-14 Thread Martin Peschke
ype=sparse entries=1024 data=[6920660.417313] started=[6920660.417313] stopped=[0.00] Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- time/timer_stats.c | 385 - timer.c|2 2 files changed, 59 insertion

[RFC] [Patch 3/4] timer_stats slimmed down: statistics prereq, keys

2007-04-14 Thread Martin Peschke
can label entries using their interpretation of a key. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- include/linux/statistic.h | 132 ++- lib/statistic.c | 191 +++--- 2 files changed, 272 insertions(

[RFC] [Patch 0/4] timer_stats slimmed down

2007-04-14 Thread Martin Peschke
: statistics prereq, labels [Patch 3/4] timer_stats slimmed down: statistics prereq, keys [Patch 4/4] timer_stats slimmed down: using statistics infrastucture Patch set is against 2.6.21-rc6-mm1 and additionaly requires "[Patch] statistics: fix sorted list" posted this morning. Signed-off-

[RFC] [Patch 1/4] timer_stats slimmed down: statistics prereq, cleanup

2007-04-14 Thread Martin Peschke
Small cleanup Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- include/linux/statistic.h |6 +++--- lib/statistic.c |2 +- 2 files changed, 4 insertions(+), 4 deletions(-) Index: linux/include/linux/stati

[RFC] [Patch 2/4] timer_stats slimmed down: statistics prereq, labels

2007-04-14 Thread Martin Peschke
This patch allows clients of the statistics infrastructure to be called back when an entry of a statistic is printed and if the client might want to add some kind of label to the output string. A line would look like this then: Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- i

[Patch] statistics: fix sorted list

2007-04-14 Thread Martin Peschke
a performance loss. Fix is to sort the list by hits after entry insertion, i.e. moving entries added at the tail up the chain, which should not be required very often (usually just when merging per-cpu lists). Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke <[EMAIL PROTEC

[Patch] statistics: fix sorted list

2007-04-14 Thread Martin Peschke
a performance loss. Fix is to sort the list by hits after entry insertion, i.e. moving entries added at the tail up the chain, which should not be required very often (usually just when merging per-cpu lists). Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke [EMAIL PROTECTED

[RFC] [Patch 0/4] timer_stats slimmed down

2007-04-14 Thread Martin Peschke
: statistics prereq, labels [Patch 3/4] timer_stats slimmed down: statistics prereq, keys [Patch 4/4] timer_stats slimmed down: using statistics infrastucture Patch set is against 2.6.21-rc6-mm1 and additionaly requires [Patch] statistics: fix sorted list posted this morning. Signed-off-by: Martin

[RFC] [Patch 1/4] timer_stats slimmed down: statistics prereq, cleanup

2007-04-14 Thread Martin Peschke
Small cleanup Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/statistic.h |6 +++--- lib/statistic.c |2 +- 2 files changed, 4 insertions(+), 4 deletions(-) Index: linux/include/linux/statistic.h

[RFC] [Patch 2/4] timer_stats slimmed down: statistics prereq, labels

2007-04-14 Thread Martin Peschke
This patch allows clients of the statistics infrastructure to be called back when an entry of a statistic is printed and if the client might want to add some kind of label to the output string. A line would look like this then: statistic name basket hits label Signed-off-by: Martin Peschke

[RFC] [Patch 3/4] timer_stats slimmed down: statistics prereq, keys

2007-04-14 Thread Martin Peschke
using their interpretation of a key. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/statistic.h | 132 ++- lib/statistic.c | 191 +++--- 2 files changed, 272 insertions(+), 51 deletions(-) Index

[RFC] [Patch 4/4] timer_stats slimmed down: using statistics infrastucture

2007-04-14 Thread Martin Peschke
/definition name=expired state=on units=timer/occurrence type=sparse entries=1024 data=[6920660.417313] started=[6920660.417313] stopped=[0.00] Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- time/timer_stats.c | 385 - timer.c

[Patch] cleanup: use seq_release_private() where appropriate

2007-04-10 Thread Martin Peschke
We can save some lines of code by using seq_release_private(). Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- drivers/md/md.c | 11 +-- fs/proc/proc_misc.c |9 + kernel/kallsyms.c |9 + net/sunrpc/cache.c

[Patch] statistics: fix cpu hot unplug related memory leak

2007-04-10 Thread Martin Peschke
In case of CPU hotunplug statistics might have leaked some memory (lists of struct statistic_entry_sparse, about 32 byte each, freed by statistic_sparse_reset()). Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- statistic.c |1 + 1 file chan

[Patch] statistics: small cleanup in debugfs write function

2007-04-10 Thread Martin Peschke
-by: Martin Peschke <[EMAIL PROTECTED]> --- statistic.c |6 -- 1 file changed, 4 insertions(+), 2 deletions(-) Index: linux/lib/statistic.c === --- linux.orig/lib/statistic.c +++ linux/lib/statistic.c @@ -631,11 +631,13 @@

[Patch] statistics: fix string termination

2007-04-10 Thread Martin Peschke
Make sure strsep() in statistic_release_def() finds a terminanal '\0' and doesn't attempt to access bytes outside the given buffer. (Patch fixes statistics-infrastructure-simplify-statistics-debugfs-write-function.patch) Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke <[EM

[Patch] statistics: simplify statistics' debugfs read functions

2007-04-10 Thread Martin Peschke
This patch replaces some ugly code implementing debugfs files. The cleaned up code uses seq_file. File contents remains unchanged. Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- statistic.c

[Patch] statistics: simplify statistics' debugfs read functions

2007-04-10 Thread Martin Peschke
This patch replaces some ugly code implementing debugfs files. The cleaned up code uses seq_file. File contents remains unchanged. Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- statistic.c | 588

[Patch] statistics: fix string termination

2007-04-10 Thread Martin Peschke
Make sure strsep() in statistic_release_def() finds a terminanal '\0' and doesn't attempt to access bytes outside the given buffer. (Patch fixes statistics-infrastructure-simplify-statistics-debugfs-write-function.patch) Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke [EMAIL

[Patch] statistics: small cleanup in debugfs write function

2007-04-10 Thread Martin Peschke
-by: Martin Peschke [EMAIL PROTECTED] --- statistic.c |6 -- 1 file changed, 4 insertions(+), 2 deletions(-) Index: linux/lib/statistic.c === --- linux.orig/lib/statistic.c +++ linux/lib/statistic.c @@ -631,11 +631,13 @@ static

[Patch] statistics: fix cpu hot unplug related memory leak

2007-04-10 Thread Martin Peschke
In case of CPU hotunplug statistics might have leaked some memory (lists of struct statistic_entry_sparse, about 32 byte each, freed by statistic_sparse_reset()). Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- statistic.c |1 + 1 file changed, 1

[Patch] cleanup: use seq_release_private() where appropriate

2007-04-10 Thread Martin Peschke
We can save some lines of code by using seq_release_private(). Patch is against 2.6.21-rc6-mm1. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- drivers/md/md.c | 11 +-- fs/proc/proc_misc.c |9 + kernel/kallsyms.c |9 + net/sunrpc/cache.c | 10

[Patch] simplify statistics' debugfs write function

2007-03-16 Thread Martin Peschke
752] [] system_call+0x7e/0x83 Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- statistic.c | 111 ++-- 1 file changed, 26 insertions(+), 85 deletions(-) Index: linux/lib/st

[Patch] simplify statistics' debugfs write function

2007-03-16 Thread Martin Peschke
[ 694.295253] [81025ca3] filp_close+0x73/0x90 [ 694.295498] [8104baf8] sys_dup2+0x148/0x190 [ 694.295752] [8106411e] system_call+0x7e/0x83 Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- statistic.c | 111 ++-- 1

[Patch] fix parsing of statistics type-attribute

2007-03-06 Thread Martin Peschke
Without this fix the the statistics user interface accepted, for example: echo name=my_stats type=utilisa > definition while it should only accept: echo name=my_stats type=utilisation > definition Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- statis

[Patch 2/2] add for_each_substring() and match_substring() - exploitation

2007-03-06 Thread Martin Peschke
simplifying statistics code by using for_each_substring() and match_substring() instead of strsep() and match_token() Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- statistic.c | 67 +--- 1 file changed, 20 insertions(

[Patch 1/2] add for_each_substring() and match_substring()

2007-03-06 Thread Martin Peschke
() / match_substring(), e.g. all the stuff in fs/, should not be difficult. Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- include/linux/parser.h |7 +++ lib/parser.c | 45 - 2 files changed, 51 insertions(+), 1 deletion(-) Index:

[Patch] small lib/parser.c cleanup

2007-03-06 Thread Martin Peschke
simplifying code by using available string duplication function Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- parser.c |8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) Index: linux/lib/pa

[Patch] small lib/parser.c cleanup

2007-03-06 Thread Martin Peschke
simplifying code by using available string duplication function Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- parser.c |8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) Index: linux/lib/parser.c

[Patch 1/2] add for_each_substring() and match_substring()

2007-03-06 Thread Martin Peschke
() / match_substring(), e.g. all the stuff in fs/, should not be difficult. Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- include/linux/parser.h |7 +++ lib/parser.c | 45 - 2 files changed, 51 insertions(+), 1 deletion(-) Index: linux

[Patch 2/2] add for_each_substring() and match_substring() - exploitation

2007-03-06 Thread Martin Peschke
simplifying statistics code by using for_each_substring() and match_substring() instead of strsep() and match_token() Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- statistic.c | 67 +--- 1 file changed, 20 insertions(+), 47

[Patch] fix parsing of statistics type-attribute

2007-03-06 Thread Martin Peschke
Without this fix the the statistics user interface accepted, for example: echo name=my_stats type=utilisa definition while it should only accept: echo name=my_stats type=utilisation definition Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- statistic.c |3 ++- 1

[Resend][Patch] fixing a comment

2007-02-05 Thread Martin Peschke
The return value of scnprintf() never exceeds @size. Patch is against 2.6.20-rc6-mm3 Signed-off-by: Martin Peschke <[EMAIL PROTECTED]> --- vsprintf.c |3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/lib/vsprintf.c2007-02-02 19:12:09.0 +0100 +++ b/lib/vspr

[Resend][Patch] fixing a comment

2007-02-05 Thread Martin Peschke
The return value of scnprintf() never exceeds @size. Patch is against 2.6.20-rc6-mm3 Signed-off-by: Martin Peschke [EMAIL PROTECTED] --- vsprintf.c |3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) --- a/lib/vsprintf.c2007-02-02 19:12:09.0 +0100 +++ b/lib/vsprintf.c