[PATCH] - allow specification of alternate inittab files
B Thomas
bjthomas3 at gmail.com
Wed Nov 1 07:08:05 PST 2006
Yeah... that was stupid. Let's try again with a much smaller, much improved
version. Thanks for pointing out the obvious silliness in the original
patch.
-b
On 10/31/06, B Thomas <bjthomas3 at gmail.com> wrote:
>
> Hey, you're probably correct. It was a long, twisty path before I got to
> the final patch including many detours and changes of direction. Let me
> rework it with the environment variables and resubmit.
>
> Thanks,
> -b
>
>
> On 10/31/06, Denis Vlasenko <vda.linux at googlemail.com> wrote:
> >
> > On Tuesday 31 October 2006 23:22, B Thomas wrote:
> > > Hi,
> > >
> > > There are circumstances in which it would be great to allow the
> > selection of
> > > different inittab file at boot time. This patch adds the ability to
> > select
> > > the inittab file via a command line option (bb_inittab).
> > >
> > > One of the things that I don't like about this patch is the need to
> > mount
> > > /proc on systems in which it isn't mounted. The mount is cleaned up
> > and
> > > handled carefully; I just don't like having to do it. Having said
> > that,
> > > this patch has proven to be quite useful.
> > >
> > > Signed-off-by: Ben Thomas (ben at virtualiron.com )
> >
> > I thought that all unrecognized kernel params are passed in the
> > environment
> > to init: kernel tree, init/main.c:
> >
> > /*
> > * Unknown boot options get handed to init, unless they look like
> > * failed parameters
> > */
> > static int __init unknown_bootoption(char *param, char *val)
> > {
> > ....
> > if (val) {
> > /* Environment option */
> > unsigned int i;
> > for (i > > if (i = MAX_INIT_ENVS) {
> > panic_later > > `%s'";
> > panic_param > > }
> > if (!strncmp(param, envp_init[i], val - param))
> > break;
> > }
> > ....
> >
> > So you do not need to parse /proc/commandline
> > --
> > vda
> >
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://busybox.net/lists/busybox/attachments/20061101/d0113ffc/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bbinit.patch
Type: text/x-patch
Size: 891 bytes
Desc: not available
Url : http://busybox.net/lists/busybox/attachments/20061101/d0113ffc/attachment.bin
More information about the busybox
mailing list