linux-mips
[Top] [All Lists]

Re: Boot flags in the kernel.

To: Alex deVries <adevries@engsoc.carleton.ca>
Subject: Re: Boot flags in the kernel.
From: "William J. Earl" <wje@fir.engr.sgi.com>
Date: Mon, 26 Jan 1998 09:36:43 -0800
Cc: SGI Linux <linux@cthulhu.engr.sgi.com>
In-reply-to: <Pine.LNX.3.95.980126004413.18537A-100000@lager.engsoc.carleton.ca>
References: <Pine.LNX.3.95.980126004413.18537A-100000@lager.engsoc.carleton.ca>
Sender: owner-linux@cthulhu.engr.sgi.com
Alex deVries writes:
 > 
 > I'm not sure if what I'm trying to do is possible. I'm trying to implement
 > the same rootflags that are passwd within the kernel image in i386 into
 > the MIPS kernel. 
 > 
 > In i386 there's a portion of the boot image reserved for these flags;
 > they're things like console type, initial filesystem, initial ramdisk
 > location, etc.  
 > 
 > It's traditionally been more important to have this feature in i386
 > because there wasn't anything nice like the PROMs on MIPS or Sparcs.
 > 
 > But, there _is a good reason to have it; for install or rescue images it's
 > nice to be able to boot with compressed initial ramdisk within the same
 > boot image without having to pass the ramdisk offset on command line
 > manually.
 > 
 > Where in the kernel would we put this data?

       I am sure where you should put it, but bear in mind that the
command line options and environment are passed to the kernel much as
if it were a user main program (as argc, argv, and envp, in $a0, $a1,
and $a2), by sash or the PROM.  You can get things like the console
variable that way (console=g means textport and console=d means
serial console). 


<Prev in Thread] Current Thread [Next in Thread>