[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [microblaze-uclinux] Note to bootloader developers
Hi Yashi,
Yasushi SHOJI wrote:
>>A note to the developers of these bootloaders, if you wish to add kernel
>>command line support, it's easy. When you jump to the kernel start
>>address, just have r5 contain the address of a null-terminated string
>>that is the kernel command line. This string could live anywhere -
>>BRAM, flash, doesn't matter. The kernel copies it away safely very early
>>in the piece, so you don't need to worry about it getting corrupted.
>
> I have to object on this.
>
> so as I (as a programmer working on microblaze port; not as an
> employee of Atmark Techno) am an embedded system programmer, what we
> need are:
>
> 1. standard tag based kernel paramter passing scheme
> 2. compile time parter passing scheme
> 3. (if any one needs it) current string based simple parameter scheme.
>
> comments welcome!
Feel free to object, and to implement the tag based scheme! :) I'll
freely admit that the current approach was a quick hack by myself and
Brett to get some form of command line params into the kernel.
Necessity is the mother of invention and all that.
However, from what I saw in the source, basically all the kernel expects
ultimately is a pointer to a string that it later parses. So, is your
objection just the simplistic mechanism for forming that string (ie a
bootloader issue)? Or is it something deeper than that, that would go
into setup_arch()?
From linux-2.4.x/init/main.c:
asmlinkage void __init start_kernel(void)
{
char * command_line;
extern char saved_command_line[];
...
setup_arch(&command_line);
printk("Kernel command line: %s\n", saved_command_line);
parse_options(command_line);
Regards,
John
___________________________
microblaze-uclinux mailing list
microblaze-uclinux@itee.uq.edu.au
Project Home Page : http://www.itee.uq.edu.au/~jwilliams/mblaze-uclinux
Mailing List Archive : http://www.itee.uq.edu.au/~listarch/microblaze-uclinux/