lkml.org 
[lkml]   [2008]   [Apr]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Disk geometry from /sys
    > Why do you want to know what cylinder size the hard disk pretents to
    > have? What use could it be? Harddisks have varying numbers of sectors

    It matters on a CHS addressed device - vaguely.

    > drive. All that matters on a modern drive is the total number of
    > sectors since all access is done by requesting a specific sector number
    > starting from the begining of the drive. Where it is physically located
    > is none of software's business, and it may not even be adjacent to the
    > sector with a number right next to the requested one due to defect
    > management and various optimizations.

    And some other OS's make certain assumptions about layout that must agree
    with that OS view of the disk. A good general rule is to believe the
    partition table information if present and if not use SG_IO to issue an
    IDENTIFY to any ATA or CFA drive to see how it has mapped the device.

    Even better make use fo the existing tools whenever possible - disk
    partitioning is more like magic than science

    Alan


    \
     
     \ /
      Last update: 2008-04-09 23:57    [W:4.165 / U:0.020 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site