linux-scsi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [repost][PATCH 1/8] stex: fix biosparam calculation
@ 2006-12-05  1:49 Ed Lin
  2006-12-05  2:17 ` Jeff Garzik
  0 siblings, 1 reply; 2+ messages in thread
From: Ed Lin @ 2006-12-05  1:49 UTC (permalink / raw)
  To: linux-scsi; +Cc: James.Bottomley, jeff, promise_linux


Fix biosparam calculation.

Signed-off-by: Ed Lin <ed.lin@promise.com>
---
diff --git a/drivers/scsi/stex.c b/drivers/scsi/stex.c
index 185c270..91d484c 100644
--- a/drivers/scsi/stex.c
+++ b/drivers/scsi/stex.c
@@ -1100,18 +1100,18 @@ static int stex_reset(struct scsi_cmnd *
 static int stex_biosparam(struct scsi_device *sdev,
 	struct block_device *bdev, sector_t capacity, int geom[])
 {
-	int heads = 255, sectors = 63, cylinders;
+	int heads = 255, sectors = 63;
 
 	if (capacity < 0x200000) {
 		heads = 64;
 		sectors = 32;
 	}
 
-	cylinders = sector_div(capacity, heads * sectors);
+	sector_div(capacity, heads * sectors);
 
 	geom[0] = heads;
 	geom[1] = sectors;
-	geom[2] = cylinders;
+	geom[2] = capacity;
 
 	return 0;
 }



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [repost][PATCH 1/8] stex: fix biosparam calculation
  2006-12-05  1:49 [repost][PATCH 1/8] stex: fix biosparam calculation Ed Lin
@ 2006-12-05  2:17 ` Jeff Garzik
  0 siblings, 0 replies; 2+ messages in thread
From: Jeff Garzik @ 2006-12-05  2:17 UTC (permalink / raw)
  To: Ed Lin; +Cc: linux-scsi, James.Bottomley, promise_linux

Ed Lin wrote:
> Fix biosparam calculation.
> 
> Signed-off-by: Ed Lin <ed.lin@promise.com>

ACK patches 1-8



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-12-05  2:17 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-12-05  1:49 [repost][PATCH 1/8] stex: fix biosparam calculation Ed Lin
2006-12-05  2:17 ` Jeff Garzik

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).