本系列文章有本人yinjiabin制作,转载请注明出处:
step1:用tftp下载编译好的内核
tftp 通过网络下载文件
注意:使用tftp,需要先配置好网络
setenv serverip 192.168.1.100 (tftp服务器的地址)
tftp c0008000 uImage //把server(IP=环境变量中设置的serverip)中tftp服务目录 (我的是tftpboot)下的uImage通过TFTP读入到0xc0008000(内存地址)处
step2: 加载内核
bootm c0008000 //执行内存c0008000中的二进制代码
setp3:内核运行结果
mmc0: SDHCI controller on samsung-hsmmc [s3c-sdhci.0] using ADMA
s3c-sdhci s3c-sdhci.1: clock source 0: hsmmc (133000000 Hz)
s3c-sdhci s3c-sdhci.1: clock source 1: hsmmc (133000000 Hz)
s3c-sdhci s3c-sdhci.1: clock source 2: mmc_bus (24000000 Hz)
enter s3c64xx_setup_sdhci1_cfg_gpio
s3c6400_setup_sdhci_cfg_card: CTRL 2=c0004120, 3=80808080
mmc1: SDHCI controller on samsung-hsmmc [s3c-sdhci.1] using ADMA
usbcore: registered new interface driver usbhid
usbhid: USB HID core driver
asoc: AC97 HiFi <-> s3c-ac97 mapping ok
s3c6400_setup_sdhci_cfg_card: CTRL 2=c0004100, 3=00008080
mmc0: new high speed SDHC card at address 1234
mmcblk0: mmc0:1234 SA04G 3.65 GiB
mmcblk0: p1
s3c6400_setup_sdhci_cfg_card: CTRL 2=c0004120, 3=80808080
ALSA device list:
#0: SMDK (WM9713)
TCP cubic registered
lib80211: common routines for IEEE802.11 drivers
Registering the dns_resolver key type
s3c-rtc s3c64xx-rtc: setting system clock to 2000-10-30 06:50:40 UTC (972888640)
VFS: Cannot open root device "ubi0:FriendlyARM-root" or unknown-block(0,0)
Please append a correct "root=" boot option; here are the available partitions:
1f00 512 mtdblock0 (driver?)
1f01 5120 mtdblock1 (driver?)
1f02 2091520 mtdblock2 (driver?)
b300 3829760 mmcblk0 driver: mmcblk
b301 3825664 mmcblk0p1
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
[<c00368cc>] (unwind_backtrace+0x0/0xf4) from [<c049a85c>] (dump_stack+0x18/0x1)
[<c049a85c>] (dump_stack+0x18/0x1c) from [<c049a8c4>] (panic+0x64/0x188)
[<c049a8c4>] (panic+0x64/0x188) from [<c0009024>] (mount_block_root+0x174/0x244)
[<c0009024>] (mount_block_root+0x174/0x244) from [<c0009284>] (prepare_namespac)
[<c0009284>] (prepare_namespace+0x94/0x198) from [<c0008c5c>] (kernel_init+0x11)
[<c0008c5c>] (kernel_init+0x114/0x154) from [<c0031a3c>] (kernel_thread_exit+0x)
step 4: 解决VFS: Cannot open root device "ubi0:FriendlyARM-root" or unknown-block(0,0)的方法
进入linux2.6.36内核
s3c6400-uart.0: s3c2410_serial0 at MMIO 0x7f005000 (irq = 16) is a S3C6400/10
s3c6400-uart.1: s3c2410_serial1 at MMIO 0x7f005400 (irq = 20) is a S3C6400/10
s3c6400-uart.2: s3c2410_serial2 at MMIO 0x7f005800 (irq = 24) is a S3C6400/10
s3c6400-uart.3: s3c2410_serial3 at MMIO 0x7f005c00 (irq = 28) is a S3C6400/10
S3C NAND Driver, (c) 2008 Samsung Electronics
S3C NAND Driver is using hardware ECC.
NAND device: Manufacturer ID: 0xec, Chip ID: 0xd5 (Samsung NAND 2GiB 3,3V 8-bit)
Creating 3 MTD partitions on "NAND 2GiB 3,3V 8-bit":
0x000000000000-0x000000080000 : "Bootloader"
0x000000080000-0x000000580000 : "Kernel"
0x000000580000-0x000080000000 : "File System"
PPP generic driver version 2.4.2
....... ....... ........ ........
VFS: Cannot open root device "ubi0:FriendlyARM-root" or unknown-block(0,0)
Please append a correct "root=" boot option; here are the available partitions:
1f00 512 mtdblock0 (driver?)
1f01 5120 mtdblock1 (driver?)
1f02 2091520 mtdblock2 (driver?)
b300 3829760 mmcblk0 driver: mmcblk
b301 3825664 mmcblk0p1
Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
[<c00368cc>] (unwind_backtrace+0x0/0xf4) from [<c049a85c>] (dump_stack+0x18/0x1)
[<c049a85c>] (dump_stack+0x18/0x1c) from [<c049a8c4>] (panic+0x64/0x188)
[<c049a8c4>] (panic+0x64/0x188) from [<c0009024>] (mount_block_root+0x174/0x244)
[<c0009024>] (mount_block_root+0x174/0x244) from [<c0009284>] (prepare_namespac)
[<c0009284>] (prepare_namespace+0x94/0x198) from [<c0008c5c>] (kernel_init+0x11)
[<c0008c5c>] (kernel_init+0x114/0x154) from [<c0031a3c>] (kernel_thread_exit+0x)
5)添加对UBIFS文件系统的支持
由IBM、nokia工程师Thomas Gleixner,Artem Bityutskiy等人于2006年发起,致力于开发性能卓越、扩展性高的FLASH专用文件系统,以解决当前嵌入式环境下以FLASH作为MTD设备使用时的技术瓶颈。
第二、为何使用ubifs?
第三、如何得到ubifs?
2.6.22以后,ubifs活跃于git管理工程中:
git://git.infradead.org/ubi-2.6.git
2.6.27以后,ubifs被整合进内核树中,用户只需下载最新内核即可获取ubifs支持。
第四、如何使用ubifs?。