From: Andries.Brouwer@cwi.nl
To: anders.henke@sysiphus.de, linux-kernel@vger.kernel.org
Cc: marcelo@conectiva.com.br
Subject: Re: using 2 TB in real life
Date: Fri, 13 Dec 2002 00:15:39 +0100 (MET) [thread overview]
Message-ID: <UTC200212122315.gBCNFdp22965.aeb@smtp.cwi.nl> (raw)
> SCSI device sdb: -320126976 512-byte hdwr sectors (-163904 MB)
Yes, the code in 2.4.20 works up to 30 bits.
A slight modification works up to 31 bits.
[This is cosmetic only.]
Andries
--- /linux/2.4/linux-2.4.20/linux/drivers/scsi/sd.c Sat Aug 3 02:39:44 2002
+++ ./sd.c Fri Dec 13 00:12:00 2002
@@ -1001,7 +1001,7 @@
*/
int m;
int hard_sector = sector_size;
- int sz = rscsi_disks[i].capacity * (hard_sector/256);
+ unsigned int sz = (rscsi_disks[i].capacity/2) * (hard_sector/256);
/* There are 16 minors allocated for each major device */
for (m = i << 4; m < ((i + 1) << 4); m++) {
@@ -1009,9 +1009,9 @@
}
printk("SCSI device %s: "
- "%d %d-byte hdwr sectors (%d MB)\n",
+ "%u %d-byte hdwr sectors (%d MB)\n",
nbuff, rscsi_disks[i].capacity,
- hard_sector, (sz/2 - sz/1250 + 974)/1950);
+ hard_sector, (sz - sz/625 + 974)/1950);
}
/* Rescale capacity to 512-byte units */
next reply other threads:[~2002-12-12 23:07 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-12-12 23:15 Andries.Brouwer [this message]
2002-12-13 14:43 ` Anders Henke
-- strict thread matches above, loose matches on Subject: below --
2002-12-12 11:12 Anders Henke
2002-12-12 12:03 ` Mike Black
2002-12-12 17:22 ` Bryan O'Sullivan
2002-12-12 17:48 ` Anders Henke
2002-12-12 19:03 ` Bryan O'Sullivan
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=UTC200212122315.gBCNFdp22965.aeb@smtp.cwi.nl \
--to=andries.brouwer@cwi.nl \
--cc=anders.henke@sysiphus.de \
--cc=linux-kernel@vger.kernel.org \
--cc=marcelo@conectiva.com.br \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®