Re: patch for sd.c: fix MB vs. GB

Chris Pirih (proverbs@wolfenet.com)
Sun, 27 Dec 1998 16:33:53 -0800


The problem is that the reporting is confused -- the MB number is
bytes / 2^20, but the GB number is MB / 10. Either the MB number
should be changed to bytes / 10^6, or the GB number should be
changed to MB / 2^10.

Or is there some compelling reason for GB to be *neither* binary
(technical gigabytes) *nor* decimal (marketing gigabytes)?

E.g. I have a drive which IBM calls "9.1 GB" which Linux reports as:

SCSI device sdb: hdwr sector= 512 bytes. Sectors= 17916240 [8748 MB] [8.7 GB]

17916240 * 512 = 9173114880 (bytes) = ~9.2 "decimal" gigabytes
= ~8748 "binary" megabytes = ~8.5 "binary" gigabytes

Regardless of which system one prefers, 8.7 GB is simply wrong.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/