From: Steven Scholz <steven.scholz@imc-berlin.de>
To: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Cc: linux-ide@vger.kernel.org
Subject: Re: HPA and failed opcode was: 0x37 ?
Date: Wed, 31 Jan 2007 10:51:36 +0100 [thread overview]
Message-ID: <45C066A8.2090500@imc-berlin.de> (raw)
In-Reply-To: <45BF8F33.3070008@ru.mvista.com>
Sergei,
>> How could one then explain
>
>> current capacity is 78140160 sectors would be 0x000004A85300
>> native capacity is 185074430006016 sectors would be 0xA852FFA85300
>>
>> ? First three bytes ok, then the other three bytes rubbish?
>
> Note that they're not complete garbage but equal the value of the
> lower 3 bytes minus 1. What is clear is that Read Native Max Address Ext
> command must be mistreating the HOB bit... :-)
Well this results from
addr++; /* since the return value is (maxlba - 1), we add 1 */
in idedisk_read_native_max_address_ext().
Apparently on my system
u32 high = (args.hobRegister[IDE_HCYL_OFFSET] << 16) |
(args.hobRegister[IDE_LCYL_OFFSET] << 8) |
args.hobRegister[IDE_SECTOR_OFFSET];
u32 low = ((args.tfRegister[IDE_HCYL_OFFSET])<<16) |
((args.tfRegister[IDE_LCYL_OFFSET])<<8) |
(args.tfRegister[IDE_SECTOR_OFFSET]);
high and low contain the same values! :-(
I "hardcoded" set_max = capacity, now I get
hda: Host Protected Area detected.
current capacity is 78140160 sectors (40007 MB)
native capacity is 78140160 sectors (40007 MB)
hda: Host Protected Area disabled.
hda: 4289221376 sectors (2196081 MB) w/8192KiB Cache, CHS=65535/255/63
;-)
But still something must go terribly wrong.
smartctl shows
7 Seek_Error_Rate 0x000f 061 060 030 - 1513926
195 Hardware_ECC_Recovered 0x001a 100 066 000 - 104721680
And after just doing a "mke2fs /dev/hda1" I see
7 Seek_Error_Rate 0x000f 061 060 030 - 1516919
195 Hardware_ECC_Recovered 0x001a 095 066 000 - 104791382
:-(
--
Steven
next prev parent reply other threads:[~2007-01-31 9:51 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-30 14:02 HPA and failed opcode was: 0x37 ? Steven Scholz
2007-01-30 14:07 ` Steven Scholz
2007-01-30 15:44 ` Eric D. Mudama
2007-01-30 15:50 ` Eric D. Mudama
2007-01-30 15:54 ` Steven Scholz
2007-01-30 15:53 ` Steven Scholz
2007-01-30 16:44 ` Alan
2007-01-30 16:46 ` Steven Scholz
2007-01-30 17:26 ` Alan
2007-01-30 17:19 ` Steven Scholz
2007-01-30 18:07 ` Alan
2007-01-30 18:04 ` Steven Scholz
2007-01-30 18:23 ` Eric D. Mudama
2007-01-30 18:32 ` Sergei Shtylyov
2007-01-30 19:56 ` Eric D. Mudama
2007-01-30 20:01 ` Eric D. Mudama
2007-01-31 8:29 ` Steven Scholz
2007-01-31 12:54 ` Sergei Shtylyov
2007-01-31 13:08 ` Steven Scholz
2007-01-31 13:12 ` Sergei Shtylyov
2007-01-31 13:38 ` Steven Scholz
2007-01-31 9:51 ` Steven Scholz [this message]
2007-01-31 12:50 ` Sergei Shtylyov
2007-01-31 13:04 ` Steven Scholz
2007-01-31 13:33 ` Alan
2007-01-31 13:26 ` Steven Scholz
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=45C066A8.2090500@imc-berlin.de \
--to=steven.scholz@imc-berlin.de \
--cc=linux-ide@vger.kernel.org \
--cc=sshtylyov@ru.mvista.com \
/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;
as well as URLs for NNTP newsgroup(s).