Hi, 2011/6/23 Vladimir 'φ-coder/phcoder' Serbinenko <phco...@gmail.com>: >> As an OS developer enthusiastic, I needed to load a file to memory at >> a given specific address. > While such a functionality would be a toy for loader developpers, it's > completely useless for the end users. If the user has to know any single > address or any single address figures in grub.cfg it's automatically a > bad design. Also while it would be possible to write a loader in scripts > using such kind of commands it's simply a wrong place for it. Loaders > have to be written in C. Also people who really need such kind of > functionality (devs) can quickly add such a kludge to the loader they > are currently developping. As for the user the syntax has to be sth like > loader_name <file> <args> > This allows for a much higher flexibility, portability and future-proof.
Ok, I understand your point regarding end-users (which have absolutely no need for this kind of module). My use of it is not to write a loader in script: this module is my loader in its own right. For now, I'm using it to load my kernel at 1MB and use a chainloader of mine to jump to it (and do some other things before). But I agree it'd be better to wrap everything into a single loader command. >> No command in grub 1.99 was fitting my needs (as my file as no >> semantic known to grub: it's not a module, it's not an initrd, it's >> not a multiboot kernel either), so I developed my own module. >> > What is it then? I'm willing to consider adding new loading as long as > they are sane and make sense. Basically, I wanted to have a small chainloader of mine to load my kernel. IIRC, I cannot use both the 'kernel' and 'chainloader' commands together, so I just skipped using a multiboot compliant kernel and have the chainloader to jump at a given address (1MB). This module is only intended to load the kernel at this expected address, so I only rely on the 'chainloader' command. But again, I'll try to make the whole thing a clean loader. If I come up with such a loader, do you consider it could be eligible for inclusion in grub ? Maybe maintaining the loaders for all the kernel formats of hobbyist like me is not what you wish for... Anyway, thanks for your lights, -- pini _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org https://lists.gnu.org/mailman/listinfo/grub-devel