how to get some values for LBA <-> CHS conversion?

From: lallous (lallous_at_lgwm.org)
Date: 05/26/04


Date: Wed, 26 May 2004 17:59:27 +0000 (UTC)

Hello

I am trying to apply this formula (found @
http://encyclopedia.thefreedictionary.com/CHS%20conversion):

[quote]
>>From CHS to LBA
The equation to convert from CHS to LBA follows:

 LBA = ( ( CYL * HPC + HEAD ) * SPT ) + SECT - 1

Where:

 LBA: linear base address of the block
 CYL: value of the cylinder CHS coordinate
 HPC: number of heads per cylinder for the disk
 HEAD: value of the head CHS coordinate
 SPT: number of sectors per track for the disk
 SECT: value of the sector CHS coordinate
[/quote]

I have read the partition table and got these values: CYL, HEAD, SECT; how
can I get the other missing variables (SPT & HPC) ?

--
Elias


Relevant Pages

  • ATA/CHS problem (path + new information)
    ... True ATA device may not have ATA_FLAG_54_58 valid bit, ... I also want to know why ata driver doesn't check LBA support from word 49? ... that only 20G part of my hard disk works with CHS. ...
    (freebsd-current)
  • ATA/CHS problem (path + new information)
    ... True ATA device may not have ATA_FLAG_54_58 valid bit, ... I also want to know why ata driver doesn't check LBA support from word 49? ... that only 20G part of my hard disk works with CHS. ...
    (freebsd-hackers)
  • Re: Partitioning a reformatted Maxtor 91000D8 (9539 MB) recognizes only 2008 MB --> Uses LBA mode
    ... CHS mode was a logistical nightmare. ... Also the maximum size with LBA is much higher (dependes of block size mostly ... So change in your BIOS the disk mode from CHS to LBA: ...
    (comp.os.linux.setup)
  • Re: PartitionMagic8 & Vista?
    ... Length of partition table incorrect. ... CHS length: 20979295 ... LBA length: 20971520 ... FileSyst. ...
    (microsoft.public.windows.vista.general)
  • Re: fdisk chs numbers
    ... arrangement of the data on the disk ... I thought the CHS numbers would be derived from the LBA ... why should those numbers be tied to DOS FAT? ...
    (uk.comp.sys.mac)