From: Mike Miller <mike.miller@hp.com>

This patch fixes our cylinder calculations.  Without his fix the number of
cylinders maxes out at 65535.

Signed-off-by: Andrew Morton <akpm@osdl.org>
---

 25-akpm/drivers/block/cciss.c |    6 ++++++
 1 files changed, 6 insertions(+)

diff -puN drivers/block/cciss.c~cciss-updates-cylinder-calculation-fix-for-268-rc3 drivers/block/cciss.c
--- 25/drivers/block/cciss.c~cciss-updates-cylinder-calculation-fix-for-268-rc3	Thu Aug  5 15:38:30 2004
+++ 25-akpm/drivers/block/cciss.c	Thu Aug  5 15:38:30 2004
@@ -1470,6 +1470,8 @@ static void cciss_geometry_inquiry(int c
 			drv->sectors = 32; // Sectors per track
 			drv->cylinders = total_size / 255 / 32;
 		} else {
+			unsigned int t;
+
 			drv->block_size = block_size;
 			drv->nr_blocks = total_size;
 			drv->heads = inq_buff->data_byte[6];
@@ -1477,6 +1479,10 @@ static void cciss_geometry_inquiry(int c
 			drv->cylinders = (inq_buff->data_byte[4] & 0xff) << 8;
 			drv->cylinders += inq_buff->data_byte[5];
 			drv->raid_level = inq_buff->data_byte[8];
+			t = drv->heads * drv->sectors;
+			if (t > 1) {
+				drv->cylinders = total_size/t;
+			}
 		}
 	} else { /* Get geometry failed */
 		printk(KERN_WARNING "cciss: reading geometry failed, "
_