lkml.org 
[lkml]   [1999]   [Mar]   [26]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Problem with larger IDE drive

Andries.Brouwer@cwi.nl writes:

> The most difficult problem is finding the correspondence between the
> BIOS disks 0x80, 0x81, ... and the Linux disks /dev/sda, /dev/hda, ...

This is impossible without writing to the disk, but you can do a very
good job. Use the BIOS to read the first sector of every disk, and
supply userspace with the sectors via the proc filesystem.

So you might have a 512-byte file like this:
/proc/biosinfo/disks/0x80/bootsect.bin

Userspace just compares that with /dev/hda, etc. Userspace should be
able to change the data too, to match any changes to /dev/hda, etc.

Boot sectors should have a unique ID, and they usually differ by
boot code and partition data. In the unlikely event that all of
that is the same (someone used dd), you could take a guess or just
ask the user.

(and offer to add a unique ID if one is missing or not unique)

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:51    [W:3.597 / U:0.096 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site