grub-devel
[Top][All Lists]
Advanced

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

Re: Replacing the legacy "map" command


From: Urja Rannikko
Subject: Re: Replacing the legacy "map" command
Date: Tue, 27 May 2008 19:15:09 +0300

>
> By the way, I can imagine that some kernels not loaded with
> "chainloader" may benefit from the remapping as well.
>
> Again, I'd like to see the command name shortened, perhaps to "drivemap"
> or "map".  It's not like users will need to distinguish BIOS and
> non-BIOS mappings.
>

[/lurkermode]

Since the mapping (internally) works on bios drive numbers, the
simplest syntax i think of would be
map [oldhex newhex] ...
eg. map 0x81 0x80 0x80 0x81
would swap the first two drives.

For grub, i'd suggest
map [olddrive newdrive] ...
eg. map (hd1) (hd0) (hd0) (hd1)

I don't know whether the brevity of this format is very user friendly,
but it would work very well for me

The map command would just store the given parameters (converted to
bios hex drive numbers) to a table/array.
When the boot command is issued, grub would install an int 0x13
handler that uses this data as an lookup table
to convert requests and "forward" them to the original int 0x13 handler.


[lurkermode]

-- 
urjaman




reply via email to

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