aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorJurzitza, Dieter <DJurzitza@harmanbecker.com>2006-09-12 13:23:56 +0200
committerWilly Tarreau <w@1wt.eu>2006-09-28 23:53:28 +0200
commita34c4fd7853fe577f63acd755a397fe6fa6a0092 (patch)
tree45c421609ea8a5e69146fcec0c347a0469ef64f8 /fs
parent4178cd8d9a552390bd76d5946e7e18e01f4720ec (diff)
downloadlinux-2.4-a34c4fd7853fe577f63acd755a397fe6fa6a0092.tar.gz
[PATCH] really fix size display for sun partitions larger than 1TByte
Problem: the last fix introduced by Jeff Mahoney for kernel 2.6 was not complete for kernel 2.4 (as applied). I found out that add_gd_partition is called by any type of partition (2.4). add_gd_partition is defined as add_gd_partition (int, int), what makes no sense to me as negative numbers should never occur here. As long as add_gd_partition is not changed to add_gd_partition (unsigned, unsigned), /proc/partitions will keep showing negative numbers. If ever someone could look into this, within the different partition type files in linux/fs/partitions the parameters to add_gd_partitions seem to be chosen arbitrarily between int, unsigned and unsigned long, whatever seemed to be appropriate, I think it would make sense to get consistent parameters to add_gd_partition from all partition types here. Especially if one takes into account that sizeof (long) and sizeof (int) may differ significantly i. e. on sparc. Signed-off-by: Dieter Jurzitza <DJurzitza@HarmanBecker.com> Signed-off-by: Willy Tarreau <w@1wt.eu>
Diffstat (limited to 'fs')
-rw-r--r--fs/partitions/check.c3
-rw-r--r--fs/partitions/check.h3
2 files changed, 4 insertions, 2 deletions
diff --git a/fs/partitions/check.c b/fs/partitions/check.c
index 323572335d781b..f99c836e387b69 100644
--- a/fs/partitions/check.c
+++ b/fs/partitions/check.c
@@ -204,7 +204,8 @@ char *disk_name (struct gendisk *hd, int minor, char *buf)
/*
* Add a partitions details to the devices partition description.
*/
-void add_gd_partition(struct gendisk *hd, int minor, int start, int size)
+void add_gd_partition(struct gendisk *hd, int minor, unsigned int start,
+ unsigned int size)
{
#ifndef CONFIG_DEVFS_FS
char buf[40];
diff --git a/fs/partitions/check.h b/fs/partitions/check.h
index 32d7940469a406..dd9351702e5b70 100644
--- a/fs/partitions/check.h
+++ b/fs/partitions/check.h
@@ -2,7 +2,8 @@
* add_partition adds a partitions details to the devices partition
* description.
*/
-void add_gd_partition(struct gendisk *hd, int minor, int start, int size);
+void add_gd_partition(struct gendisk *hd, int minor, unsigned int start,
+ unsigned int size);
typedef struct {struct page *v;} Sector;