rochchip px30刷机后卡在系统引导界面。具体系统引导日志为:
[ 2.403866] Run /init as init process [ 2.873149] dwmmc_rockchip ff390000.dwmmc: Successfully tuned phase to 207 [ 2.874129] mmc1: new HS200 MMC card at address 0001 [ 2.877446] mmcblk1: mmc1:0001 08A391 7.22 GiB [ 2.879300] mmcblk1boot0: mmc1:0001 08A391 partition 1 4.00 MiB [ 2.881151] mmcblk1boot1: mmc1:0001 08A391 partition 2 4.00 MiB [ 2.882121] mmcblk1rpmb: mmc1:0001 08A391 partition 3 4.00 MiB, chardev (241:0) [ 2.889840] mmcblk1: p1 p2 p3 p4 p5 p6 p7 p8 p9 p10 p11 p12 p13 p14 Device /dev/mmcblk1p9 is not a valid VERITY device. system enter halt error(0)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | [ 2.812287] device-mapper: verity: sha256 using implementation "sha256-ce" Verity OK [ 2.824325] EXT4-fs (mmcblk1p11): recovery complete [ 2.824840] EXT4-fs (mmcblk1p11): mounted filesystem with ordered data mode. Opts: errors= continue [ 2.832181] device-mapper: verity: 179:9: data block 0 is corrupted [ 2.832913] SQUASHFS error: squashfs_read_data failed to read block 0x0 [ 2.833507] squashfs: SQUASHFS error: unable to read squashfs_super_block mount: mounting /dev/mapper/vroot on /root failed: Input/output error system enter halt error(0) [ 2.840945] cpu cpu0: min=816000, max=816000 [ 2.857804] cpu cpu0: min=816000, max=816000 [ 2.885917] vendor storage:20190527 ret = 0 [ 2.890964] reboot: Restarting system |
根据提供的启动日志和搜索结果,我们可以分析出以下rootfs镜像检查不通过的问题:
dm-verity校验失败: 日志中显示device-mapper: verity: 179:9: data block 0 is corrupted
,这表明在使用dm-verity进行数据完整性校验时,发现数据块0已损坏。这可能是由于rootfs镜像文件损坏或者在传输过程中发生了错误。
通过搜索,可以在uboot的命令行内通过bootargs禁用这个校验机制,或替换默认的初始化程序/init .搜到了4种方法:
rdinit=/bin/bash
rdinit=/sbin/init
androidboot.veritymode=disabled
dm_verity.verify=0
经测试rdinit=/bin/bash或rdinit=/sbin/init ,方式可以生效,=/bin/bash是修改了系统引导后执行的默认程序,可能肯会导致系统内一些初始化项目没有完成。/sbin/init是OPENWRT的正常初始化文件。
以下二条命令即可实现正常引导:
setenv bootargs console=ttyFIQ0,1500000 earlycon=uart8250,mmio32,0xff160000 system=/dev/mmcblk1p9 root=/dev/mmcblk1p9 rdinit=/sbin/init rootdelay=1 rw rootwait net.ifnames=0
mmc read 0x03a80000 0x00010000 0x014000;bootm 0x03a80000
其他办法:编辑镜像,对以下关键值清零。应该可以直接编辑引导程序,/sbin/initab , /etc/inittab 这些都没有测试。
Method 1 - Manually patching boot.img using hex editor
Requirements
- Ideal for devices with Android Verified Boot 1.0 (commonly found in Android 8)
- Stock boot.img for your phone model (it's best it's for your Build Number / Variant ). You can extract from the stock ROM / firmware of your device (you may check our firmware collection) OR backup from your device using any method at the forum e.g Wwr_Mtk, Miracle Box, CM2, Nck Box Pro etc
- Hxd hex editor ; download @ https://mh-nexus.de/en/hxd/
- Install adb and fastboot
Follow the steps below to patch boot.img manually to remove/disable dm-verity
- Launch Hxd hex editor tool
- Drag and drop your boot.img onto HxD hex editor window
- Click Search > Replace
- In the Replace windows, Click the Hex-values tab and input the following below
Search for 2C 76 65 72 69 66 79
replace with 00 00 00 00 00 00 00
android刷机后卡住也可以用这个办法解决。
参考文章:https://www.hovatek.com/forum/thread-32719.html
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 震惊!C++程序真的从main开始吗?99%的程序员都答错了
· 【硬核科普】Trae如何「偷看」你的代码?零基础破解AI编程运行原理
· 单元测试从入门到精通
· 上周热点回顾(3.3-3.9)
· winform 绘制太阳,地球,月球 运作规律