Hardware Reference
In-Depth Information
Gibibytes (GiB) 5.77 5.77 5.77
As you can see from this example, a drive with 12,000 cylinders and 16 heads translates to 750
cylinders and 256 heads using the standard CHS bit-shift scheme. The revised CHS bit-shift scheme
rule does a double translation in this case, first changing the 16 heads to 15 and then multiplying the
12,000 cylinders by 16/15, resulting in 12,800 cylinders. Then, the new cylinder value is CHS bit-
shift-translated (it is divided by 16), resulting in 800 logical cylinders. Likewise, the 15 heads are
multiplied by 16, resulting in 240 logical heads. If the logical cylinder count calculates to more than
1,024, it is truncated to 1,024. In this case, what started out as 12,000 cylinders and 16 heads P-CHS
becomes 800 cylinders and 240 heads (instead of 750 cylinders and 256 heads) L-CHS, which works
around the bug in the DOS/Win9x/Me operating systems.
So far, all my examples have been clean—that is, the L-CHS parameters have calculated to the same
capacity as the P-CHS parameters. Unfortunately, it doesn't always work out that way. The following
shows a more typical example in the real world. Several 8.4GB drives from Maxtor, Quantum,
Seagate, and others report 16,383 cylinders and 16 heads P-CHS. For those drives, the translations
would work out as follows:
Click here to view code image
Bit-shift Revised Bit-
P-CHS L-CHS shift L-CHS
Parameters Parameters Parameters
-------------------------------------------------------------
Cylinders 16,383 1,023 1,024
Heads 16 256 240
Sectors/Track 63 63 63
=============================================================
Total Sectors 16,514,064 16,498,944 15,482,880
-------------------------------------------------------------
Total Bytes 8,455,200,768 8,447,459,328 7,927,234,560
Megabytes (MB) 8,455 8,447 7,927
Mebibytes (MiB) 8,064 8,056 7,560
Gigabytes (GB) 8.46 8.45 7.93
Gibibytes (GiB) 7.87 7.87 7.38
Note that the revised CHS bit-shift translation rules result in supporting only 7.93GB of the 8.46GB
total on the drive. In fact, the parameters shown (with 240 heads) are the absolute maximum that
revised CHS bit-shift supports. Fortunately, another translation mode is available that improves this
situation.
LBA-Assist Translation
The LBA-assist translation method places no artificial limits on the reported drive geometries, but it
works only on drives that support LBA addressing at the ATA interface level. Fortunately, though,
virtually all ATA drives larger than 2GB support LBA. LBA-assist translation takes the CHS
parameters the drive reports, multiplies them together to get a calculated LBA maximum value (total
number of sectors), and then uses this calculated LBA number to derive the translated CHS
parameters. Table 7.21 shows the rules for LBA-assist translation.
Table 7.21. LBA-Assist Translation Rules
 
 
 
 
Search WWH ::




Custom Search