您尚未登录。

楼主 #1 2019-08-31 23:59:58

gunge204
会员
注册时间: 2019-08-24
已发帖子: 26
积分: 26

荔枝派nano烧写16M的spiflash后启动异常

按照荔枝派nano的教程和本论坛置顶帖子的顺序,制作了完成了镜像文件,烧写进去之后,发现最后起不来
1、看打印信息,发现了spi,并且好像挂载rootfs也成功了
2、搜索本论坛,参考了一些,也取消了一些配置上的东西,不管用
3、难道是根文件系统有问题?

U-Boot SPL 2018.01-05679-g013ca457fd-dirty (Aug 31 2019 - 22:35:11)
DRAM: 32 MiB
Trying to boot from MMC1
Card did not respond to voltage select!
mmc_init: -95, time 22
spl: mmc init failed with error: -95
Trying to boot from sunxi SPI


U-Boot 2018.01-05679-g013ca457fd-dirty (Aug 31 2019 - 22:35:11 +0800) Allwinner Technology

CPU:   Allwinner F Series (SUNIV)
Model: Lichee Pi Nano
DRAM:  32 MiB
MMC:   SUNXI SD/MMC: 0
SF: Detected w25q128bv with page size 256 Bytes, erase size 4 KiB, total 16 MiB
*** Warning - bad CRC, using default environment

Setting up a 800x480 lcd console (overscan 0x0)
In:    serial@1c25000
Out:   serial@1c25000
Err:   serial@1c25000
Net:   No ethernet found.
starting USB...
No controllers found
Hit any key to stop autoboot:  0 
SF: Detected w25q128bv with page size 256 Bytes, erase size 4 KiB, total 16 MiB
device 0 offset 0x100000, size 0x4000
SF: 16384 bytes @ 0x100000 Read: OK
device 0 offset 0x110000, size 0x400000
SF: 4194304 bytes @ 0x110000 Read: OK
## Flattened Device Tree blob at 80c00000
   Booting using the fdt blob at 0x80c00000
   Loading Device Tree to 80e5f000, end 80e63ddc ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0
[    0.000000] Linux version 5.2.0-licheepi-nano+ (qiup@qiup-virtual-machine) (gcc version 7.4.0 (Ubuntu/Linaro 7.4.0-1ubuntu1~18.04.1)) #1 Fri Aug 30 23:26:40 CST 2019
[    0.000000] CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=0005317f
[    0.000000] CPU: VIVT data cache, VIVT instruction cache
[    0.000000] OF: fdt: Machine model: Lichee Pi Nano
[    0.000000] Memory policy: Data cache writeback
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 8128
[    0.000000] Kernel command line: console=ttyS0,115200 panic=5 rootwait root=/dev/mtdblock3 rw rootfstype=jffs2
[    0.000000] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes)
[    0.000000] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes)
[    0.000000] Memory: 23760K/32768K available (5120K kernel code, 208K rwdata, 1300K rodata, 1024K init, 221K bss, 9008K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[    0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[    0.000000] random: get_random_bytes called from start_kernel+0x254/0x3cc with crng_init=0
[    0.000046] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[    0.000126] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[    0.000639] Console: colour dummy device 80x30
[    0.000739] Calibrating delay loop... 203.16 BogoMIPS (lpj=1015808)
[    0.070246] pid_max: default: 32768 minimum: 301
[    0.070697] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.070758] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.072584] CPU: Testing write buffer coherency: ok
[    0.074720] Setting up static identity map for 0x80100000 - 0x80100058
[    0.077164] devtmpfs: initialized
[    0.083376] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.083441] futex hash table entries: 256 (order: -1, 3072 bytes)
[    0.083778] pinctrl core: initialized pinctrl subsystem
[    0.087298] DMA: preallocated 256 KiB pool for atomic coherent allocations
[    0.089356] cpuidle: using governor menu
[    0.142230] SCSI subsystem initialized
[    0.142653] usbcore: registered new interface driver usbfs
[    0.142818] usbcore: registered new interface driver hub
[    0.143023] usbcore: registered new device driver usb
[    0.143506] pps_core: LinuxPPS API ver. 1 registered
[    0.143533] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    0.144167] Advanced Linux Sound Architecture Driver Initialized.
[    0.144539] clocksource: Switched to clocksource timer
[    0.176901] NetWinder Floating Point Emulator V0.97 (double precision)
[    0.178918] Initialise system trusted keyrings
[    0.179543] workingset: timestamp_bits=30 max_order=13 bucket_order=0
[    0.198654] jffs2: version 2.2. (NAND) © 2001-2006 Red Hat, Inc.
[    0.206458] Key type asymmetric registered
[    0.206499] Asymmetric key parser 'x509' registered
[    0.206665] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 252)
[    0.206693] io scheduler mq-deadline registered
[    0.206709] io scheduler kyber registered
[    0.219835] suniv-f1c100s-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[    0.421925] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[    0.428196] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pe not found, using dummy regulator
[    0.430037] printk: console [ttyS0] disabled
[    0.450331] 1c25000.serial: ttyS0 at MMIO 0x1c25000 (irq = 24, base_baud = 6250000) is a 16550A
[    0.777835] printk: console [ttyS0] enabled
[    0.786192] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pd not found, using dummy regulator
[    0.804839] SCSI Media Changer driver v0.25 
[    0.810628] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pc not found, using dummy regulator
[    0.823926] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    0.828867] 4 fixed-partitions partitions found on MTD device spi0.0
[    0.835289] Creating 4 MTD partitions on "spi0.0":
[    0.840095] 0x000000000000-0x000000100000 : "u-boot"
[    0.849304] 0x000000100000-0x000000110000 : "dtb"
[    0.858011] 0x000000110000-0x000000510000 : "kernel"
[    0.867110] 0x000000510000-0x000001000000 : "rootfs"
[    0.876615] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    0.883150] ehci-platform: EHCI generic platform driver
[    0.888849] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    0.895180] ohci-platform: OHCI generic platform driver
[    0.900798] usbcore: registered new interface driver usb-storage
[    0.907942] i2c /dev entries driver
[    0.915824] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pf not found, using dummy regulator
[    0.954098] sunxi-mmc 1c0f000.mmc: initialized, max. request size: 16384 KB
[    0.963630] usbcore: registered new interface driver usbhid
[    0.969343] usbhid: USB HID core driver
[    0.992726] Loading compiled-in X.509 certificates
[    1.008765] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pd not found, using dummy regulator
[    1.020249] sun4i-backend 1e60000.display-backend: Couldn't find matching frontend, frontend features disabled
[    1.031136] sun4i-drm display-engine: bound 1e60000.display-backend (ops 0xc0637c34)
[    1.040267] sun4i-drm display-engine: bound 1c0c000.lcd-controller (ops 0xc063688c)
[    1.048053] [drm] Supports vblank timestamp caching Rev 2 (21.10.2013).
[    1.054708] [drm] No driver support for vblank timestamp query.
[    1.061940] [drm] Initialized sun4i-drm 1.0.0 20150629 for display-engine on minor 0
[    1.314921] Console: switching to colour frame buffer device 100x30
[    1.354692] sun4i-drm display-engine: fb0: sun4i-drmdrmfb frame buffer device
[    1.362774] ALSA device list:
[    1.365902]   #0: Loopback 1
[    1.371804] random: fast init done
[    1.485396] random: crng init done
[    4.255663] VFS: Mounted root (jffs2 filesystem) on device 31:3.
[    4.263993] devtmpfs: mounted
[    4.274122] Freeing unused kernel memory: 1024K
[    4.278883] Run /sbin/init as init process
[    6.975375] Kernel panic - not syncing: Attempted to kill init! exitcode=0x0000000b
[    6.983049] CPU: 0 PID: 1 Comm: init Not tainted 5.2.0-licheepi-nano+ #1
[    6.989729] Hardware name: Allwinner suniv Family
[    6.994520] [<c010e42c>] (unwind_backtrace) from [<c010b9f4>] (show_stack+0x10/0x14)
[    7.002271] [<c010b9f4>] (show_stack) from [<c0116dc0>] (panic+0xe8/0x2e4)
[    7.009145] [<c0116dc0>] (panic) from [<c01185f4>] (do_exit+0x9dc/0xa18)
[    7.015844] [<c01185f4>] (do_exit) from [<c0119190>] (do_group_exit+0x3c/0xb4)
[    7.023066] [<c0119190>] (do_group_exit) from [<c0122d54>] (get_signal+0x10c/0x7bc)
[    7.030724] [<c0122d54>] (get_signal) from [<c010af60>] (do_work_pending+0x1a8/0x558)
[    7.038552] [<c010af60>] (do_work_pending) from [<c0101068>] (slow_work_pending+0xc/0x20)
[    7.046704] Exception stack(0xc1831fb0 to 0xc1831ff8)
[    7.051753] 1fa0:                                     bec48f10 00000000 00000000 00000000
[    7.059919] 1fc0: 00000940 00000000 00000000 00000000 00000000 00000000 000275e4 00000000
[    7.068082] 1fe0: 00000000 bec48f10 b6edcb53 b6edd000 00000030 ffffffff
[    7.074691] Rebooting in 5 seconds..
[   13.053923] Reboot failed -- System halted

离线

#2 2019-09-01 15:02:53

晕哥
管理员
所在地: 微信 whycan_cn
注册时间: 2017-09-06
已发帖子: 9,224
积分: 9197

Re: 荔枝派nano烧写16M的spiflash后启动异常

对, 你的编译器有问题, 导致根文件系统有问题:

https://whycan.cn/t_2757.html
https://whycan.cn/t_1180.html
https://whycan.cn/t_1896.html





在线

楼主 #3 2019-09-01 20:26:47

gunge204
会员
注册时间: 2019-08-24
已发帖子: 26
积分: 26

Re: 荔枝派nano烧写16M的spiflash后启动异常

结贴:感谢晕哥,确实如此,编译buildroot生成根文件的时候不能再用arm-linux-gnueabi,而应该用默认下载的Sourcery CodeBench ARM 2014.5
那么我以后在PC上交叉编译C程序生成可执行文件到nano上的时候,编译器应该用哪个呢?按道理,也应该用根文件系统同样的编译器Sourcery CodeBench ARM 2014.5?

晕哥 说:

对, 你的编译器有问题, 导致根文件系统有问题:

https://whycan.cn/t_2757.html
https://whycan.cn/t_1180.html
https://whycan.cn/t_1896.html

最近编辑记录 gunge204 (2019-09-01 20:30:09)

离线

#4 2019-09-01 20:45:44

晕哥
管理员
所在地: 微信 whycan_cn
注册时间: 2017-09-06
已发帖子: 9,224
积分: 9197

Re: 荔枝派nano烧写16M的spiflash后启动异常

Sourcery CodeBench ARM 2014.5

这个可以用的, 或者用 buildroot 自己生成的 gcc ===>

QQ20190901204126.png

如果 u-boot / linux  需要使用buildroot 生成的gcc工具链, 那么执行:
export PATH=/opt/f1c100s/buildroot-2019.02.2/output/host/bin:$PATH

然后执行:
ARCH=arm CROSS_COMPILE=arm-linux- make




在线

#5 2020-07-23 23:33:51

lignin
会员
注册时间: 2020-03-21
已发帖子: 99
积分: 97.5

Re: 荔枝派nano烧写16M的spiflash后启动异常

我按照韦东山的教程编译了个hello world驱动,,因为编译链的原因,要么显示line 1: syntax error: word unexpected (expecting ") .再不就是找不到这个文件,明明文件就在这里。最后还是看到晕哥写的这个才注意到buildroot使用的是自己的编译链,弄了一个下午加晚上,总算是会写helloworld了

离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn