UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

取消
显示结果 
搜索替代 
您的意思是: 
Observer wenzhao_xie
Observer
171 次查看
注册日期: ‎12-23-2018

请教一个关于Linux系统无法启动的问题,或许与uEnv.txt文件有关?

转到解答

你好!

我现在尝试在zc706板子上启动一个Linux,现在拥有BOOT.bin、devicetree.dtb、uramdisk.image.gz 和 uImage文件(但是没有uEnv.txt文件)。我的手上有一个之前在zedboard板子上可以顺利启动Linux的流程(我zc706的这些文件就是按照这个流程创建的)。现在我在zc706上无法顺利启动Linux,因此我观察了在zedboard和zc706上尝试启动linux时它们各自打印出来的信息。

下面截取一段zedboard启动linux时打印出来的信息,加粗的部分我不是很理解,这代表zedboard上也没有顺利按照uEnv.txt去启动Linux,而是转而去使用默认的boot设置去启动linux吗?

(zc706和zedboard的完整打印信息附在上传的txt文件上)

-------------------------zedboard分割线------------------------

(省略)

reading uEnv.txt
388 bytes read in 10 ms (37.1 KiB/s)
Loaded environment from uEnv.txt
Importing environment from SD ...
Running uenvcmd ...
Copying Linux from SD to RAM...
reading uImage
4106112 bytes read in 238 ms (16.5 MiB/s)
reading devicetree.dtb
13541 bytes read in 16 ms (826.2 KiB/s)
reading uramdisk.image.gz
19242207 bytes read in 1069 ms (17.2 MiB/s)
Wrong Image Format for bootm command
ERROR: can't get kernel image!
Copying Linux from SD to RAM...
reading uImage
4106112 bytes read in 238 ms (16.5 MiB/s)
reading devicetree.dtb
13541 bytes read in 16 ms (826.2 KiB/s)
reading uramdisk.image.gz
19242207 bytes read in 1069 ms (17.2 MiB/s)
## Booting kernel from Legacy Image at 02080000 ...
Image Name: Linux-4.9.0-g5899204-dirty
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 4106048 Bytes = 3.9 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 04000000 ...
Image Name:
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 19242143 Bytes = 18.4 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
## Flattened Device Tree blob at 02000000
Booting using the fdt blob at 0x2000000
Loading Kernel Image ... OK
Loading Ramdisk to 1d8bf000, end 1eb18c9f ... OK
Loading Device Tree to 1d8b8000, end 1d8be4e4 ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

(省略)

------------------------zedboard分割线-----------------------------

 

下面放一段zc706打印出来的错误信息,可以看到板子没有读取到uEnv.txt文件,但似乎也还是去启动了linux?

我加粗了一些错误信息,这似乎就是导致zc706启动linux失败的原因?

-------------------------------zc706分割线--------------------------

(省略)

** Unable to read file uEnv.txt **
Copying Linux from SD to RAM...
reading uImage
4321368 bytes read in 253 ms (16.3 MiB/s)
reading devicetree.dtb
13563 bytes read in 17 ms (778.3 KiB/s)
reading uramdisk.image.gz
26164156 bytes read in 1444 ms (17.3 MiB/s)
## Booting kernel from Legacy Image at 02080000 ...
Image Name: Linux-4.14.0
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 4321304 Bytes = 4.1 MiB
Load Address: 00008000
Entry Point: 00008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 04000000 ...
Image Name:
Image Type: ARM Linux RAMDisk Image (gzip compressed)
Data Size: 26164092 Bytes = 25 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
## Flattened Device Tree blob at 02000000
Booting using the fdt blob at 0x2000000
Loading Kernel Image ... OK
Loading Ramdisk to 1e70c000, end 1ffffb7c ... OK
Loading Device Tree to 1e705000, end 1e70b4fa ... OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

(省略)

Unhandled fault: imprecise external abort (0x406) at 0x00000000
pgd = c0004000
[00000000] *pgd=00000000
Internal error: : 406 [#1] PREEMPT SMP ARM
Modules linked in:
CPU: 1 PID: 1 Comm: swapper/0 Not tainted 4.14.0 #1
Hardware name: Xilinx Zynq Platform
task: ef03f840 task.stack: ef040000
PC is at axi_clkgen_mmcm_read+0x20/0x80
LR is at axi_clkgen_get_div+0x20/0x90
pc : [<c033af8c>] lr : [<c033b00c>] psr: a0000013
sp : ef041dc8 ip : dec0de1c fp : 00000000
r10: 00000000 r9 : c0b6c720 r8 : c08a41a0
r7 : 0883d3b6 r6 : c08a3dac r5 : 00000008 r4 : ef223290
r3 : 00002710 r2 : ef041ddc r1 : 00000009 r0 : ef223290
Flags: NzCv IRQs on FIQs on Mode SVC_32 ISA ARM Segment none
Control: 18c5387d Table: 0000404a DAC: 00000051
Process swapper/0 (pid: 1, stack limit = 0xef040210)
Stack: (0xef041dc8 to 0xef042000)
1dc0: ef223290 00000008 c08a3dac c033b00c ef006300 ef223cc0
1de0: c0b6c720 00000001 ef223290 c033b130 c0b6c720 c0334c60 00000000 00000001
1e00: ef25fb00 c08a3dac ef223294 c08a41a0 c0b6c720 c0336d08 ef223294 c0336854
1e20: ef223294 ef223950 ef168610 ef223294 ef168610 ef223290 00000000 c0337068
1e40: ef223294 ef168600 ef041e54 c033ae4c ef7f62b8 de706831 c08fc07c ef7f62b8
1e60: c072d244 ef041e54 c0b6dc01 00000003 ef168610 ffffffed c0b1369c fffffdfb
1e80: 00000000 c03b26d4 ef168610 c0b6dc4c c0b6dc50 c0b1369c 00000000 c03b0ef4
1ea0: ef168610 c0b1369c ef168644 00000000 000000c6 c0a3083c c0a3adb0 c03b1048
1ec0: 00000000 c0b1369c c03b0fa4 c03af454 ef075f58 ef104ab4 c0b1369c ef0a9b80
1ee0: c0b18198 c03b0454 c08a46a0 00000000 c0a1687c c0b1369c 00000000 c0a1687c
1f00: c0b4e680 c03b18f0 ffffe000 00000000 c0a1687c c0101a20 c093fe3c 000000c6
1f20: 00000000 c0138578 00000000 c08bfc58 00000006 00000006 c0888f18 00000000
1f40: c0891924 c0888f8c efffce09 00000000 00000000 00000007 c0b4e680 c0a30830
1f60: 00000007 c0b4e680 c0a30834 c0b4e680 000000c6 c0a00dc0 00000006 00000006
1f80: 00000000 c0a005a8 00000000 c06b13d0 00000000 00000000 00000000 00000000
1fa0: 00000000 c06b13d8 00000000 c0107a30 00000000 00000000 00000000 00000000
1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
1fe0: 00000000 00000000 00000000 00000000 00000013 00000000 0191040d 11000243
[<c033af8c>] (axi_clkgen_mmcm_read) from [<c033b00c>] (axi_clkgen_get_div+0x20/0x90)
[<c033b00c>] (axi_clkgen_get_div) from [<c033b130>] (axi_clkgen_recalc_rate+0x20/0xec)
[<c033b130>] (axi_clkgen_recalc_rate) from [<c0336d08>] (clk_register+0x330/0x640)
[<c0336d08>] (clk_register) from [<c0337068>] (devm_clk_hw_register+0x3c/0x84)
[<c0337068>] (devm_clk_hw_register) from [<c033ae4c>] (axi_clkgen_probe+0x140/0x180)
[<c033ae4c>] (axi_clkgen_probe) from [<c03b26d4>] (platform_drv_probe+0x50/0xac)
[<c03b26d4>] (platform_drv_probe) from [<c03b0ef4>] (driver_probe_device+0x238/0x2e8)
[<c03b0ef4>] (driver_probe_device) from [<c03b1048>] (__driver_attach+0xa4/0xa8)
[<c03b1048>] (__driver_attach) from [<c03af454>] (bus_for_each_dev+0x4c/0x9c)
[<c03af454>] (bus_for_each_dev) from [<c03b0454>] (bus_add_driver+0x188/0x20c)
[<c03b0454>] (bus_add_driver) from [<c03b18f0>] (driver_register+0x78/0xf4)
[<c03b18f0>] (driver_register) from [<c0101a20>] (do_one_initcall+0x44/0x168)
[<c0101a20>] (do_one_initcall) from [<c0a00dc0>] (kernel_init_freeable+0x148/0x1d4)
[<c0a00dc0>] (kernel_init_freeable) from [<c06b13d8>] (kernel_init+0x8/0x108)
[<c06b13d8>] (kernel_init) from [<c0107a30>] (ret_from_fork+0x14/0x24)
Code: 0a000018 e590c000 e59cc074 f57ff04f (e31c0801)
---[ end trace e54b4a34e906ff48 ]---
Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b

CPU0: stopping
CPU: 0 PID: 0 Comm: swapper/0 Tainted: G D 4.14.0 #1
Hardware name: Xilinx Zynq Platform
[<c010edbc>] (unwind_backtrace) from [<c010b6f4>] (show_stack+0x10/0x14)
[<c010b6f4>] (show_stack) from [<c069f0a4>] (dump_stack+0x8c/0xa0)
[<c069f0a4>] (dump_stack) from [<c010d4dc>] (ipi_cpu_stop+0x64/0x74)
[<c010d4dc>] (ipi_cpu_stop) from [<c010dc1c>] (handle_IPI+0x6c/0x7c)
[<c010dc1c>] (handle_IPI) from [<c0101464>] (gic_handle_irq+0x8c/0x90)
[<c0101464>] (gic_handle_irq) from [<c010c20c>] (__irq_svc+0x6c/0xa8)
Exception stack(0xc0b01f40 to 0xc0b01f88)
1f40: 00000001 00000000 00000000 c01179e0 ffffe000 c0b03cb4 c0b03c68 c0a42a48
1f60: c0b48ee0 00000000 00000000 00000000 2ed8e000 c0b01f90 c0108480 c0108484
1f80: 60000013 ffffffff
[<c010c20c>] (__irq_svc) from [<c0108484>] (arch_cpu_idle+0x38/0x3c)
[<c0108484>] (arch_cpu_idle) from [<c0150e14>] (do_idle+0x16c/0x1f8)
[<c0150e14>] (do_idle) from [<c0151148>] (cpu_startup_entry+0x18/0x1c)
[<c0151148>] (cpu_startup_entry) from [<c0a00c6c>] (start_kernel+0x394/0x3a0)
[<c0a00c6c>] (start_kernel) from [<0000807c>] (0x807c)
---[ end Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b

---------------------------zc706分割线-------------------------------------

 

现在我主要的疑惑如下:

(1)zedboard是否按照uEnv.txt文件去启动了Linux?如果是,那么也许我zc706启动linux失败的原因就出在缺失uEnv.txt文件上?如果不是,那么也许我在zc706上启动Linux并不需要一个uEnv.txt?

(2)zc706上显示的错误信息是什么意思?是我FPGA的bit文件出错了吗?还是别的什么问题?

 

问题较长,非常感谢您的答复!

 

0 项奖励
1 个已接受解答

已接受的解答
Highlighted
Xilinx Employee
Xilinx Employee
132 次查看
注册日期: ‎09-14-2018

回复: 请教一个关于Linux系统无法启动的问题,或许与uEnv.txt文件有关?

转到解答

Hi @wenzhao_xie

(1)zedboard是否按照uEnv.txt文件去启动了Linux?如果是,那么也许我zc706启动linux失败的原因就出在缺失uEnv.txt文件上?如果不是,那么也许我在zc706上启动Linux并不需要一个uEnv.txt?

-- 通常是会在uEnv.txt中去找的(并不总是,要看bootcmd定义),但具体执行的是什么启动指令,请在uboot下执行 printenv bootcmd。

(2)zc706上显示的错误信息是什么意思?是我FPGA的bit文件出错了吗?还是别的什么问题?

-- 可能是你的镜像文件有问题,kernal/application或者加载的比特流和application不匹配都有可能。同理也可以通过printenv bootcmd看看启动指令是否正确。

 

供参考。

----------------------------------------------------------------------------------------------
如果提供的信息能解决您的问题,请标记为“接受为解决方案”。
如果您认为帖子有帮助,请点击“奖励”。谢谢!
----------------------------------------------------------------------------------------------

 

 

1 条回复
Highlighted
Xilinx Employee
Xilinx Employee
133 次查看
注册日期: ‎09-14-2018

回复: 请教一个关于Linux系统无法启动的问题,或许与uEnv.txt文件有关?

转到解答

Hi @wenzhao_xie

(1)zedboard是否按照uEnv.txt文件去启动了Linux?如果是,那么也许我zc706启动linux失败的原因就出在缺失uEnv.txt文件上?如果不是,那么也许我在zc706上启动Linux并不需要一个uEnv.txt?

-- 通常是会在uEnv.txt中去找的(并不总是,要看bootcmd定义),但具体执行的是什么启动指令,请在uboot下执行 printenv bootcmd。

(2)zc706上显示的错误信息是什么意思?是我FPGA的bit文件出错了吗?还是别的什么问题?

-- 可能是你的镜像文件有问题,kernal/application或者加载的比特流和application不匹配都有可能。同理也可以通过printenv bootcmd看看启动指令是否正确。

 

供参考。

----------------------------------------------------------------------------------------------
如果提供的信息能解决您的问题,请标记为“接受为解决方案”。
如果您认为帖子有帮助,请点击“奖励”。谢谢!
----------------------------------------------------------------------------------------------