diff options
| author | Andrew Morton <akpm@digeo.com> | 2002-11-10 02:02:25 -0800 |
|---|---|---|
| committer | David S. Miller <davem@nuts.ninka.net> | 2002-11-10 02:02:25 -0800 |
| commit | 36e573c792536dbe8334ef1e5e3b5c4f49d6113a (patch) | |
| tree | 8c3aeed26844b36e4e2ccb8caba6b6000381d1d5 /include/linux/blkdev.h | |
| parent | 3e4c5912b9043263c64a30591b7ebd3a7ffd9cea (diff) | |
[PATCH] remove duplicated disk statistics
This patch will break some userspace monitoring apps in the name of
having sane disk statistics in 2.6.x.
Patch from Rick Lindsley <ricklind@us.ibm.com>
In 2.5.46, there are now disk statistics being collected twice: once
for gendisk/hd_struct, and once for dkstat. They are collecting the
same thing. This patch removes dkstat, which also had the disadvantage
of being limited by DK_MAX_MAJOR and DK_MAX_DISK. (Those #defines are
removed too.)
In addition, this patch removes disk statistics from /proc/stat since
they are now available via sysfs and there seems to have been a general
preference in previous discussions to "clean up" /proc/stat. Too many
disks being reported in /proc/stat also caused buffer overflows when
trying to print out the data.
The code in led.c from the parisc architecture has not apparently been
recompiled under recent versions of 2.5, since it references
kstat.dk_drive which doesn't exist in later versions. Accordingly,
I've added an #ifdef 0 and a comment to that code so that it may at
least compile, albeit without one feature -- a step up from its state
now. If it is preferable to keep the broken code in, that patch may
easily be excised from below.
Diffstat (limited to 'include/linux/blkdev.h')
| -rw-r--r-- | include/linux/blkdev.h | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index 95b7c2e03a2a..a3927e6b6dee 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -11,22 +11,6 @@ #include <asm/scatterlist.h> -/* - * Disk stats ... - */ - -#define DK_MAX_MAJOR 16 -#define DK_MAX_DISK 16 - -struct disk_stat { - unsigned int drive[DK_MAX_MAJOR][DK_MAX_DISK]; - unsigned int drive_rio[DK_MAX_MAJOR][DK_MAX_DISK]; - unsigned int drive_wio[DK_MAX_MAJOR][DK_MAX_DISK]; - unsigned int drive_rblk[DK_MAX_MAJOR][DK_MAX_DISK]; - unsigned int drive_wblk[DK_MAX_MAJOR][DK_MAX_DISK]; -}; -extern struct disk_stat dkstat; - struct request_queue; typedef struct request_queue request_queue_t; struct elevator_s; |
