bug-grub
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

BIOS int13/48h does not return the right physical sector count...


From: Jean-Jacques Michel
Subject: BIOS int13/48h does not return the right physical sector count...
Date: Fri, 22 Mar 2002 09:39:22 +0100

Hi,

And thus, the "partnew" command returns a ERR_GEOM error when I try to
make a partition
that use the maximum real physical number of sectors on my disk...

Let's explain :

- if I look at the manufacturer's datasheet, I get 20015856 sectors !
- My Mandrake setup/partionning program is also using the correct amount
of sectors (20015856).
- the "geometry" command gives me a CHS of 1024/240/63 with 20003760
sectors, LBA
(which is correct, if you look at a fdisk output, I get 1323/240/63,
which gives
1323*240*63=20003760). The total_sectors count is given by int13/48h.

Here are my questions :
- Can you rely on the information given by int13/48h : it should be the
number of PHYSICAL sectors
on the disk, but it gives the number of sectors that you can access
using a CHS addressing scheme.
This is not very useful for LBA addressing.
- Where can you find a real value for the number of physical sectors,
accessible via LBA.
- Is it a problem with my BIOS, or is it a more general known bug.
- Do you think that "bios.c" should be patched to takes this into amount
(I made a test with a
diochotomic search of the latest good sector between drp.total_sectors &
(drp.sectors*drp.heads*(drp.cylinders+1))
and it is working).

I know that most of people won't bother about losing some sectors at the
end of a disk, but
it can represent up to (255*63)-1 sectors, thus up to 8MByte, unusable
by Grub "partnew".
(and any command that makes a test based on geom->total_sectors).


-- 
Jean-Jacques Michel mailto:address@hidden 
Hardware Engineer - Linbox http://www.linbox.com
TechnopĂ´le Metz 2000 - 152 rue de Grigy - 57070 Metz - France
Tel : +33 (0)3 87 75 55 21 - Fax : +33 (0)3 87 75 19 26



reply via email to

[Prev in Thread] Current Thread [Next in Thread]