aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsicam.c
diff options
context:
space:
mode:
authorTrond Myklebust <Trond.Myklebust@netapp.com>2006-07-05 13:13:03 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2006-07-05 13:13:03 -0400
commit5e66dd6d66ffe758b39b6dcadf2330753ee1159b (patch)
treea72cdcff4448e4af9425cc213ddf56ab23e697fe /drivers/scsi/scsicam.c
parent026477c1141b67e98e3bd8bdedb7d4b88a3ecd09 (diff)
parentca78f6baca863afe2e6a244a0fe94b3a70211d46 (diff)
Merge branch 'master' of /home/trondmy/kernel/linux-2.6/
Diffstat (limited to 'drivers/scsi/scsicam.c')
-rw-r--r--drivers/scsi/scsicam.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/scsi/scsicam.c b/drivers/scsi/scsicam.c
index b78354fc4b17..cd68a66c7bb3 100644
--- a/drivers/scsi/scsicam.c
+++ b/drivers/scsi/scsicam.c
@@ -57,6 +57,7 @@ EXPORT_SYMBOL(scsi_bios_ptable);
57int scsicam_bios_param(struct block_device *bdev, sector_t capacity, int *ip) 57int scsicam_bios_param(struct block_device *bdev, sector_t capacity, int *ip)
58{ 58{
59 unsigned char *p; 59 unsigned char *p;
60 u64 capacity64 = capacity; /* Suppress gcc warning */
60 int ret; 61 int ret;
61 62
62 p = scsi_bios_ptable(bdev); 63 p = scsi_bios_ptable(bdev);
@@ -68,7 +69,7 @@ int scsicam_bios_param(struct block_device *bdev, sector_t capacity, int *ip)
68 (unsigned int *)ip + 0, (unsigned int *)ip + 1); 69 (unsigned int *)ip + 0, (unsigned int *)ip + 1);
69 kfree(p); 70 kfree(p);
70 71
71 if (ret == -1) { 72 if (ret == -1 && capacity64 < (1ULL << 32)) {
72 /* pick some standard mapping with at most 1024 cylinders, 73 /* pick some standard mapping with at most 1024 cylinders,
73 and at most 62 sectors per track - this works up to 74 and at most 62 sectors per track - this works up to
74 7905 MB */ 75 7905 MB */