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

IMX8MP设备Sway compositor下GStreamer性能异常及崩溃求助

IMX8MP上Sway会话中GStreamer性能骤降及崩溃问题

环境配置

基础构建环境

  • Yocto版本:kirkstone(L5.15.52_2.1.0)
  • Sway版本:1.7-5543acff(2022年1月22日,分支'v1.7')
  • wlroots版本:0.15.1
  • 构建配置:
IMAGE_INSTALL:append = " sudo sway "

用户配置(因Sway不支持root登录)

inherit extrausers
PASSWD="$5$9gounUy.ZkcjiF4H$/Xy3R25TknKrWmv/rCOJfXuDE9wecgyaVilSEymEF1C"
DEV_PASSWD="$5$C6cr07SRVZhrxjIm$2OOBCoEQ.IFORLhzc1KGgXaIqU3ru1Lr9gWYvzeR8E8"
EXTRA_USERS_PARAMS = "usermod -p '${PASSWD}' root;
    useradd -m -p '${DEV_PASSWD}' -d /home/dev dev;
    groupadd devs;
    usermod -a -G sudo,video,tty,input,devs dev;
"

设备权限配置(确保VPU访问)

sudo chgrp video /dev/mxc_*
sudo chmod 660 /dev/mxc_*

正常运行的GStreamer命令(未启动Sway时)

sudo -E gst-launch-1.0 playbin uri=<filename.mp4>

未启动Sway时该命令运行流畅,仅存在缩放问题待处理,VPU支持已确认。

问题现象

在Sway会话中执行GStreamer命令出现两类异常:

  1. 按以下步骤操作时,帧率降至1.2 FPS(正常为30 FPS):
    • 启动seatd:sudo seatd -u dev &
    • 启动Sway:sway &
    • 设置Wayland显示:export WAYLAND_DISPLAY=wayland-1
    • 执行GStreamer命令:gst-launch-1.0 playbin uri=<filename.mp4>
  2. 若使用sudo -E gst-launch-1.0 playbin uri=<filename.mp4>执行,则直接导致Sway崩溃、显示屏关闭。

日志信息

GStreamer日志

Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...

====== AIUR: 4.7.1 build on Jul 19 2022 06:15:03. ======
Core: MPEG4PARSER_06.20.06 build on May 7 2022 07:52:31
file: /usr/lib/imx-mm/parser/lib_mp4_parser_arm_elinux.so.3.2
Track 00 [video_0] Enabled
Duration: 0:00:30.033333000
Language: und
Mime:
video/x-h264, parsed=(boolean)true, alignment=(string)au, stream-format=(string)avc, 
width=(int)1920, height=(int)720, framerate=(fra
Track 01 [audio_0] Enabled
Duration: 0:00:30.549333000
Language: und
Mime:
audio/mpeg, mpegversion=(int)4, channels=(int)2, rate=(int)48000, bitrate=(int)2276, 
stream-format=(string)raw, codec_data=(buffer)11
XDG_RUNTIME_DIR (/run/user/1000) is not owned by us (uid 0), but by uid 1000! (This 
could e.g. happen if you try to connect to a non-root Pul)

====== BEEP: 4.7.1 build on Jul[ 4572.364687] remoteproc remoteproc0: powering up imx- 
dsp-rproc
19 2022 06:15:03. ======
Core: DSP decoder Wrapper build on [ 4572.376352] remoteproc remoteproc0: Booting fw 
image imx/dsp/hifi4.bin, size 804421
May 19 2022 08:49:06
file: /usr[ 4572.387226] imx-dsp-rproc 3b6e8000.dsp: Allocated carveout doesn't fit 
device address request
/lib/imx-mm/audio-codec/wrap/lib_[ 4572.397921] imx-dsp-rproc 3b6e8000.dsp: Allocated 
carveout doesn't fit device address request
dsp_wrap_arm_elinux.so
[ 4572.408902] remoteproc remoteproc0: bad phdr da 0x92400000 mem 0x408cc
[ 4572.417484] remoteproc remoteproc0: Failed to load program segments: -22
[ 4572.424384] remoteproc remoteproc0: Boot failed: -22
Error: Invalid argument
remote proc is not ready

====== BEEP: 4.7.1 build on Jul 19 2022 06:15:03. ======
Core: AAC decoder Wrapper build on Jul 25 2022 15:45:05
file: /usr/lib/imx-mm/audio-codec/wrap/lib_aacd_wrap_arm_elinux.so.3
CODEC: BLN_MAD-MMCODECS_AACD_ARM_03.09.00_ARMV8 build on Jul 25 2022 10:05:48.

====== V4L2DEC: 1.20.0 build on Jul 28 2022 06:57:16. ======
Redistribute latency...
Redistribute latency...
Redistribute latency...
Redistribute latency...
Pipeline is PREROLLED ... 
g pipeline to PLAYING ...

内核日志

[ 4572.408902] remoteproc remoteproc0: bad phdr da 0x92400000 mem 0x408cc
[ 4572.417484] remoteproc remoteproc0: Failed to load program segments: -22
[ 4572.424384] remoteproc remoteproc0: Boot failed: -2
[ 4573.789319] drm_panel_disable
[ 4573.792318] panel_simple_disable enabled=1
[ 4573.796549] panel_simple_disable - Backlihgt(off) to stop lvds signal time - STBYB 
pull L to RSTB time: 167
[ 4574.124807] imx8mp_ldb_encoder_disable
[ 4574.128692] drm_panel_unprepare
[ 4574.131832] panel_simple_unprepare prepared=1
[ 4574.136308] panel_simple_unprepare - Restart VCC time: 500
[ 4574.678516] drm_panel_prepare
[ 4574.681512] panel_simple_prepare prepared=0
[ 4574.685836] imx8mp_ldb_encoder_enable

求助内容

寻求解决Sway会话中GStreamer性能骤降及崩溃问题的方案。

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

相关产品推荐
方舟 Agent Plan

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

最近更新时间:2026.06.29 02:29:53