万博网页版登陆页派论坛

QQ登录

只需一步,快速开始

查看: 3268|回复: 0
收起左侧

pcDuino的linux移植三

[复制链接]
发表于 2013-5-18 23:43:38 | 显示全部楼层 |阅读模式
[p=26, null, left][color=#333333][font=Arial]pcduino的linux移植二内核是启动了,但是还存在问题,先分析启动信息,再移植根文件系统[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]问题一:** Unable to read "uEnv.txt" from mmc 0:1 **[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]部分启动信息:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]reading uEnv.txt[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]** Unable to read "uEnv.txt" from mmc 0:1 **
Loading file "uEnv.txt" from mmc device 0:1[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]很明显找不到uEnv.txt,uEnv.txt是设置启动参数的,生成过程boot.cmd——>boot.src——>uEnv.txt[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]1.创建boot.cmd设置启动参数。boot.cmd:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]setenv bootargs console=ttyS0,115200 noinitrd root=/dev/mmcblk0p2 init=/sbin/init rootwait panic=10 ${extra}
fatload mmc 0 0x43000000 boot/script.bin
fatload mmc 0 0x48000000 boot/uImage
bootm 0x48000000[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]2.根据boot.cmd生成u-boot能够读取的boot.src文件[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]mkimage -C none -A arm -T script -d boot.cmd boot.scr[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]3.据说老版本的u-boot能读取boot.scr,新版本的不能直接读取。为了验证这个,我先只用boot.scr,不行再通过uEnv.txt读取boot.scr:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]bootenv=boot.scr
loaduimage=fatload mmc ${mmcdev} ${loadaddr} ${bootenv}
mmcboot=echo Running boot.scr script from mmc ...; source ${loadaddr}[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]4.烧写实验[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]直接用boot.scr:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] vim boot.cmd[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]setenv bootargs console=ttyS0,115200 noinitrd root=/dev/mmcblk0p2 init=/sbin/init rootwait panic=10 ${extra}
fatload mmc 0 0x43000000 boot/script.bin
fatload mmc 0 0x48000000 boot/uImage
bootm 0x48000000[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]保存退出[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] mkimage -C none -A arm -T script -d boot.cmd boot.scr
Image Name:   
Created:      Sat Apr 20 21:41:43 2013
Image Type:   ARM Linux Script (uncompressed)
Data Size:    225 Bytes = 0.22 kB = 0.00 MB
Load Address: 00000000
Entry Point:  00000000
Contents:
   Image 0: 217 Bytes = 0.21 kB = 0.00 MB[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]若干这里mkimage报错或移植二中make uImage报错,需要将编译u-boot是生成的tools目录下的mkimage拷贝到/usr/local/bin,即可解决问题[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] sudo mount /dev/sdb1 /mnt/
[sudo] password for change:
[url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] cp boot.scr /mnt/[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]放到pcduino tf卡槽,设置串口 115200 8 n 1启动信息还是[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]U-Boot SPL 2012.10 (Apr 19 2013 - 18:46:44)
DRAM: 1024MB
SUNXI SD/MMC: 0[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]
U-Boot 2012.10 (Apr 19 2013 - 18:46:44) Allwinner Technology[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]CPU:   SUNXI Family
Board: pcDuino
I2C:   ready
DRAM:  1 GiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]In:    serial
Out:   serial
Err:   serial
Hit any key to stop autoboot:  0
reading uEnv.txt[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]** Unable to read "uEnv.txt" from mmc 0:1 **
Loading file "uEnv.txt" from mmc device 0:1
Failed to mount ext2 filesystem...
** Bad ext2 partition or disk - mmc 0:1 **
ext2load - load binary file from a Ext2 filesystem[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]看来还是得用uEnv.txt读取boot.scr[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] vim uEnv.txt[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]bootenv=boot.scr
loaduimage=fatload mmc ${mmcdev} ${loadaddr} ${bootenv}
mmcboot=echo Running boot.scr script from mmc ...; source ${loadaddr}[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]保存,退出,tf卡插到UBUNTU变/dev/sdc[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] sudo mount /dev/sdc1 /mnt/
[url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] cp uEnv.txt /mnt/
[url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] sudo umount /dev/sdc1 /mnt/
umount: /mnt: not mounted[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]tf卡插到pcduino卡槽,连接串口设置115200 8 n 1,启动信息如下:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]U-Boot 2012.10 (Apr 19 2013 - 18:46:44) Allwinner Technology[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]CPU:   SUNXI Family
Board: pcDuino
I2C:   ready
DRAM:  1 GiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]In:    serial
Out:   serial
Err:   serial
Hit any key to stop autoboot:  0
reading uEnv.txt[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]144 bytes read
Loaded environment from uEnv.txt
reading boot.scr[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]289 bytes read
Jumping to boot.scr
## Executing script at 44000000
Wrong image format for "source" command
reading script.bin[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]44900 bytes read
reading uImage[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]4693132 bytes read
## Booting kernel from Legacy Image at 48000000 ...
   Image Name:   Linux-3.0.62
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4693068 Bytes = 4.5 MiB
   Load Address: 40008000
   Entry Point:  40008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]Starting kernel ...[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]<6>Initializing cgroup subsys cpuset
<5>Linux version 3.0.62 ([url=mailto:change@change]change@change[/url]) (gcc version 4.4.1 (Sourcery G++ Lite 2009q3-67) ) #1 PREEMPT Sat Apr 20 18:32:39 CST 2013
CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: sun4i
<6>Memory cut off:
<6>     MALI : 0x5c000000 - 0x5fffffff  (  64 MB)
<4>Ignoring unrecognised tag 0x00000000
<6>Memory Reserved:
<6>     SYS  : 0x43000000 - 0x4300ffff  (  64 kB)
<6>     VE   : 0x44000000 - 0x48ffffff  (  80 MB)
<6>     G2D  : 0x49000000 - 0x49ffffff  (  16 MB)
<6>     LCD  : 0x5a000000 - 0x5bffffff  (  32 MB)
Memory policy: ECC disabled, Data cache writeback
<6>chip-id: A10 (AW1623 revision C)
<7>On node 0 totalpages: 245760
<7>free_area_init_node: node 0, pgdat c0887ea0, node_mem_map c094e000
<7>  Normal zone: 1280 pages used for memmap
<7>  Normal zone: 0 pages reserved
<7>  Normal zone: 146176 pages, LIFO batch:31
<7>  HighMem zone: 768 pages used for memmap
<7>  HighMem zone: 97536 pages, LIFO batch:31
<7>pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
<7>pcpu-alloc: [0] 0
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 243712
<5>Kernel command line: console=ttyS0,115200 root=/dev/mmcblk0p2 rootwait loglevel=8 panic=10
<6>PID hash table entries: 4096 (order: 2, 16384 bytes)
<6>Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
<6>Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
<6>Memory: 448MB 512MB = 960MB total
<5>Memory: 833852k/833852k available, 149188k reserved, 393216K highmem
<5>Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)[/font][/color][/p][p=26, null, left][color=#333333][font=Arial].........太长了此处省略若干,通过上面的启动信息发现uEnv.txt读取正常[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]<0>Kernel panic - not syncing: Attempted to kill init!
[    2.650000] Kernel panic - not syncing: Attempted to kill init!
[<c003e92c>] (unwind_backtrace+0x0/0x13c) from [<c05fa2ac>] (panic+0x74/0x188)
[    2.660000] [<c003e92c>] (unwind_backtrace+0x0/0x13c) from [<c05fa2ac>] (panic+0x74/0x188)
[<c05fa2ac>] (panic+0x74/0x188) from [<c006bfd0>] (do_exit+0x6c4/0x788)
[    2.670000] [<c05fa2ac>] (panic+0x74/0x188) from [<c006bfd0>] (do_exit+0x6c4/0x788)
[<c006bfd0>] (do_exit+0x6c4/0x788) from [<c003c87c>] (die+0x288/0x300)
[    2.690000] [<c006bfd0>] (do_exit+0x6c4/0x788) from [<c003c87c>] (die+0x288/0x300)
[<c003c87c>] (die+0x288/0x300) from [<c0042cb0>] (__do_kernel_fault+0x74/0x84)
[    2.700000] [<c003c87c>] (die+0x288/0x300) from [<c0042cb0>] (__do_kernel_fault+0x74/0x84)
[<c0042cb0>] (__do_kernel_fault+0x74/0x84) from [<c0042e40>] (do_page_fault+0x180/0x2e4)
[    2.720000] [<c0042cb0>] (__do_kernel_fault+0x74/0x84) from [<c0042e40>] (do_page_fault+0x180/0x2e4)
[<c0042e40>] (do_page_fault+0x180/0x2e4) from [<c00312b4>] (do_DataAbort+0x34/0x98)
[    2.730000] [<c0042e40>] (do_page_fault+0x180/0x2e4) from [<c00312b4>] (do_DataAbort+0x34/0x98)
[<c00312b4>] (do_DataAbort+0x34/0x98) from [<c0037dd0>] (__dabt_svc+0x70/0xa0)
[    2.750000] [<c00312b4>] (do_DataAbort+0x34/0x98) from [<c0037dd0>] (__dabt_svc+0x70/0xa0)
Exception stack(0xe783bee8 to 0xe783bf30)
[    2.770000] Exception stack(0xe783bee8 to 0xe783bf30)
bee0:                   29c5c734 00000000 1137666c f1c20800 00000001 55866a9a
[    2.780000] bee0:                   29c5c734 00000000 1137666c f1c20800 00000001 55866a9a
bf00: c0039358 00000000 00000001 6239831b c0944588 11376664 1137665c e783bf30
[    2.790000] bf00: c0039358 00000000 00000001 6239831b c0944588 11376664 1137665c e783bf30
bf20: f8a905a8 c0059aac 20000013 ffffffff
[    2.810000] bf20: f8a905a8 c0059aac 20000013 ffffffff
[<c0037dd0>] (__dabt_svc+0x70/0xa0) from [<c0059aac>] (sunxi_gpio_request_array+0x160/0x540)
[    2.810000] [<c0037dd0>] (__dabt_svc+0x70/0xa0) from [<c0059aac>] (sunxi_gpio_request_array+0x160/0x540)
[<c0059aac>] (sunxi_gpio_request_array+0x160/0x540) from [<c040b868>] (alloc_pin+0xc/0x60)
[    2.830000] [<c0059aac>] (sunxi_gpio_request_array+0x160/0x540) from [<c040b868>] (alloc_pin+0xc/0x60)
[<c040b868>] (alloc_pin+0xc/0x60) from [<c00209cc>] (sw_hci_sunxi_init+0x3c/0x144)
[    2.850000] [<c040b868>] (alloc_pin+0xc/0x60) from [<c00209cc>] (sw_hci_sunxi_init+0x3c/0x144)
[<c00209cc>] (sw_hci_sunxi_init+0x3c/0x144) from [<c0031378>] (do_one_initcall+0x34/0x180)
[    2.860000] [<c00209cc>] (sw_hci_sunxi_init+0x3c/0x144) from [<c0031378>] (do_one_initcall+0x34/0x180)
[<c0031378>] (do_one_initcall+0x34/0x180) from [<c00084d4>] (kernel_init+0x108/0x194)
[    2.880000] [<c0031378>] (do_one_initcall+0x34/0x180) from [<c00084d4>] (kernel_init+0x108/0x194)
[<c00084d4>] (kernel_init+0x108/0x194) from [<c0039358>] (kernel_thread_exit+0x0/0x8)
[    2.900000] [<c00084d4>] (kernel_init+0x108/0x194) from [<c0039358>] (kernel_thread_exit+0x0/0x8)
<0>Rebooting in 10 seconds..[    2.920000] Rebooting in 10 seconds..[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]这下内核启动算成功了,由于还没有文件系统,找不到进程init,故kill init[/font][/color][/p]
[p=26, null, left][color=#333333][font=Arial]问题二:<0>Kernel panic - not syncing: Attempted to kill init![/font][/color][/p][p=26, null, left][color=#333333][font=Arial]上面分析了,其实就是找不到init进程,而文件系统提供这些进程。先写到这,明天开始移植文件系统[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]下面开始移植根文件系统:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] mkdir rootfs[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]1.编译、安装busybox[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]获取busybox源码[url=http://www.busybox.net/]http://www.busybox.net/[/url]  点击[url=http://busybox.net/downloads/busybox-1.21.0.tar.bz2]BusyBox 1.21.0[/url]下载源码,解压到工作目录并进入该目录[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/busybox-1.21.0$]change@change:~/Si/A10/pcduino/busybox-1.21.0$[/url] make menuconfig[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]先采用默认配置,不行回来再改。回来把builid option 把 Build BusyBox as a static binary (no shared libs) 把这个选上[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/busybox-1.21.0$]change@change:~/Si/A10/pcduino/busybox-1.21.0$[/url] vim Makefile[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]修改:[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]164:CROSS_COMPILE ?= arm-none-linux-gnueabi-[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]190:ARCH ?= arm[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]保存退出,开始编译[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/busybox-1.21.0$]change@change:~/Si/A10/pcduino/busybox-1.21.0$[/url] make[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]........//过程有点长,省略若干[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]  AR      util-linux/volume_id/lib.a
  LINK    busybox_unstripped
Trying libraries: crypt m
Library crypt is not needed, excluding it
Library m is needed, can't exclude it (yet)
Final link with: m
  DOC     busybox.pod
  DOC     BusyBox.txt
  DOC     busybox.1
  DOC     BusyBox.html[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]编译结束,开始安装到指定目录[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/busybox-1.21.0$]change@change:~/Si/A10/pcduino/busybox-1.21.0$[/url] make CONFIG_PREFIX=../rootfs install[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]--------------------------------------------------
You will probably need to make your busybox binary
setuid root to ensure all configured applets will
work properly.
--------------------------------------------------
安装过程完成,安装在上面新建的rootfs目录[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/busybox-1.21.0$]change@change:~/Si/A10/pcduino/busybox-1.21.0$[/url] cd ../rootfs/
[url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url] ls -l
total 12
drwxr-xr-x 2 change change 4096 2013-04-21 16:05 bin
lrwxrwxrwx 1 change change   11 2013-04-21 16:05 linuxrc -> bin/busybox
drwxr-xr-x 2 change change 4096 2013-04-21 16:05 sbin
drwxr-xr-x 4 change change 4096 2013-04-21 16:05 usr
[url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url][/font][/color][/p][p=26, null, left][color=#333333][font=Arial]2.创建设备文件(可以省,后来忘记也能启动呵呵)[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url] mkdir dev
[url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url] cd dev/
[url=mailto:change@change:~/Si/A10/pcduino/rootfs/dev$]change@change:~/Si/A10/pcduino/rootfs/dev$[/url] sudo mknod console c 5 1
[url=mailto:change@change:~/Si/A10/pcduino/rootfs/dev$]change@change:~/Si/A10/pcduino/rootfs/dev$[/url] sudo mknod null c 1 3
[url=mailto:change@change:~/Si/A10/pcduino/rootfs/dev$]change@change:~/Si/A10/pcduino/rootfs/dev$[/url] ls -l
total 0
crw-r--r-- 1 root root 5, 1 2013-04-21 17:00 console
crw-r--r-- 1 root root 1, 3 2013-04-21 17:00 null
3.构建配置文件[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]直接拷贝busybox的,偷点懒[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]change@change:~/Si/A10/pcduino$ cp busybox-1.21.0/examples/bootfloppy/etc/ rootfs/[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]change@change:~/Si/A10/pcduino/rootfs$ vim etc/inittab
[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]# /etc/inittab
::sysinit:/etc/init.d/rcS[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]::askfirst:~/bin/sh
保存退出[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]change@change:~/Si/A10/pcduino/rootfs$ vim etc/fstab
[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]proc /proc proc nosuid,noexec,nodev 0 0
sysfs /sys sysfs nosuid,noexec,nodev 0 0
devpts /dev/pts devpts gid=4,mode=620 0 0
tmpfs /tmp tmpfs defaults 0 0
devtmpfs /dev devtmpfs mode=0755,nosuid 0 0

/dev/mmcblk0p1 /boot vfat defaults 0 2
/dev/mmcblk0p2 / ext4 defaults,noatime 0 1
[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]保存退出[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]4.安装glibc库[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url] mkdir -p lib
[url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url] ls
bin  dev  etc  inittab  lib  linuxrc  sbin  usr
[url=mailto:change@change:~/Si/A10/pcduino/rootfs$]change@change:~/Si/A10/pcduino/rootfs$[/url] cd /home/change/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/lib/
[url=mailto:change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/lib$]change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/lib$[/url] cp *.so* /home/change/Si/A10/pcduino/rootfs/lib/ -d
[url=mailto:change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/lib$]change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/lib$[/url] cd ../usr/lib
[url=mailto:change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/usr/lib$]change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/usr/lib$[/url] cp *.so* /home/change/Si/A10/pcduino/rootfs/lib/ -d[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]5.烧写、测试[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/usr/lib$]change@change:~/tools/arm-2009q3/arm-none-linux-gnueabi/libc/armv4t/usr/lib$[/url] cd /home/change/Si/A10/pcduino/
[url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] sudo mount /dev/sdc2 /mnt/
[sudo] password for change:
[url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] sudo cp -pR rootfs/*  /mnt/[/font][/color][/p][p=26, null, left][color=#333333][font=Arial][url=mailto:change@change:~/Si/A10/pcduino$]change@change:~/Si/A10/pcduino$[/url] sudo umount /dev/sdc2[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]插tf到pcduino,系统启动[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]U-Boot 2012.10 (Apr 19 2013 - 18:46:44) Allwinner Technology[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]CPU:   SUNXI Family
Board: pcDuino
I2C:   ready
DRAM:  1 GiB
MMC:   SUNXI SD/MMC: 0
*** Warning - bad CRC, using default environment[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]In:    serial
Out:   serial
Err:   serial
Hit any key to stop autoboot:  0
reading uEnv.txt[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]144 bytes read
Loaded environment from uEnv.txt
reading boot.scr[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]289 bytes read
Jumping to boot.scr
## Executing script at 44000000
Wrong image format for "source" command
reading script.bin[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]44900 bytes read
reading uImage[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]4693132 bytes read
## Booting kernel from Legacy Image at 48000000 ...
   Image Name:   Linux-3.0.62
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    4693068 Bytes = 4.5 MiB
   Load Address: 40008000
   Entry Point:  40008000
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]Starting kernel ...[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]<6>Initializing cgroup subsys cpuset
<5>Linux version 3.0.62 ([url=mailto:change@change]change@change[/url]) (gcc version 4.4.1 (Sourcery G++ Lite 2009q3-67) ) #1 PREEMPT Sat Apr 20 18:32:39 CST 2013
CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
CPU: VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: sun4i
<6>Memory cut off:
<6>     MALI : 0x5c000000 - 0x5fffffff  (  64 MB)
<4>Ignoring unrecognised tag 0x00000000
<6>Memory Reserved:
<6>     SYS  : 0x43000000 - 0x4300ffff  (  64 kB)
<6>     VE   : 0x44000000 - 0x48ffffff  (  80 MB)
<6>     G2D  : 0x49000000 - 0x49ffffff  (  16 MB)
<6>     LCD  : 0x5a000000 - 0x5bffffff  (  32 MB)
Memory policy: ECC disabled, Data cache writeback
<6>chip-id: A10 (AW1623 revision C)
<7>On node 0 totalpages: 245760
<7>free_area_init_node: node 0, pgdat c0887ea0, node_mem_map c094e000
<7>  Normal zone: 1280 pages used for memmap
<7>  Normal zone: 0 pages reserved
<7>  Normal zone: 146176 pages, LIFO batch:31
<7>  HighMem zone: 768 pages used for memmap
<7>  HighMem zone: 97536 pages, LIFO batch:31
<7>pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
<7>pcpu-alloc: [0] 0
Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 243712
<5>Kernel command line: console=ttyS0,115200 root=/dev/mmcblk0p2 rootwait loglevel=8 panic=10
<6>PID hash table entries: 4096 (order: 2, 16384 bytes)
<6>Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
<6>Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
<6>Memory: 448MB 512MB = 960MB total
<5>Memory: 833852k/833852k available, 149188k reserved, 393216K highmem
<5>Virtual kernel memory layout:
    vector  : 0xffff0000 - 0xffff1000   (   4 kB)
    fixmap  : 0xfff00000 - 0xfffe0000   ( 896 kB)[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]........//太长了,省略若干[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]<6>mmc0: new high speed SD card at address 1234
[    4.140000] mmc0: new high speed SD card at address 1234
<6>mmcblk0: mmc0:1234 SA01G 942 MiB
[    4.160000] mmcblk0: mmc0:1234 SA01G 942 MiB
<6> mmcblk0: p1 p2
[    4.170000]  mmcblk0: p1 p2
<6>Console: switching to colour frame buffer device 160x45
[    4.290000] Console: switching to colour frame buffer device 160x45
<4>regulator_init_complete: axp20_buck3: incomplete constraints, leaving on
[    4.330000] regulator_init_complete: axp20_buck3: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_buck2: incomplete constraints, leaving on
[    4.350000] regulator_init_complete: axp20_buck2: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo4: incomplete constraints, leaving on
[    4.360000] regulator_init_complete: axp20_ldo4: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo3: incomplete constraints, leaving on
[    4.380000] regulator_init_complete: axp20_ldo3: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo2: incomplete constraints, leaving on
[    4.390000] regulator_init_complete: axp20_ldo2: incomplete constraints, leaving on
<4>regulator_init_complete: axp20_ldo1: incomplete constraints, leaving on
[    4.410000] regulator_init_complete: axp20_ldo1: incomplete constraints, leaving on
<6>sunxi-rtc sunxi-rtc: sunxi_rtc_gettime
[    4.420000] sunxi-rtc sunxi-rtc: sunxi_rtc_gettime
<6>sunxi-rtc sunxi-rtc: read time 2010-1-1 0:0:10
[    4.430000] sunxi-rtc sunxi-rtc: read time 2010-1-1 0:0:10
<6>sunxi-rtc sunxi-rtc: setting system clock to 2010-01-01 00:00:10 UTC (1262304010)
[    4.440000] sunxi-rtc sunxi-rtc: setting system clock to 2010-01-01 00:00:10 UTC (1262304010)
<3>EXT3-fs (mmcblk0p2): error: couldn't mount because of unsupported optional features (240)
[    4.460000] EXT3-fs (mmcblk0p2): error: couldn't mount because of unsupported optional features (240)
<3>EXT2-fs (mmcblk0p2): error: couldn't mount because of unsupported optional features (244)
[    4.480000] EXT2-fs (mmcblk0p2): error: couldn't mount because of unsupported optional features (244)
<6>EXT4-fs (mmcblk0p2): recovery complete
[    5.840000] EXT4-fs (mmcblk0p2): recovery complete
<6>EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[    6.060000] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
<6>VFS: Mounted root (ext4 filesystem) on device 179:2.
[    6.080000] VFS: Mounted root (ext4 filesystem) on device 179:2.
<6>devtmpfs: mounted
[    6.090000] devtmpfs: mounted
<6>Freeing init memory: 164K
[    6.090000] Freeing init memory: 164K
mount: mounting devpts on /dev/pts failed: No such file or directory
mount: mounting /dev/mmcblk0p1 on /boot failed: No such file or directory

Please press Enter to activate this console.

Processing /etc/profile... Done

/ # ls
bin         home        lost+found  run         tmp
dev         lib         mnt         sbin        usr
etc         linuxrc     proc        sys         var
/ #
[/font][/color][/p][p=26, null, left][color=#333333][font=Arial]挂载文件系统部分花了不少时间,经过多种尝试,系统·终于启动了。下一步可着手驱动开发了。[/font][/color][/p]


回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|手机版|Archiver|万博网页版登陆页派论坛 ( 粤ICP备15075382号-1  

GMT+8, 2024-11-1 23:31 , Processed in 1.140625 second(s), 26 queries , Gzip On.

Powered by Shumeipai.net! X3.2

© 2001-2015 万博网页版登陆页派论坛安全联盟

快速回复 返回顶部 返回列表