From: Mark Bellon <mbellon@mvista.com>
To: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Andre Hedrick <andre@linux-ide.org>,
linux-kernel@vger.kernel.org, akpm@osdl.org
Subject: Re: [PATCH] IDE disks show invalid geometries in /proc/ide/hd*/geometry
Date: Wed, 03 Aug 2005 10:37:12 -0700 [thread overview]
Message-ID: <42F100C8.8040700@mvista.com> (raw)
In-Reply-To: <58cb370e05080310195c244f72@mail.gmail.com>
Bartlomiej Zolnierkiewicz wrote:
>Hi,
>
>The topic was discussed to death on linux-kernel.
>
>Mark, you need to fix your applications and stop using /proc/ide/hd*/geometry
>or/and HDIO_GET_GEO ioctl (which BTW your patch also affects).
>
>
Fixing the applications I can understand but the patch still seems
necessary, to me, so the
HDIO_GET_GEO returns "rational" values.
I tested HDIO_GET_GEO and it returns the same broken values as go into
/proc (no surprises) without my patch.
If a drive is in LBA mode (28 or 48 bit) the existing code doesn't
always "fix up" the geometry properly for some value returns. It only
tries with 48 bit mode and it fails there for some values. My patch
forces a complete geometry and appears (to me) to preserve the side
efefcts of the existing code.
Am I missing something?
mark
>Bartlomiej
>
>On 8/3/05, Andre Hedrick <andre@linux-ide.org> wrote:
>
>
>>Did you read ATA-1 through ATA-7 to understand all the variations?
>>
>>On Tue, 2 Aug 2005, Mark Bellon wrote:
>>
>>
>>
>>>The ATA specification tells large disk drives to return C/H/S data of
>>>16383/16/63 regardless of their actual size (other variations on this
>>>return include 15 heads and/or 4092 cylinders). Unfortunately these CHS
>>>data confuse the existing IDE code and cause it to report invalid
>>>geometries in /proc when the disk runs in LBA mode.
>>>
>>>The invalid geometries can cause failures in the partitioning tools;
>>>partitioning may be impossible or illogical size limitations occur. This
>>>also leads to various forms of human confusion.
>>>
>>>I attach a patch that fixes this problem while strongly attempting to
>>>not break any existing side effects and await any comments.
>>>
>>>mark
>>>
>>>Signed-off-by: Mark Bellon <mbellon@mvista.com>
>>>
>>>
>>>
>>>
>>-
>>To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>>the body of a message to majordomo@vger.kernel.org
>>More majordomo info at http://vger.kernel.org/majordomo-info.html
>>Please read the FAQ at http://www.tux.org/lkml/
>>
>>
>>
next prev parent reply other threads:[~2005-08-03 17:39 UTC|newest]
Thread overview: 24+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-29 0:03 [PATCH] disk quotas fail when /etc/mtab is symlinked to /proc/mounts Mark Bellon
2005-07-29 0:13 ` Nathan Scott
2005-07-29 0:15 ` Mark Bellon
2005-07-29 0:19 ` Mark Bellon
2005-07-29 0:23 ` Andrew Morton
2005-07-29 0:29 ` Mark Bellon
2005-07-29 0:46 ` Mark Bellon
2005-07-29 13:46 ` Jan Kara
2005-07-29 15:47 ` Mark Bellon
2005-07-29 17:21 ` [PATCH] (REPOST/REVISION) " Mark Bellon
2005-07-29 22:03 ` [PATCH] (TAKE 3) " Mark Bellon
2005-08-02 21:27 ` [PATCH] IDE disks show invalid geometries in /proc/ide/hd*/geometry Mark Bellon
2005-08-03 7:19 ` Andre Hedrick
2005-08-03 16:54 ` Mark Bellon
2005-08-03 17:19 ` Bartlomiej Zolnierkiewicz
2005-08-03 17:37 ` Mark Bellon [this message]
2005-08-03 18:05 ` Bartlomiej Zolnierkiewicz
2005-08-03 18:32 ` Mark Bellon
2005-08-03 18:51 ` Bartlomiej Zolnierkiewicz
2005-08-04 6:03 ` Jan Engelhardt
2005-08-04 16:44 ` Mark Bellon
2005-08-04 23:45 ` Eric D. Mudama
2005-08-08 16:02 ` [PATCH] (TAKE 3) disk quotas fail when /etc/mtab is symlinked to /proc/mounts Jan Kara
2005-08-08 17:55 ` [PATCH] PPC64: large INITRD causes kernel not to boot Mark Bellon
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=42F100C8.8040700@mvista.com \
--to=mbellon@mvista.com \
--cc=akpm@osdl.org \
--cc=andre@linux-ide.org \
--cc=bzolnier@gmail.com \
--cc=linux-kernel@vger.kernel.org \
/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