Amlogic Linux系列(四) 视频解码分析2
打算学习一下Amlogic Linux系统,目前已知的amlogic Linux系统包括
1.官方的buildroot(没有技术资料,只支持A311D/S905D3)
2.khadas ubuntu (开源,只对vim系列开发板技术支持):
KVM1-S905X
KVM2-S912
KVM3-A311D
手上有一块amlogic S912的盒子一直没用,buildroot是没法用了,准备将KVM2的ubuntu系统移植到这块板子上,并移植后相关驱动,并做后续的功能测试
这块板子的基本配置:
S912+LPDDR3+32G带RTC数码管
一、概述
上一章测试了khadas 自带的mpv播放器直接播视频是没有走硬解的,播放视频卡顿。为此研究和对比khadas 的代码,发现khadas是加入了amlogic硬解的,但是应该是上层没法调用。
为了确认这一点,使用了相关测试程序,来验证硬解码驱动。经确认是可以的。
相关打印:
[ 350.125624] DI: unreg f
[ 350.127619] pts hit 0, pts missed 0, i hit 0, missed 0
[ 350.127638] total frame 0, avi_flag 0, rate 3840
[ 350.127887] vdec_release instance ffffff800ea2b000, total 1
[ 350.128910] the clk_hevc_mux clock off, ref cnt: -7
[ 350.128959] the clk_vdec_mux clock off, ref cnt: 0
[ 350.128979] the vdec clock off, ref cnt: 0
[ 350.128998] the parser_top clock off, ref cnt: 0
[ 350.129015] the demux clock off, ref cnt: 0
[ 350.129407] fb: osd[0] enable: 1 (ttyx)
[ 356.096944] fb: osd[0] enable: 0 (ttyx)
[ 356.107191] video_global_output_store(1)
[ 356.117039] the demux clock on, ref cnt: 1
[ 356.117065] the parser_top clock on, ref cnt: 1
[ 356.117083] the vdec clock on, ref cnt: 1
[ 356.117123] the clk_vdec_mux clock on, ref cnt: 1
[ 356.117149] vdec mux clock is 500000000 Hz
[ 356.117265] vdec_create instance ffffff800ea64000, total 1
[ 356.117414] no drmmode
[ 356.117473] The fw has been loaded.
[ 356.121055] Video stbuf alloced at 00000000a3000000, secure = 0, size = 10485760
[ 356.121118] vdec_init, dev_name:amvdec_vc1, vdec_type=VDEC_TYPE_SINGLE
[ 356.121133] vdec_init set vfm decoder ffffff800ea64000
[ 356.126917] vvc1_init, format 11
[ 356.126949] decoder_bmmu_box_alloc_box, tvp_flags = 0
[ 356.126964] WVC1 dec format
[ 356.126984] [LOCAL], the fw (vc1) will be loaded.
[ 356.129716] vdec_request_irq ffffff80026340c0, vvc1-irq
[ 356.130883] di_receiver_event_fun: vframe provider reg ppmgr
[ 356.131033] DI: reg f
[ 356.138215] vdec_init, vf_provider_name =
[ 356.138893] video first pts = 0
[ 356.138913] vdec_request_irq ffffff8002309f98, parser
[ 356.205380] DI: di_receiver_event_fun , is_bypass() 1 trick_mode 0 bypass_all 0
[ 356.205398] DI: di_receiver_event_fun: unreg
[ 356.205410] DI: provider name:(null)
[ 356.205557] DI: di_unreg_process unreg start 1.
[ 356.205591] VD1 AFBC 0x0.
[ 356.205612] DI: di_unreg_process vf unreg cost 0 ms.
[ 356.205624] DI: di_unreg_process unreg stop 1.
[ 356.205700] di_unreg_process_irq disable di mirror image.
[ 356.205711] DI: di_unreg_process_irq:cma release req time: 56132 ms
[ 356.205758] di_cma_release:release 0 buffer use 0 ms(56132~56132)
[ 356.208848] DI: unreg f
[ 356.211352] pts hit 0, pts missed 0, i hit 0, missed 0
[ 356.211374] total frame 0, avi_flag 0, rate 3840
[ 356.215434] vdec_release instance ffffff800ea64000, total 1
[ 356.216513] the clk_hevc_mux clock off, ref cnt: -8
[ 356.216563] the clk_vdec_mux clock off, ref cnt: 0
[ 356.216585] the vdec clock off, ref cnt: 0
[ 356.216603] the parser_top clock off, ref cnt: 0
[ 356.216620] the demux clock off, ref cnt: 0
[ 356.217039] fb: osd[0] enable: 1 (ttyx)
[ 358.672936] fb: osd[0] enable: 0 (ttyx)
[ 358.676404] video_global_output_store(1)
[ 367.113682] fb: osd[0] enable: 0 (ttyx)
[ 367.118266] video_global_output_store(1)
[ 371.051434] fb: osd[0] enable: 0 (ttyx)
[ 371.055476] video_global_output_store(1)
[ 384.099813] fb: osd[0] enable: 0 (ttyx)
[ 384.103504] video_global_output_store(1)
[ 390.212107] fb: osd[0] enable: 0 (ttyx)
[ 390.224701] video_global_output_store(1)
[ 390.232051] the demux clock on, ref cnt: 1
[ 390.232077] the parser_top clock on, ref cnt: 1
[ 390.232094] the vdec clock on, ref cnt: 1
[ 390.232135] the clk_vdec_mux clock on, ref cnt: 1
[ 390.232162] vdec mux clock is 500000000 Hz
[ 390.232277] vdec_create instance ffffff800ea9d000, total 1
[ 390.232390] no drmmode
[ 390.232447] The fw has been loaded.
[ 390.236408] Video stbuf alloced at 00000000a3000000, secure = 0, size = 10485760
[ 390.236465] vdec_init, dev_name:amvdec_h264, vdec_type=VDEC_TYPE_SINGLE
[ 390.236479] vdec_init set vfm decoder ffffff800ea9d000
[ 390.244415] decoder_bmmu_box_alloc_box, tvp_flags = 0
[ 390.244442] H264 sysinfo: 1920x960 duration=3840, pts_outside=1
[ 390.244455] sync_outside=1, use_idr_framerate=0
[ 390.247592] 264 ucode swap area: phyaddr 00000000b4a40000, cpu vaddr ffffff800eab4000
[ 390.247668] [LOCAL], the fw (h264) will be loaded.
[ 390.247944] vdec_request_irq ffffff8002525b68, vh264-irq
[ 390.247998] di_receiver_event_fun: vframe provider reg ppmgr
[ 390.248140] DI: reg f
[ 390.258154] h264_reset_userdata_fifo: bInit: 1, ri: 0, wi: 0
[ 390.258261] vdec_init, vf_provider_name =
[ 390.258916] video first pts = 0
[ 390.258936] vdec_request_irq ffffff8002309f98, parser
[ 390.270525] Enter set parameter cmd1.
[ 390.270733] vdec mux clock is 666666666 Hz
[ 390.271001] vdec1 video changed to 3840 x 2160 60 fps clk->667MHZ
[ 390.271022] actual_dpb_size 11 max_dpb_size 5 max_ref 4
[ 390.378059] di: di_init_buf -S
[ 390.378101] DI: di_init_buf:cma alloc req time: 90308 ms
[ 390.378126] di: di_init_buf -E
[ 390.378158] di_patch_post_update_mc_sw:0x0->0x2
[ 390.438016] di_cma_alloc:alloc 10 buffer use 60 ms(90308~90368)
[ 390.444228] pre_de_buf_config:90372ms 1th source change: 0x0/0/0/0=>0x9000/1920/1080/0
[ 390.474445] video first pts = e10
[ 390.474595] [amvideo..] saturation_pre:0 hue_pre:0 mab:1000000
[ 391.290121] vdec mux clock is 285714285 Hz
[ 391.290144] vdec1 video changed to 1920 x 1080 25 fps clk->333MHZ
[ 393.653897] DI: DI: tasklet schedule cost 12ms.
[ 411.253879] DI: DI: tasklet schedule cost 12ms.
[ 412.898661] DI: di_receiver_event_fun , is_bypass() 0 trick_mode 0 bypass_all 0
[ 412.898678] DI: di_receiver_event_fun: unreg
[ 412.898690] DI: provider name:(null)
[ 412.914125] DI: di_unreg_process unreg start 1.
[ 412.914173] keep exit is skip current
[ 412.914190] video first pts = 0
[ 412.914198] VD1 AFBC 0x0.
[ 412.914219] DI: di_unreg_process vf unreg cost 0 ms.
[ 412.914231] DI: di_unreg_process unreg stop 1.
[ 412.914316] di_unreg_process_irq disable di mirror image.
[ 412.914326] di_patch_post_update_mc_sw:0x2->0x0
[ 412.914334] DI: di_unreg_process_irq:cma release req time: 112844 ms
[ 412.917500] di_cma_release:release 10 buffer use 0 ms(112844~112844)
[ 412.917556] DI: unreg f
[ 412.924465] vdec mux clock is 285714285 Hz
[ 412.924487] vdec1 video changed to 0 x 0 0 fps clk->333MHZ
[ 412.924770] vdec_release instance ffffff800ea9d000, total 1
[ 412.926634] the clk_hevc_mux clock off, ref cnt: -9
[ 412.926679] the clk_vdec_mux clock off, ref cnt: 0
[ 412.926702] the vdec clock off, ref cnt: 0
[ 412.926721] the parser_top clock off, ref cnt: 0
[ 412.926738] the demux clock off, ref cnt: 0
[ 412.927138] fb: osd[0] enable: 1 (ttyx)
[ 417.312544] fb: osd[0] enable: 0 (ttyx)
[ 417.318588] video_global_output_store(1)
[ 417.328461] the demux clock on, ref cnt: 1
[ 417.328486] the parser_top clock on, ref cnt: 1
[ 417.328504] the vdec clock on, ref cnt: 1
[ 417.328541] the clk_vdec_mux clock on, ref cnt: 1
[ 417.328618] vdec mux clock is 500000000 Hz
[ 417.328733] vdec_create instance ffffff800eae5000, total 1
[ 417.328885] no drmmode
[ 417.328945] The fw has been loaded.
[ 417.332987] Video stbuf alloced at 00000000a3000000, secure = 0, size = 10485760
[ 417.333053] vdec_init, dev_name:amvdec_h264, vdec_type=VDEC_TYPE_SINGLE
[ 417.333068] vdec_init set vfm decoder ffffff800eae5000
[ 417.334886] decoder_bmmu_box_alloc_box, tvp_flags = 0
[ 417.334913] H264 sysinfo: 1920x960 duration=3840, pts_outside=1
[ 417.334926] sync_outside=1, use_idr_framerate=0
[ 417.335929] 264 ucode swap area: phyaddr 00000000b4a40000, cpu vaddr ffffff800eafc000
[ 417.335999] [LOCAL], the fw (h264) will be loaded.
[ 417.336273] vdec_request_irq ffffff8002525b68, vh264-irq
[ 417.336338] di_receiver_event_fun: vframe provider reg ppmgr
[ 417.340248] DI: reg f
[ 417.341018] h264_reset_userdata_fifo: bInit: 1, ri: 0, wi: 0
[ 417.341098] vdec_init, vf_provider_name =
[ 417.343314] video first pts = 0
[ 417.343338] vdec_request_irq ffffff8002309f98, parser
[ 417.345718] Enter set parameter cmd1.
[ 417.346613] vdec mux clock is 666666666 Hz
[ 417.346632] vdec1 video changed to 3840 x 2160 60 fps clk->667MHZ
[ 417.346651] actual_dpb_size 11 max_dpb_size 5 max_ref 4
[ 417.374029] di: di_init_buf -S
[ 417.374074] DI: di_init_buf:cma alloc req time: 117304 ms
[ 417.374100] di: di_init_buf -E
[ 417.374131] di_patch_post_update_mc_sw:0x0->0x2
[ 417.380362] di_cma_alloc:alloc 10 buffer use 4 ms(117304~117308)
[ 417.384180] pre_de_buf_config:117312ms 1th source change: 0x0/0/0/0=>0x9000/1920/1080/0
[ 417.401444] video first pts = e10
[ 418.213933] vdec mux clock is 285714285 Hz
[ 418.213954] vdec1 video changed to 1920 x 1080 25 fps clk->333MHZ
[ 481.253887] DI: DI: tasklet schedule cost 12ms.
[ 531.453872] DI: DI: tasklet schedule cost 12ms
cat vfm/map 打印
khadas@Khadas:/sys/class$
khadas@Khadas:/sys/class$
khadas@Khadas:/sys/class$ cat vfm/map
[00] default { decoder(1) ppmgr(1) deinterlace(1) amvideo}
[01] default_amlvideo2 { vdin1(0) amlvideo2.1}
[02] dvblpath { dvbldec(0) amvideo}
[03] dvelpath { dveldec(0) dvel}
[04] dvhdmiin { dv_vdin(0) amvideo}provider list:decoder.h264ppmgrdeinterlacereceiver list:vfm_grabberamvideovideopipdeinterlaceamlvideoamlvideo2.0amlvideo2.1ppmgrionvideovideosync.0
khadas@Khadas:/sys/class$
Amlogic Linux系列(四) 视频解码分析2相关推荐
- Amlogic Linux系列(二)新增测试驱动
用手上的Amlogic S912板子成功刷入了Khadas系统,开始做一些驱动编程的尝试.编写一个测试驱动 打算学习一下Amlogic Linux系统,目前已知的amlogic Linux系统包括 1 ...
- Amlogic Linux系列(一)S912盒子刷Khadas ubuntu系统
打算学习一下Amlogic Linux系统,目前已知的amlogic Linux系统包括 1.官方的buildroot(没有技术资料,只支持A311D/S905D3) 2.khadas ubuntu ...
- Linux系列-Red Hat5平台下的LAMP网站服务搭建(四)
Linux系列-Red Hat5平台下的LAMP网站服务搭建(四)<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com: ...
- Glide系列(四) — Glide缓存流程分析
文章目录 一.概述 1.1 背景 1.2 系列文章 二.准备知识 2.1 Glide 的缓存分层结构 2.2 Glide 缓存相关类的关联关系 三.缓存的获取流程 3.1 缓存获取的入口 3.2 内存 ...
- 转载_LKM backdoor研究linux系列--insmod源码分析篇
问题的提出是前一阵和lgx聊天发现,一个被strip的module也可以被成功的 insmod,当时知道一些insmod 的原理觉得不太可能,因为一个正常的module文件 其实就是标准的ELF格 ...
- [转]LKM backdoor研究linux系列--insmod源码分析篇
转自:http://bbs.chinaunix.net/forum.php?mod=viewthread&tid=527771 作者:jbtzhm <jbtzhm@nsfocus.com ...
- 从需求的角度去理解Linux系列:总线、设备和驱动
<从需求的角度去理解Linux系列:总线.设备和驱动>是一篇有关如何学习嵌入式Linux系统的方法论文章,也是从需求的角度去理解Linux系统软件的开篇.这是作者精心撰写的经验总结,希望嵌 ...
- Hadoop实战系列之MapReduce 分析 Youtube视频数据
Hadoop实战系列之MapReduce 分析 Youtube视频数据 一.实战介绍 MapReduce 是 Hadoop 的计算框架. 在运行一个 MR 程序时,任务过程被分为两个阶段:Map 阶段 ...
- dos攻击命令_Kali Linux系列之拒绝服务攻击(DOS)实战(下)
(你的世界是个什么样的世界?你说,我们倾听!) 利用系统漏洞进行拒绝服务攻击 1.利用系统漏洞 ...
- Kali Linux系列之拒绝服务攻击(DOS)实战(下)
(你的世界是个什么样的世界?你说,我们倾听!) 利用系统漏洞进行拒绝服务攻击 1.利用系统 ...
最新文章
- 第三代测序平台简介-单分子实时测序
- model1模式变为mv模式,实现业务逻辑和画面的分离
- 2022-01-23
- c语言 为什么i%3cn 1,c语言中n+1个基础且容易出错的知识点
- 渗透测试(Penetration Testing)
- Linux X64下汇编学习:C语言调用汇编代码,汇编中调用C语言函数
- 《华林科纳-半导体工艺》PVA 刷擦洗
- 使用Composer部署laravel框架
- 公司要求我提供竞业协议证明材料,而新公司和我原公司存在竞争关系,且我已经入职,请问如何规避违约风险?
- 影视搜索播放PHP源码_可对接资源网
- 常用的数据统计分析软件
- 师董正伟:商务部受理微软涉垄断案
- 怎样让自己的【微信公众号】快速涨粉?
- 37. Hard Disk Drives
- 40W-100W系列PD快充IC方案,AH6680,高效简洁的升降压芯片
- 联调中通wincall平台-踩坑指南
- 4.7 51单片机-DS1302 实时时钟芯片
- [渝粤教育] 保定学院 艺术教育 参考 资料
- 基于watermark.js给图片添加水印
- 图像处理---亚像素
热门文章
- [CSP-S模拟测试]:跳房子(模拟)
- 群晖NAS使用Docker安装迅雷离线下载出现the active key is not valid.
- Android ANR 触发原理
- coldfusion_ColdFusion破坏神话
- word涂改涂掉图片_word画图-厉害了Word哥!原来还可以这样画图
- 手机重装android系统,安卓手机系统怎样重装
- 目标检测之DarkNet-DarkNet源码解读<二>训练篇
- 用c语言实现图片的任意倍数缩小和放大
- latex编译报错:Font ntx-Regular- tlf-ot1r at 438 not found
- 梁念坚:从MOTO到微软 从无缝连接到统一沟通