mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: Harald.Schaefer@gls-germany.com
Cc: Thomas.Mieslinger@gls-germany.com,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: ide-problem still with 2.4.21-pre5-ac1
Date: 06 Mar 2003 15:15:32 +0000	[thread overview]
Message-ID: <1046963731.17718.35.camel@irongate.swansea.linux.org.uk> (raw)
In-Reply-To: <OFA9D69D12.A2BE6A15-ONC1256CE1.00344A6F-C1256CE1.0039609A@LocalDomain>

On Thu, 2003-03-06 at 10:26, Harald.Schaefer@gls-germany.com wrote:
> sorry for sending you directly again instead to the kernel-ML. I do so
> because the problems are only caused by ide-disk.c. This mail is CCed to
> the ML.

I disagree there

> I was able to work around the problem for our little environment (about
> 2000 Computers of 9 different types) with the following dirty hack,
> changing from kernel-2.4.21-pre5-ac1:

We set the mapping to 255, 63, .. whe the drive supports reporting its
LBA geometry addressing. Otherwise we use the lba capacity based on 
the bios mapping. The 48bit LBA factor would explain the reason you
saw some drives work and some fail.

> In your mail you wrote that the kernel honors the mapping of existing
> partitions on the disk. Unfortunately the kernel 2.4.21-pre5-ac1 does not
> so! I created a primary dos-partition on a Fujitsu-disk attached to a
> Compaq Notebook Evo N610c using MS-DOS 6.22 fdisk, which bios uses a
> 240-head mapping, but linux used a 255-head maping at the next boot. This
> may destroy data on the disk.

Linux maps the disk in a logical block order at all times. The partition
code looks for any existing mappings and then translates based on the
data it discovers (fs/partition/msdos.c calling ide_xlate_1024()

> I think that the priority of LBA from BIOS has to be raised to 2 and the
> priority of LBA from drive should be lowered to 3.
> The mapping-problem only appreared with very new drives in some
> brand-computers using a 240-head mapping from the bios.

I don't think thats viable when doing 48bit LBA.

> We don't know which problems our workaround causes, but we're happy with it
> and would like to see it in an upcoming release. Why was a 255 head mapping
> hard coded in the kernel?

You'd have to ask Andre to be sure but I believe it is what the spec
says about those mappings. The more interesting question if thats what
you are seeing is why the ide_xlate_1024 handling isn't picking up 
on the situation. That seems to be the actual problem case.

Alan




  reply	other threads:[~2003-03-06 14:00 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-06 10:26 Harald.Schaefer
2003-03-06 15:15 ` Alan Cox [this message]
2003-03-08 22:28 ` Bill Davidsen
2003-03-08 23:23   ` Andries Brouwer
2003-03-09  1:30     ` Alan Cox
2003-03-09  8:17       ` Andre Hedrick
2003-03-09  2:38     ` Bill Davidsen
2003-03-09  8:17 Andries.Brouwer
2003-03-09 20:30 ` Bill Davidsen
2003-03-09  8:41 Andries.Brouwer
2003-03-09 20:24 ` Bill Davidsen
2003-03-09 20:41 Andries.Brouwer
2003-03-11  9:03 Thomas.Mieslinger
2003-03-11  9:46 Andries.Brouwer

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=1046963731.17718.35.camel@irongate.swansea.linux.org.uk \
    --to=alan@lxorguk.ukuu.org.uk \
    --cc=Harald.Schaefer@gls-germany.com \
    --cc=Thomas.Mieslinger@gls-germany.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

all inboxes | Powered by JetHome®