You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

编译AOSP8.1.0_r4刷入Pixel2后CHRE启动失败报错59求助

问题:Pixel2刷入AOSP8.1.0_r4后循环报错CHRE: Failed to start CHRE on SLPI: 59

刷入未修改的AOSP8.1.0_r4系统到Pixel2(walleye)后,设备持续循环报错CHRE: Failed to start CHRE on SLPI: 59,核心日志片段如下:

01-31 20:41:05.990  5171  5171 E CHRE    : Failed to start CHRE on SLPI: 59
01-31 20:41:10.949  5174  5174 D /vendor/bin/chre: vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:1038: Error ffffffff: apps_dev_init failed. domain 2, errno Operation not permitted
01-31 20:41:10.949  5174  5174 D /vendor/bin/chre: vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:1113: Error ffffffff: open dev -1 for domain 2 failed
01-31 20:41:10.951  5174  5174 D /vendor/bin/chre: vendor/qcom/proprietary/adsprpc/src/fastrpc_apps_user.c:571: Error 3b: remote handle invoke failed. domain 2, handle ffffffff, sc 5020000, pra 0x7fd36b6178
01-31 20:41:10.951  5174  5174 E CHRE    : Failed to deliver timestamp message from host to CHRE: 59
01-31 20:41:10.961  5174  5174 E CHRE    : Failed to start CHRE on SLPI: 59

日志中Operation not permitted和apps_dev_init failed明确指向CHRE进程无法通过fastrpc访问SLPI设备节点,推测是高通驱动集成或权限配置问题,对应驱动版本为walleye OPM1.171019.013。


解决方案

1. 重新验证驱动集成

下载对应版本的高通驱动包后,必须在AOSP源码根目录下执行驱动包内的提取脚本,确保vendor目录下的驱动文件完整覆盖。检查vendor/qcom/walleye目录下是否存在libfastrpc.so、SLPI固件(如slpi.mbn)等文件,缺失则重新执行提取脚本。

2. 修复SELinux权限规则

CHRE进程(vendor/bin/chre)没有访问fastrpc设备节点的权限,需要修改SELinux规则:

  • 打开device/google/walleye/sepolicy/vendor/vendor_chre.te,添加以下规则:
    allow chre fastrpc_device:chr_file rw_file_perms;
    
  • 确认device/google/walleye/sepolicy/vendor/file_contexts中存在如下配置:
    /dev/fastrpc    u:object_r:fastrpc_device:s0
    

3. 确认SLPI固件打包

检查AOSP编译配置,确保SLPI固件被正确打包到vendor或boot分区。可以在device/google/walleye/walleye.mk中确认是否包含固件相关的拷贝规则。

4. 重新编译并完整刷入

完成上述修改后,执行全编译:

make clean && make -j$(nproc)

刷入完整镜像(包括system、vendor、boot分区):

fastboot flashall -w

内容的提问来源于stack exchange,提问作者meteor

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.30 23:57:01