lkml.org 
[lkml]   [2006]   [Feb]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: RFC: disk geometry via sysfs
Seewer Philippe wrote:
>
> IDE tries to return the actual hardware geometry. Most other drivers
> implement a "fake". Or try to guess the geometry from the MBR...
>

But there is no "actual hardware geometry". IDE disks can report a
geometry, but that is no more real than any other made up geometry. If
you take the geometry that the disk itself reports and write that to the
MBR, then software that actually uses the geometry ( i.e. non LBA boot
loaders ) will fail because it is not the geometry that the bios uses.

The only remaining purpose to geometry values that I see is to store in
the MBR for non LBA boot loaders to use. Since they must have the
values the bios uses, then you need to get the values from the bios when
creating such an MBR.

> My personal answer is here: Because there are so many tools around which
> use the kernel values, that it is easier to overwrite the kernel than
> patch all other software... (i know, i know...)

The only tools that I am aware of are boot loaders and disk
partitioners, and these tools do not need the geometry, they just try to
get it to maintain compatibility with ancient systems. As such, it is
long past time for them to no longer require this information.

>
> And additionally: When partitioning its sometimes necessary or safer to
> write a whole new mbr (dd if=... of=... ; parted mklabel msdos). When
> dd'ing the mbr goes away. And some drivers return geometry based on the
> mbr...... So overwriting these values might come handy.
>

But what would you overwrite them with? The only values that have any
actual use are the ones from the bios. If you get the values from the
bios, it makes no sense to change them later.

-
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/

\
 
 \ /
  Last update: 2006-02-14 19:22    [W:0.073 / U:3.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site