From: Robert Millan <r...@aybabtu.com> Date: Sun, 15 Mar 2009 16:45:31 +0100
> It's not an absolute must that device names are unique. You can still > identify partitions by their filesystem UUID or label, and in fact this > is what our default scripts (grub-mkconfig) do anyway. Things like UUID and labels are not an option for the 512-byte boot block where I have to know the exact OBP path of the boot device, and this is what the GRUB kernel fetches from the 'bootpath' environment variable to compose the root device and path. So the point is that we need this information anyways. > Making GRUB specify partitions differently depending on the platform we're > on seems troublesome, specially if we end up with such long an ugly names. If there are commas in the openfirmware paths, which there are, there are only two ways to resolve the conflict between how GRUB uses comma characters (to delimit partition specifications) and how the firmware uses them: 1) My suggestion, which is to use ":" on openfirmware platforms. To me this is the best because people using openfirmware platforms are familiar with this syntax. We gain nothing by giving them something else to learn, on top of openfirmware path naming, just for the sake of GRUB. 2) Munge the openfirmware path back and forth, for example changing the openfirmware "," characters into something else. We'd need to do this back and forth, as device paths go in and out of GRUB's realm. I don't really think that is maintainable. > If we really need this, can't we just assign names dynamically like > hd0, hd1, etc, and keep a memory structure that matches them with the > actual OFW device? I need the fully expanded path for things like the boot block anyways. Here is the devicemap file on my workstation: (/p...@1e,600000/p...@0/p...@9/p...@0/s...@1/d...@0) /dev/sda (/p...@1e,600000/p...@0/p...@9/p...@0/s...@1/d...@1) /dev/sdb And that looks just fine to me. We could enhance this (and I planned on implementing this) by using the shorter devalias names which match the above paths. _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel