积分1 / 贡献0

提问1答案被采纳0文章0

作者动态

    RK3588移植OpenHarmony4.0release的init问题

    weixin_38858744 显示全部楼层 发表于 2024-11-15 11:18:22

    【问题描述】

    1. 相关的代码(请勿使用截图)
    2. 运行结果、错误截图
    3. 我尝试过的解决方法和结果
    4. 我想要达到的结果

    我们使用3588平台自己做了个板子,然后请外协做好了kylin的操作系统,然后要自己移植Oh操作系统,本人搭建好了4.0release源码环境,然后将kylin的kernel替换210的kernel,编译完成后,烧录,启动到如下所示:

    [ 12.514697] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0)

    [ 12.517457] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.518251] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.518866] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.519430] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.519994] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.520554] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.521153] EXT4-fs error (device mmcblkError loading shared librar0p7): y libselinux.z.so: No error information e(needed by /init) xt4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.521747] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) [ 12.522298] EXT4-fs error (device mmcblk0p7): ext4_find_extent:924: inode #1806: comm init: pblk 723578 bad header/extent: invalid magic - magic 0, entries 0, max 0(0), depth 0(0) Error loading shared library librestorecon.z.so: No error information (needed by /init) Error relocating /init: Restorecon: symbol not found Error relocating /init: setfilecon: symbol not found [ 12.533548] Kernel panic - not syncing: Attempted to kill init! exitcode=0x00007f00 [ 12.534694] CPU: 3 PID: 1 Comm: init Not tainted 5.10.110 #1 [ 12.535197] Hardware name: Rockchip RK3588S TABLET P101 Board (DT) 到此处后报了panic,启动失败了,通过追查代码发现,其启动到了init/main.c中的kernel_init函数,运行到了ret = run_init_process("/init"); 处,看打印信息和源码,感觉像是再做init 的时候缺少了 libselinux.z.so、Restorecon这些库和模块导致init失败而引起的panic,查阅好久资料和尝试了几种方法,发现无法解决此问题,咨询广大网友,是否遇到过同样问题,或知晓此问题解决之法的,本人不胜感激;

    【运行环境】

    硬件:rk3588 ROM版本: DevEvoStudio版本: SDK版本:openharmony4.0release

    您尚未登录,无法参与评论,登录后可以:
    参与开源共建问题交流
    认同或收藏高质量问答
    获取积分成为开源共建先驱

    精彩评论1

    fengyunrenwu

    沙发 发表于 昨天 09:03
    需要看下rk3568编译的日志,看看编译任务是不是包含了libselinux的编译任务。另外,镜像可以通过7z软件解压,看下system/lib目录下是否存在libselinux.z.so文件。

    Copyright   ©2023  OpenHarmony开发者论坛  京ICP备2020036654号-3 |技术支持 Discuz!

    返回顶部