feat: Add Rockchip MPP plugin for hardware encoder/decoder monitoring#3514
Open
csvke wants to merge 1 commit intonicolargo:developfrom
Open
feat: Add Rockchip MPP plugin for hardware encoder/decoder monitoring#3514csvke wants to merge 1 commit intonicolargo:developfrom
csvke wants to merge 1 commit intonicolargo:developfrom
Conversation
…itoring - New plugin: glances/plugins/mpp/ with Rockchip MPP backend - Reads per-engine load/utilization from /proc/mpp_service/load - Tracks active sessions from /proc/mpp_service/sessions-summary - Auto-enables load_interval when not set - Displays RKVENC, RKVDEC, RKJPEGD engines with load % and session count - TUI: Added to top bar with hotkey '8' to toggle - WebUI: Vue component, uiconfig, CSS, rebuilt bundle - Tested on Rockchip RV1126B-P with ffmpeg rkmpp HW transcode
Owner
|
Hi @csvke thanks for the PR. Before merging into develop some changes are needed:
Note: the plugin should be disabled by default because it is not a top stat to monitor on a system.
Thanks ! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds a new MPP (Media Process Platform) plugin to monitor Rockchip hardware video encoder/decoder engines in real time. This is the codec counterpart to the existing NPU plugin.
Rockchip SoCs expose per-engine load and session information through
/proc/mpp_service/. This plugin reads that data and displays it in both the TUI and WebUI.What it monitors
For each engine:
Implementation
Backend (
glances/plugins/mpp/)cards/mpp.py—MPPStatsdataclasscards/rockchip_mpp.py— Reads/proc/mpp_service/loadand/proc/mpp_service/sessions-summary__init__.py—MppPluginclass withfields_description, history tracking, alert thresholds, and curses renderingKey details:
/proc/mpp_service/load_intervalto 1000ms if not already configured (required for the kernel to report load stats)21f40000.rkvenc load: 24.80% utilization: 24.39%TUI (
glances/outputs/glances_curses.py)'mpp'to the_topbar between NPU and GPU8toggles MPP display @nicolargo you may want it with another hotkey, you decide :)fullquicklookmethodsWebUI
plugin-mpp.vueApp.vue(import, component, template,hasMpp()computed property)uiconfig.jsontopMenustyle.scssConfiguration
Add to
glances.conf:Testing
Tested on Rockchip RV1126B-P board with ffmpeg rkmpp hardware transcode:
# Generate load: HW decode → HW encode ffmpeg -c:v h264_rkmpp -i input.mp4 -c:v h264_rkmpp -b:v 2M output.mp4TUI output (
glances --stdout mpp):Results during H.264 HW transcode:
Affected devices
/proc/mpp_service/(RK3588, RK3576, RK3568, RK3566, RK3399, etc.)/proc/mpp_service/availability)