[<prev] [next>] [day] [month] [year] [list]
Message-ID: <CAJxxZ0NNb6981fpLyiH97Q3Y6ucWm=XB5-MmMRnBCr-dmQrpyw@mail.gmail.com>
Date: Fri, 2 Mar 2012 18:53:23 +0800
From: Sonic Zhang <sonic.adi@...il.com>
To: Linux Kernel <linux-kernel@...r.kernel.org>,
initramfs@...r.kernel.org
Subject: Fail to mount a ext2 partition /dev/mmcblk0p1 on SD card as root file
system in kernel 3.2
Hi,
Kernel 3.2 panic when I mount a ext2 partition /dev/mmcblk0p1 on SD
card as root file system.
My boot parameter line is "root=/dev/mmcblk0p1 rw rootwait
earlyprintk=serial,uart0,57600 console=ttyBF0,57600".
After reading init/do_mounts.c a bit, I find VFS folders "/dev" and
"/root" don't exist when mount_root() tries to create block device
node "/dev/root" and mount this device at path "/root". If I create
these folders by mkdir() before line create_dev() in function
mount_root(), kernel boots up on SD card properly.
Where should folders "/dev" and "/root" be created? Any hint?
Thanks
void __init mount_root(void)
{
.......
#ifdef CONFIG_BLOCK
create_dev("/dev/root", ROOT_DEV);
mount_block_root("/dev/root", root_mountflags);
#endif
}
static int __init do_mount_root(char *name, char *fs, int flags, void *data)
{
int err = sys_mount(name, "/root", fs, flags, data);
if (err)
return err;
......
}
Sonic Zhang
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists