An ATA 48-bit Address feature set issue

  • Thread starter Thread starter Svend Olaf Mikkelsen
  • Start date Start date
S

Svend Olaf Mikkelsen

This is part of the output from my Identify program for a disk larger
than 128 GB (words 23-26, 27-46 and 60-61):

Identify, version 1.0.

Secondary Master

23 3.06 Firmware revision (8 ASCII characters)
27 Model number (40 ASCII characters)
ST3160023A

60 312581808 Total number of user addressable sectors (LBA mode
only)


And this is the same disk after power down/up:

23 3.06 Firmware revision (8 ASCII characters)
27 Model number (40 ASCII characters)
ST3160023A

60 268435455 Total number of user addressable sectors (LBA mode
only)

As far as I can see (but I did not wait 10 minutes), this is a serious
issue. Can anybody explain what happened?
 
This happens on power cycle but not reset? You are just booting to DOS?

From ATA-6 <<
6.2.1 Definitions and value ranges of IDENTIFY DEVICE words (see 8.12)

1) Words (61:60) shall contain the value one greater than the total number of
user-addressable

sectors in 28-bit addressing and shall not exceed 0FFFFFFFh. The content of
words (61:60) shall be greater than or equal to one and less than or equal to
268,435,455.

2) Words (103:100) shall contain the value one greater than the total number
of user-addressable sectors in 48-bit addressing and shall not exceed
0000FFFFFFFFFFFFh.If you don't get any answers, join the T13 mail list and ask.

| This is part of the output from my Identify program for a disk larger
| than 128 GB (words 23-26, 27-46 and 60-61):
|
| Identify, version 1.0.
|
| Secondary Master
|
| 23 3.06 Firmware revision (8 ASCII characters)
| 27 Model number (40 ASCII characters)
| ST3160023A
|
| 60 312581808 Total number of user addressable sectors (LBA mode
| only)
|
|
| And this is the same disk after power down/up:
|
| 23 3.06 Firmware revision (8 ASCII characters)
| 27 Model number (40 ASCII characters)
| ST3160023A
|
| 60 268435455 Total number of user addressable sectors (LBA mode
| only)
|
| As far as I can see (but I did not wait 10 minutes), this is a serious
| issue. Can anybody explain what happened?
| --
| Svend Olaf
| http://www.partitionsupport.com/utilities.htm
 
This happens on power cycle but not reset? You are just booting to DOS?

I see the first output as an error. And the error did not disappear by
pressing the system reset button. Yes DOS, and Windows 95, but the
error probably would be present in any operating system, since it is
read from the disk.
From ATA-6 <<
6.2.1 Definitions and value ranges of IDENTIFY DEVICE words (see 8.12)

1) Words (61:60) shall contain the value one greater than the total number of
user-addressable

sectors in 28-bit addressing and shall not exceed 0FFFFFFFh. The content of
words (61:60) shall be greater than or equal to one and less than or equal to
268,435,455.

Yes, except that the value is the number of sectors, and not 1 more. I
guess it is correct elsewhere in the document.
2) Words (103:100) shall contain the value one greater than the total number
of user-addressable sectors in 48-bit addressing and shall not exceed
0000FFFFFFFFFFFFh.

Yes, but it is one greater than the maximum LBA address.
If you don't get any answers, join the T13 mail list and ask.

I can repeat the problem by running a certain peace of software, but
have not been able to reproduce it in other ways. It seems to be a
Seagate issue, but it may be possible that it only occurs when wrong
commands are sent to the disk.

The problem is that operating systems and software, which does not
recognize 48-bit addressing, may corrupt data if word 60-61 contains
an unexpected number.
 
This happens on power cycle but not reset? You are just booting to DOS?
I see the first output as an error. And the error did not disappear by
pressing the system reset button. Yes DOS, and Windows 95, but the
error probably would be present in any operating system, since it is
read from the disk.

Interesting and strange both. What does my DiskId32 utility
( http://www.winsim.com/diskid32/diskid32.html ) report in Windows 95 ?

Thanks,
Lynn McGuire
 
Interesting and strange both. What does my DiskId32 utility
( http://www.winsim.com/diskid32/diskid32.html ) report in Windows 95 ?

Thanks,
Lynn McGuire

The output from your program made me consider if I overlooked
something (more than piece spelling):


Secondary Controller - Master drive

Drive Model Number________________: ST3160023A
Drive Serial Number_______________:
Drive Controller Revision Number__: 3.06
Controller Buffer Size on Drive___: 8388608 bytes
Drive Type________________________: Fixed
Drive Size________________________: 137438953472 bytes


But then I took a two years old Findpart version, written before I
knew anything about 128 GB disks (in DOS):


Findpart, version 4.1.
Copyright Svend Olaf Mikkelsen, 2001.

IDE disks:

Secondary Master: ST3160023A
Sector 0: OK Megabytes: 152627
Sector 10000: OK Usersectors: 312581808
IDE CHS: 16383/16/63 CTM: 16383/16/63

From where would that Findpart version get the number 312581808?
 
Secondary Controller - Master drive

Drive Model Number________________: ST3160023A
Drive Serial Number_______________:
Drive Controller Revision Number__: 3.06
Controller Buffer Size on Drive___: 8388608 bytes
Drive Type________________________: Fixed
Drive Size________________________: 137438953472 bytes

Also, the correct answer would be 137438952960 bytes from FFFFFFFh
sectors.

The Seagate Drvinfo program version 1.1 from 1995 reports the disk as
312581808 logical blocks.
 
Drive Size________________________: 137438953472 bytes
Also, the correct answer would be 137438952960 bytes from FFFFFFFh
sectors.

The Seagate Drvinfo program version 1.1 from 1995 reports the disk as
312581808 logical blocks.

BTW, the source code to DiskId32 is up on that web page also.

Is the 48 bit LBA code not working correctly for your disk drive ?

// calculate size based on 28 bit or 48 bit addressing
// 48 bit addressing is reflected by bit 10 of word 83
if (diskdata [83] & 0x400)
sectors = diskdata [103] * 65536I64 * 65536I64 * 65536I64 +
diskdata [102] * 65536I64 * 65536I64 +
diskdata [101] * 65536I64 + diskdata [100];
else
sectors = diskdata [61] * 65536 + diskdata [60];
// there are 512 bytes in a sector
bytes = sectors * 512;
printf ("Drive Size________________________: %I64d bytes\n", bytes);

Thanks,
Lynn
 
Also, the correct answer would be 137438952960 bytes from FFFFFFFh
sectors.

The Seagate Drvinfo program version 1.1 from 1995 reports the disk as
312581808 logical blocks.

BTW, the source code to DiskId32 is up on that web page also.

Is the 48 bit LBA code not working correctly for your disk drive ?

// calculate size based on 28 bit or 48 bit addressing
// 48 bit addressing is reflected by bit 10 of word 83
if (diskdata [83] & 0x400)
sectors = diskdata [103] * 65536I64 * 65536I64 * 65536I64 +
diskdata [102] * 65536I64 * 65536I64 +
diskdata [101] * 65536I64 + diskdata [100];
else
sectors = diskdata [61] * 65536 + diskdata [60];
// there are 512 bytes in a sector
bytes = sectors * 512;
printf ("Drive Size________________________: %I64d bytes\n", bytes);

Thanks,
Lynn

I have a copy of the Identify buffer at the time your program was run,
and it turns out that the content of words 60-61 was 312581808, while
the content of words 100-103 was 268435456.

Meaning that the DiskId32 output was correct. When the problem is not
present, the DiskId32 output is also correct:

Secondary Controller - Master drive

Drive Model Number________________: ST3160023A
Drive Serial Number_______________:
Drive Controller Revision Number__: 3.06
Controller Buffer Size on Drive___: 8388608 bytes
Drive Type________________________: Fixed
Drive Size________________________: 160041885696 bytes
 
Back
Top