[Prev][Next][Index][Thread]
Re: help me please,thanks in advance.
> From: "lawranceyang" <lawranceyang@263.net>
> Subject: help me please,thanks in advance.
> Date: Mon, 30 Apr 2001 22:54:31 +0800 (CST)
> 
>   i attempt to use fsbmodmount ,a example kernel.
>   i do some change with the source code fsbmodmount.c,
>      as follow:
>            #define DISK_NAME	"hda"
>            #define PARTITION_NAME "/dev/hda7"
>   but when i run the kernel, it always warn me that "no such partition".(
>   the hda7 is realy my ex2 partition.).
The fsbmodmount example kernel uses the netbsd/freebsd filesystem code.
When you try to mount an ext2 filesystem, it fails. If you want to use
an ext2 filesystem, you need to replace the call to start_fs(). At the
moment, no one has contributed a version of start_linux_fs(), so you will
have to take a look at startup/start_fs.c and modify that to use the linux
FS code.
Also, your spec for the PARTITION_NAME above is wrong. Should be something 
like this for a BSD disk.
            #define DISK_NAME	   "hda7"
            #define PARTITION_NAME "a"
where "a" is the partition part. For your linux disk, the PARTITION_NAME is
probably null though. 
>   i also find the getenv("DISK") and getenv("PARTITION") return a null
>   value.i'm totally confused.
I refer you to:
   http://www.cs.utah.edu/flux/oskit/html/oskit-wwwch1.html#x4-120001.6
Environment variables in the example kernels are specified on the command
line. The multiboot startup code turns those specifications into C style
environ vars. For example:
	fsbmodmount DISK=hda7 PARTITION=a -- <other args>
Lbs
----------------------------------------
Leigh B. Stoller
University of Utah - Flux Research Group
http://www.cs.utah.edu/~stoller
----------------------------------------
References: