[prev in list] [next in list] [prev in thread] [next in thread]
List: busybox
Subject: Re: [BusyBox] still fighting with minit
From: Glenn McGrath <bug1 () iinet ! net ! au>
Date: 2004-03-25 12:47:09
Message-ID: 20040325234709.21805817.bug1 () iinet ! net ! au
[Download RAW message or body]
On Thu, 25 Mar 2004 06:04:26 -0500 (EST)
"Robert P. J. Day" <rpjday@mindspring.com> wrote:
> a glance, i'm assuming that this is what i should have noticed.
> in the current (2.4.22) version of our kernel, in init/main.c, i see
> the code:
>
> static char * argv_init[MAX_INIT_ARGS+2] = { "init", NULL, };
> ...
> if (execute_command)
> execve(execute_command,argv_init,envp_init);
> execve("/sbin/init",argv_init,envp_init);
> execve("/etc/init",argv_init,envp_init);
> execve("/bin/init",argv_init,envp_init);
> execve("/bin/sh",argv_init,envp_init);
> panic("No init found. Try passing init= option to kernel.");
>
> and in the 2.6 code in that same file, i find:
>
> static void run_init_process(char *init_filename)
> {
> argv_init[0] = init_filename;
> execve(init_filename, argv_init, envp_init);
> }
> ...
>
> if (execute_command)
> run_init_process(execute_command);
>
> run_init_process("/sbin/init");
> run_init_process("/etc/init");
> run_init_process("/bin/init");
> run_init_process("/bin/sh");
>
> panic("No init found. Try passing init= option to kernel.");
>
> which, to my untrained eye, seems to solve that particular problem.
> is this what you were referring to? again, thanks for your time.
Yes, thats it, run_init_process sets argv[0] properly.
Glenn
_______________________________________________
busybox mailing list
busybox@mail.busybox.net
http://codepoet.org/mailman/listinfo/busybox
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic