public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: lsorense@csclub.uwaterloo.ca (Lennart Sorensen)
Cc: Francis Moreau <francis.moro@gmail.com>, linux-kernel@vger.kernel.org
Subject: Re: Disk geometry from /sys
Date: Wed, 9 Apr 2008 22:52:07 +0100	[thread overview]
Message-ID: <20080409225207.732faa4e@core> (raw)
In-Reply-To: <20080409212840.GB2160@csclub.uwaterloo.ca>

> 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

  reply	other threads:[~2008-04-09 21:55 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-09 20:53 Disk geometry from /sys Francis Moreau
2008-04-09 21:28 ` Lennart Sorensen
2008-04-09 21:52   ` Alan Cox [this message]
2008-04-09 22:16   ` Bernd Eckenfels
2008-04-10 14:52     ` Lennart Sorensen
2008-04-10 19:23   ` Francis Moreau
2008-04-09 21:57 ` Mark Lord
2008-04-10 19:05   ` Francis Moreau
2008-04-10 19:53     ` Mark Lord
2008-04-10 12:22 ` linux-os (Dick Johnson)
2008-04-10 19:15   ` Francis Moreau
2008-04-10 13:58 ` Bill Davidsen
2008-04-14 12:57 ` Seewer Philippe
2008-04-15  7:40   ` Francis Moreau
2008-04-16  7:49     ` Seewer Philippe
2008-04-17 14:09       ` Francis Moreau
2008-04-17 14:49         ` Seewer Philippe
2008-04-18 13:22           ` Mark Lord
2008-04-18 13:37             ` Seewer Philippe
2008-04-22 20:11               ` Francis Moreau
2008-04-23  6:44                 ` Seewer Philippe
2008-04-23  6:56                   ` Francis Moreau
2008-04-22 20:16             ` Francis Moreau
2008-04-22 22:44               ` Mark Lord
2008-04-23  6:53                 ` Seewer Philippe
2008-04-23  7:02                 ` Francis Moreau
2008-04-23  9:33                   ` Seewer Philippe
2008-04-23 13:47                   ` Mark Lord
2008-04-22 20:10           ` Francis Moreau
2008-04-23  6:48             ` Seewer Philippe

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=20080409225207.732faa4e@core \
    --to=alan@lxorguk.ukuu.org.uk \
    --cc=francis.moro@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lsorense@csclub.uwaterloo.ca \
    /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