当前位置:网站首页>Solve mt7620 continuous cycle uboot (LZMA error 1 - must reset board to recover)
Solve mt7620 continuous cycle uboot (LZMA error 1 - must reset board to recover)
2022-07-27 16:01:00 【xhoufei2010】
1 Hardware platform
1、 controller :MT7620(A9 kernel )
2 software platform
1、 development environment :Ubuntu12.04
2、SDK Kernel package :MT7620 SDK Software development package (MediaTek_ApSoC_SDK_4320_20150414.tar.bz2)
3、 Kernel version :linux-2.6.36.x
4、Uboot edition :U-Boot 1.1.3
3 Function introduction
use Ralink Of SDK Development kit , Compiled kernel , Previously burned to MT7620 On , It works . later , Compiled kernel , After burning , The development board restarts repeatedly , Has been constantly Uboot, Fall into a dead cycle , Unable to load kernel .
Error message :
stream version is not supported, outSize = FFFFFFFF
LZMA ERROR 1 - must RESET board to recoverThe purpose of this paper is to solve this problem .
Reference documents :《MTK_APSoC_SDK_User_Manual.pdf》
Document download path :http://download.csdn.net/detail/xhoufei2010/9478004
4 Problem analysis
4.1 Error log
U-Boot 1.1.3 (Aug 31 2015 - 17:33:25)
Board: Ralink APSoC DRAM: 256 MB
relocate_code Pointer at: 8ffb8000
enable ephy clock...done. rf reg 29 = 5
SSC disabled.
******************************
Software System Reset Occurred
******************************
spi_wait_nsec: 29
spi device id: 20 ba 20 10 44 (ba201044)
find flash: MT25QL512AB
raspi_read: from:30000 len:1000
raspi_read: from:30000 len:1000
============================================
Ralink UBoot Version: 4.3.0.0
--------------------------------------------
ASIC 7620_MP (Port5<->None)
DRAM component: 2048 Mbits DDR, width 16
DRAM bus: 16 bit
Total memory: 256 MBytes
Flash component: 16 MBytes NOR Flash
Date:Aug 31 2015 Time:17:33:25
============================================
icache: sets:512, ways:4, linesz:32 ,total:65536
dcache: sets:256, ways:4, linesz:32 ,total:32768
##### The CPU freq = 580 MHZ ####
estimate memory size =256 Mbytes
raspi_read: from:50000 len:40
raspi_read: from:850000 len:40
=================================================
Check image validation:
Image1 Header Magic Number --> OK
Image2 Header Magic Number --> OK
Image1 Header Checksum --> OK
Image2 Header Checksum --> OK
Image1 Data Checksum --> raspi_read: from:50040 len:6634b2
OK
Image2 Data Checksum --> raspi_read: from:850040 len:663d95
OK
Image1 Stable Flag --> Stable
Image1 Try Counter --> 3
Image1: OK Image2: OK
=================================================
Please choose the operation:
1: Load system code to SDRAM via TFTP.
2: Load system code then write to Flash via TFTP.
3: Boot system code via Flash (default).
4: Entr boot command line interface.
7: Load Boot Loader code then write to Flash via Serial.
9: Load Boot Loader code then write to Flash via TFTP.
0
3: System Boot system code via Flash.
## Booting image at bc050000 ...
raspi_read: from:50000 len:40
Image Name: Linux Kernel Image
Image Type: MIPS Linux Kernel Image (lzma compressed)
Data Size: 6698162 Bytes = 6.4 MB
Load Address: 80000000
Entry Point: 8000c150
raspi_read: from:50040 len:6634b2
Verifying Checksum ... OK
Uncompressing Kernel Image ...
stream version is not supported, outSize = FFFFFFFF
LZMA ERROR 1 - must RESET board to recover
U-Boot 1.1.3 (Aug 31 2015 - 17:33:25)
Board: Ralink APSoC DRAM: 256 MB
relocate_code Pointer at: 8ffb8000
enable ephy clock...done. rf reg 29 = 5
SSC disabled.
******************************4.2 Cause analysis
(1) because Uboot It can start normally , Describe the hardware Flash No problem , Prompt from the error message , It can be seen that ,Uboot Can load normally , however Kernel Unable to load at all , Explain that you can't get from Uboot Jump to Kernel.
(2) about Uboot Loading kernel , By decompressing the kernel file , Then import . From the wrong phenomenon , The equipment keeps Uboot, There is a problem with decompression , As the log indicates .
There is no problem with the check value of the kernel , The problem link , Is to decompress the kernel image .
Verifying Checksum ... OK
Uncompressing Kernel Image ...
stream version is not supported, outSize = FFFFFFFF
LZMA ERROR 1 - must RESET board to recover(3) From error prompt , It can be seen that , The problem lies in "LZMA" The decompressed problem .
LZMA ERROR 1 - must RESET board to recover4.3 see LZMA problem
from Ralink Official 《MTK_APSoC_SDK_User_Manual.pdf》 Manual No 44 Page and 45 page , chapter “5.2 Install LZMA Utility” see LZMA Installation of tools for .
The original text is shown in the figure 4-1 and 4-2 Shown .

chart 4-1 install LZMA

chart 4-2 Set the kernel image compression mode
From the document , You can see the hint :LZMA Algorithm , It doesn't reverse ( backward ) compatible , You have to use lzma If version 4.32.0beta3 Tools compress the kernel image , Otherwise, decompression problems will occur .
Notes: lzma algorithm is not backward-compatible, so you have to use this lzma-4.32.0beta3 tool to
compress your kernel image otherwise you will encounter lzma decompression issue.4.4 see lzma Compression method and version
4.4.1 Check the kernel compression mode
Get into source/vendors/Ralink/MT7620/, see Makefile, Among them, the original Makefile, The setting code of compression mode is as follows :
CUR_DIR = $(shell pwd)
COMP = lzmaimage: mkimage
$(CROSS_COMPILE)objcopy -O binary -R .note -R .comment -S $(ROOTDIR)/$(LINUXDIR)/vmlinux $(KERNELZ)
cd $(IMAGEDIR) ; rm -f $(KERNELZ).*; $(COMP) -9 -f -S .$(COMP) $(KERNELZ)You can know from the code , The compression method is lzma, And no path is set , Is directly Ubuntu System installed lzma Version and path .
If you strictly refer to 《MTK_APSoC_SDK_User_Manual.pdf》 Step operation , Naturally, there will be no problem . But if the user installs a new lzma, And the version is higher , Will inevitably appear lzma Version incompatibility problem .
4.4.2 Check the system lzma edition
stay ubuntu Next , Enter the command “ lzma -V” Check the system lzma edition , Pictured 4-3 Shown .
lzma -V
chart 4-3 Check the system lzma edition
4.4.3 The problem summary
Uboot Used for "lzma-4.32.0beta3", The kernel image compression tool version is “lzma5.2”, therefore uboot Cannot be compatible with a newer version 5.2, So lead to uboot decompression kernel Failure .
5 Solution
Modify the kernel's makefile, Make it lzma route , Take the absolute path , Point to “lzma-4.32.0beta3” edition .makefile The path of is “source/vendors/Ralink/MT7620/Makefile”
5.1 increase lzma Macro definition of path
The original makefile The first 8 That's ok
COMP = lzmaincrease COMP_PATH Macro definition , Point to “lzma-4.32.0beta3” edition , After compiling the tools of this article ( this paper 4.3 Chapter diagram 4-1 Installation method ), The installation path is :/opt/lzma-4.32.7/src/lzma, Modified makefile
COMP = lzma
COMP_PATH = /opt/lzma-4.32.7/src/lzma 5.2 Appoint lzma Compression tool path
take " $(COMP)" It is amended as follows “ $(COMP_PATH)/$(COMP)”, Added absolute path index .
Before modification makefile:
image: mkimage
$(CROSS_COMPILE)objcopy -O binary -R .note -R .comment -S $(ROOTDIR)/$(LINUXDIR)/vmlinux $(KERNELZ)
cd $(IMAGEDIR) ; rm -f $(KERNELZ).*; $(COMP) -9 -f -S .$(COMP) $(KERNELZ)Modified makefile:
image: mkimage
$(CROSS_COMPILE)objcopy -O binary -R .note -R .comment -S $(ROOTDIR)/$(LINUXDIR)/vmlinux $(KERNELZ)
cd $(IMAGEDIR) ; rm -f $(KERNELZ).*; $(COMP_PATH)/$(COMP) -9 -f -S .$(COMP) $(KERNELZ)6 Verify that the problem is solved
Burn the newly compiled kernel to the development board , Boot up , Can be normally from uboot Unzip the kernel , And open the kernel , The log is as follows , Explain how to solve the problem .
raspi_read: from:50040 len:663d95
Verifying Checksum ... OK
Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 8000c150) ...
## Giving linux memsize in MB, 256
Starting kernel ...
怘怘怘怘怘怘怘怘怘怘怘怘怘怘 fffxfffnux version 2.6.36 ([email protected]) (gcc version 4.6.3 (Buildroot 2012.11.1) ) #65 Fri Dec 4 12:17:11 CST 2015
The CPU feqenuce set to 580 MHz
MIPS CPU sleep mode enabled.
PCIE: bypass PCIe DLL.
PCIE: Elastic buffer control: Add边栏推荐
- Live broadcast software development, customized pop-up effect of tools
- Using Lombok results in the absence of parent class attributes in the printed toString
- Under the ban, the Countermeasures of security giants Haikang and Dahua!
- Mlx90640 infrared thermal imager temperature sensor module development notes (VII)
- Is the array name the address of the first element?
- DRF学习笔记(二):数据反序列化
- 数据表的约束以及设计、联合查询——8千字攻略+题目练习解答
- 为应对RISC-V挑战?Arm CPU引入自定义指令功能!
- 解决MT7620不断循环uboot(LZMA ERROR 1 - must RESET board to recover)
- Learn parquet file format
猜你喜欢

解决MT7620不断循环uboot(LZMA ERROR 1 - must RESET board to recover)

SQL multi table query

Binder初始化过程

Is the array name the address of the first element?
![[sword finger offer] interview question 54: the k-largest node of the binary search tree](/img/13/7574af86926a228811503904464f3f.png)
[sword finger offer] interview question 54: the k-largest node of the binary search tree

CAS compares the knowledge exchanged, ABA problems, and the process of lock upgrading

DRF学习笔记(二):数据反序列化

C language: string function and memory function

synchronized和ReentrantLock的区别

UDP 的报文结构和注意事项
随机推荐
First acquaintance with MySQL database
网络原理(1)——基础原理概述
Single machine high concurrency model design
C language: minesweeping games
线程间等待与唤醒机制、单例模式、阻塞队列、定时器
__typeof和typeof的差异
[regular expression] matching grouping
QT (VI) value and string conversion
[sword finger offer] interview question 54: the k-largest node of the binary search tree
[sword finger offer] interview question 55 - Ⅰ / Ⅱ: depth of binary tree / balanced binary tree
UDP message structure and precautions
Inter thread wait and wake-up mechanism, singleton mode, blocking queue, timer
Using Lombok results in the absence of parent class attributes in the printed toString
DRF学习笔记(二):数据反序列化
[regular expression] match the beginning and end
The method of exchanging two numbers in C language
Go language slow start - Basic built-in types
快速高效删除node_modules
Pycharm导入已有的Project
Understand │ what is cross domain? How to solve cross domain problems?