5.3. 多媒体系统调试指南
5.3.1. 控制节点
5.3.1.1. tuning server
功能:开启 tuning server。
说明:
使用
命令:
echo 1 > /sys/kernel/debug/isp/tune
5.3.1.2. cam-service
功能:控制 cam-service 输出 log 等级。
说明:
使用
命令:
echo 31 31 31 > /sys/kernel/debug/isp/log
5.3.1.3. libcam/libvpf
功能:控制 libcam/libvpf 的
说明:
使用
命令:
export CAM_LOGLEVEL=4
export VPF_LOGLEVEL=4
5.3.2. 统计信息节点
5.3.2.1. VPU 模块调试信息
VENC 编码
在cat /sys/kernel/debug/ 路径/app/platform_samples/sample_codec 为例,其中
[encode]
; 启用编码 , 按位运算
; 0x0 表示不启用编码
; 0x01 表示只启用 venc_stream1 编码流
; 0x02 表示只启用 venc_stream2 编码流
; 0x04 表示只启用 venc_stream3 编码流
; 0x08 表示只启用 venc_stream4 编码流
; 0x10 表示只启用 venc_stream5 编码流
; 0x03 表示只启用前两路编码流( venc_stream1 和 venc_stream2 ), 0x07 表示启用前三路编码流 , 0x0f 表示启用前四路编码流,以此类推
encode_streams = 0x1
[venc_stream1]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 0
width = 1920
height = 1080
frame_rate = 30
bit_rate = 8192
input = 1920x1080_NV12.yuv
output = 1920x1080_30fps.h264
frame_num = 100
external_buffer = 1
profile = h264_main@L4
[venc_stream2]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 1
width = 1280
height = 720
frame_rate = 25
bit_rate = 4096
input = 1280x720_NV12.yuv
output = 1280x720_25fps.h265
frame_num = 100
profile = h265_main@L4%high_tier
[venc_stream3]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 3
width = 1280
height = 720
frame_rate = 25
bit_rate = 4096
input = 1280x720_NV12.yuv
output = 1280x720.jpg
frame_num = 100
[venc_stream4]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 0
width = 640
height = 480
frame_rate = 30
bit_rate = 8192
input = 640x480_nv12.yuv
output = 640x480_30fps.h264
frame_num = 1000
运行
默认使能一路 H264 编码: encode_streams = 0x1
root@buildroot:/app/platform_samples/sample_codec# ./sample_codec
打印输出:
Config file: codec_config.ini
encode_streams: 0x1
decode_streams: 0x0
Encoding video...
Encode params...
codec_type: 0, width: 1920, height: 1080, frame_rate: 30, bit_rate: 8192, input_file: 1920x1080_NV12.yuv, output_file: 1920x1080_30fps.h264, frame_num: 100, profile: h264_main@L4, external_buffer: 1 performance_test:0
encode_video_external_buffer...
Encode idx: 0, init successful
Encode idx: 0, start successful
dequeue input buffer. src_idx(0), user_ptr((nil))
Encode idx: 0, frame= 1
on_encode_input_buffer_consumed userdata((nil)), inputBuffer->user_ptr(0xffffb0024810)
dequeue input buffer. src_idx(1), user_ptr((nil))
Encode idx: 0, frame= 2
on_encode_input_buffer_consumed userdata((nil)), inputBuffer->user_ptr(0xffffb0024fc0)
dequeue input buffer. src_idx(2), user_ptr((nil))
Encode idx: 0, frame= 3
....
命令:
cat /sys/kernel/debug/vpu/venc
功能:获取
输出
----encode enc param----
enc_idx enc_id profile level width height pix_fmt fbuf_count extern_buf_flag bsbuf_count bsbuf_size mirror rotate
0 h264 unspecified unspecified 1920 1080 1 5 0 8 3110912 0 0
----encode h264cbr param----
enc_idx rc_mode intra_period intra_qp bit_rate frame_rate initial_rc_qp vbv_buffer_size mb_level_rc_enalbe min_qp_I max_qp_I min_qp_P max_qp_P min_qp_B max_qp_B hvs_qp_enable hvs_qp_scale qp_map_enable max_delta_qp
0 h264cbr 30 30 8192 30 20 20 1 8 50 8 50 8 50 1 2 0 10
----encode gop param----
enc_idx enc_id gop_preset_idx custom_gop_size decoding_refresh_type
0 h264 1 0 2
----encode intra refresh----
enc_idx enc_id intra_refresh_mode intra_refresh_arg
0 h264 0 1
----encode longterm ref----
enc_idx enc_id use_longterm longterm_pic_period longterm_pic_using_period
0 h264 0 0 0
----encode roi_params----
enc_idx enc_id roi_enable roi_map_array_count
0 h264 0 0
----encode h264 entropy params----
enc_idx enc_id entropy_coding_mode
0 h264 CABAC
----encode h264 slice params----
enc_idx enc_id h264_slice_mode h264_slice_arg
0 h264 0 0
----encode h264 deblk filter----
enc_idx enc_id disable_deblocking_filter_idc slice_alpha_c0_offset_div2 slice_beta_offset_div2
0 h264 1 0 0
----encode h264 timing----
enc_idx enc_id vui_num_units_in_tick vui_time_scale fixed_frame_rate_flag
0 h264 1000 60000 0
----encode h264_intra_pred----
enc_idx enc_id constrained_intra_pred_flag
0 h264 0
----encode h264_transform----
enc_idx enc_id transform_8x8_enable chroma_cb_qp_offset chroma_cr_qp_offset user_scaling_list_enable
0 h264 1 0 0 0
----encode h264 vui----
enc_idx enc_id aspect_ratio_info_present_flag aspect_ratio_idc sar_width sar_height overscan_info_present_flag overscan_appropriate_flag video_signal_type_present_flag video_format video_full_range_flag colour_description_present_flag colour_primaries transfer_characteristics matrix_coefficients vui_timing_info_present_flag vui_num_units_in_tick vui_time_scale vui_fixed_frame_rate_flag bitstream_restriction_flag
0 h264 0 0 0 0 0 0 1 0 1 0 0 0 0 1 1000 60000 0 0
----encode 3dnr----
enc_idx enc_id nr_y_enable nr_cb_enable nr_cr_enable nr_est_enable nr_intra_weightY nr_intra_weightCb nr_intra_weightCr nr_inter_weightY nr_inter_weightCb nr_inter_weightCr nr_noise_sigmaY nr_noise_sigmaCb nr_noise_sigmaCr
0 h264 0 0 0 0 0 0 0 0 0 0 0 0 0
----encode smart bg----
enc_idx enc_id bg_detect_enable bg_threshold_diff bg_threshold_mean_diff bg_lambda_qp bg_delta_qp s2fme_disable
0 h264 0 0 0 0 0 0
----encode status----
enc_idx enc_id cur_input_buf_cnt cur_output_buf_cnt left_recv_frame left_enc_frame total_input_buf_cnt total_output_buf_cnt fps
0 h264 0 1 0 0 28985 28985 30
参数
| 调试信息 |
状态参数 | 说明 |
|---|---|---|
| encode enc param | 基础 |
enc_idx:编码 |
| encode h265cbr param | CBR 码率 |
enc_idx:编码 |
| encode gop param | GOP 参数 | enc_idx:编码 |
| encode intra refresh | 帧 |
enc_idx:编码 |
| encode longterm ref | 长期 |
enc_idx:编码 |
| encode roi_params | ROI 参数 | enc_idx:编码 |
| encode mode_decision 1 | 块 |
各种 |
| encode mode_decision 2 | 块 |
各种 |
| encode h265_transform | Transform 参数 | enc_idx:编码 |
| encode h265_pred_unit | 预测 |
enc_idx:编码 |
| encode h265 timing | Timing 参数 | enc_idx:编码 |
| encode h265 slice params | Slice 参数 | enc_idx:编码 |
| encode h265 deblk filter | 去 |
enc_idx:编码 |
| encode h265 sao param | SAO 参数 | enc_idx:编码 |
| encode status | 当前 |
enc_idx:编码 |
说明:
VPU(视频
VDEC 解码
以 /app/platform_samples/sample_codec 为例,其中
[decode]
; 启用解码,按位运算
; 0x0 表示不启用解码
; 0x01 表示只启用 vdec_stream1 解码流
; 0x02 表示只启用 vdec_stream2 解码流
; 0x03 表示只启用前两路解码流( vdec_stream1 和 vdec_stream2 ), 0x07 表示启用前三路解码流 , 0x0f 表示启动前四路解码流,以此类推
decode_streams = 0x0
[vdec_stream1]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 0
width = 1920
height = 1080
input = 1920x1080_30fps.h264
output = 1920x1080_NV12.yuv
[vdec_stream2]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 1
width = 1280
height = 720
input = 1280x720_25fps.h265
output = 1280x720_NV12.yuv
[vdec_stream3]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 3
width = 1280
height = 720
input = 1280x720.jpg
output = 1280x720_NV12.yuv
[vdec_stream4]
; 编码类型( 0 : H264 , 1 : H265 , 2 : MJPEG, 3 : JPEG)
codec_type = 0
width = 640
height = 480
input = 640x480_30fps.h264
output = 640x480_nv12.yuv
运行
关闭编码,启动 vdec_stream1 解码
root@buildroot:/app/platform_samples/sample_codec# ./sample_codec -e 0 -d 0x1
打印输出:
Config file: codec_config.ini
encode_streams: 0x0
decode_streams: 0x1
Decode params...
codec_type: 0, width: 1920, height: 1080, input_file: 1920x1080_30fps.h264, output_file: 1920x1080_NV12.yuv
Decode idx: 0, init successful
Init video decode instance 0 successful
Decode idx: 0, start successful
Decoding video...
Decoding output video...
[h264 @ 0xffff68000d50] Stream #0: not enough frames to estimate rate; consider increasing probesize
p_param->frame_num: 98
decode output continue
No more valid data available for decoding, avpacket.size: 0. Decoder will exit due to timeout after fetching decoded output.
decode output continue
Decode idx: 0, hb_mm_mc_dequeue_output_buffer timed out (possibly normal exit due to lack of data)
decode output continue
Decode idx: 0, stop successful
Decode idx: 0, deinit successful
deinit video decode instance 0 successful
....
命令:
cat /sys/kernel/debug/vpu/vdec
功能:获取 vdec 解码
输出
----decode param----
dec_idx dec_id feed_mode pix_fmt bitstream_buf_size bitstream_buf_count frame_buf_count
0 h264 1 1 3110912 3 3
----h264 decode param----
dec_idx dec_id reorder_enable skip_mode bandwidth_Opt
0 h264 1 0 1
----decode frameinfo----
dec_idx dec_id display_width display_height
0 h264 1920 1080
----decode status----
dec_idx dec_id cur_input_buf_cnt cur_output_buf_cnt total_input_buf_cnt total_output_buf_cnt fps
0 h264 0 1 66 62 12
参数
| 调试信息 |
状态参数 | 说明 |
|---|---|---|
| decode param | 基础 |
dec_idx:解码 |
| h264 decode param | H264 解码 |
dec_idx:解码 |
| decode frameinfo | 解码 |
dec_idx:解码 |
| decode status | 当前 |
dec_idx:解码 |
说明:
VPU(视频
5.3.2.2. JPU 模块调试信息
JENC 编码
以 /app/platform_samples/sample_codec 为例,输入
启用 vdec_stream3 使用 jpeg 编码
root@buildroot:/app/platform_samples/sample_codec# ./sample_codec -e 0x4
打印输出:
root@buildroot:/app/platform_samples/sample_codec# ./sample_codec -e 0x4
Config file: codec_config.ini
encode_streams: 0x4
decode_streams: 0x0
Encoding video...
Encode params...
codec_type: 3, width: 1280, height: 720, frame_rate: 25, bit_rate: 4096, input_file: 1280x720_NV12.yuv, output_file: 1280x720.jpg, frame_num: 100, profile: , external_buffer: 0 performance_test:0
encode_video...
Encode idx: 0, init successful
Encode idx: 0, start successful
Encode idx: 0, frame= 1
Encode idx: 0, frame= 2
....
Encode idx: 0, frame= 100
命令:
cat /sys/kernel/debug/jpu/jenc
功能:获取 JPEG 编码
输出
----encode param----
enc_idx enc_id width height pix_fmt fbuf_count extern_buf_flag bsbuf_count bsbuf_size mirror rotate
0 jpeg 1280 720 1 3 0 3 1384448 0 0
----encode rc param----
enc_idx rc_mode frame_rate quality_factor
0 noratecontrol 0 50
----encode status----
enc_idx enc_id cur_input_buf_cnt cur_output_buf_cnt left_recv_frame left_enc_frame total_input_buf_cnt total_output_buf_cnt fps
0 jpeg 0 1 0 0 40 40 28
参数
| 调试信息 |
状态参数 | 说明 |
|---|---|---|
| encode param | 基础 |
enc_idx:编码 |
| encode rc param | mjpeg 码率 |
enc_idx:编码 |
| encode status | 当前 |
enc_idx:编码 |
说明:
JPU(图片
JDEC 解码
以 /app/platform_samples/sample_codec 为例,输入
启用 vdec_stream3 进行 jpeg 解码
root@buildroot:/app/platform_samples/sample_codec# ./sample_codec -e 0 -d 0x4
打印输出:
Config file: codec_config.ini
encode_streams: 0x4
decode_streams: 0x0
Encoding video...
Encode params...
codec_type: 3, width: 1280, height: 720, frame_rate: 25, bit_rate: 4096, input_file: 1280x720_NV12.yuv, output_file: 1280x720.jpg, frame_num: 100, profile: , external_buffer: 0 performance_test:0
encode_video...
Encode idx: 0, init successful
Encode idx: 0, start successful
Encode idx: 0, frame= 1
Encode idx: 0, frame= 2
....
Encode idx: 0, frame= 100
命令:
cat /sys/kernel/debug/jpu/jdec
功能:获取 jdec 解码
输出
----decode param----
dec_idx dec_id feed_mode pix_fmt bitstream_buf_size bitstream_buf_count frame_buf_count mirror rotate
0 jpeg 1 1 1382400 3 3 0 0
----decode frameinfo----
dec_idx dec_id display_width display_height
0 jpeg 0 0
----decode status----
dec_idx dec_id cur_input_buf_cnt cur_output_buf_cnt total_input_buf_cnt total_output_buf_cnt fps
0 jpeg 0 0 0 0 0
参数
| 调试信息 |
状态参数 | 说明 |
|---|---|---|
| decode param | 解码 |
dec_idx:解码 |
| decode frameinfo | 解码 |
dec_idx:解码 |
| decode status | 当前 |
dec_idx:解码 |
说明:
JPU(图片
5.3.2.3. 中断统计信息
功能:输出
命令:
watch -n 1 'grep -E "sif|isp|vse|gdc" /proc/interrupts'
输出
/proc/interrupts:40: 62: 0 0 0 0 0 0 0 0 GICv3 69 Level sif
/proc/interrupts:41: 63: 0 0 0 0 0 0 0 0 GICv3 70 Level sif
/proc/interrupts:42: 64: 54451 0 0 0 0 0 0 0 GICv3 71 Level sif
/proc/interrupts:43: 65: 0 0 0 0 0 0 0 0 GICv3 72 Level sif
/proc/interrupts:48: 70: 134309 0 0 0 0 0 0 0 GICv3 75 Level isp
/proc/interrupts:52: 74: 54342 0 0 0 0 0 0 0 GICv3 82 Level vse
/proc/interrupts:53: 75: 0 0 0 0 0 0 0 0 GICv3 80 Level gdc
说明:
打印
5.3.2.4. 帧率信息
功能:输出
命令:
cat /sys/devices/virtual/vps/flow/fps
输出
-------------------------------------------------------------------
Flow0 FPS
-------------------------------------------------------------------
vin3 ctx 0: | ich0 0 | och0 0 | och3 0 | och4 0 |
isp0 ctx 0: | ich0 0 | och0 30 |
-------------------------------------------------------------------
Flow1 FPS
-------------------------------------------------------------------
vin2 ctx 0: | ich0 0 | och0 0 | och3 0 | och4 0 |
isp0 ctx 1: | ich0 0 | och0 30 |
-------------------------------------------------------------------
Flow2 FPS
-------------------------------------------------------------------
vin0 ctx 0: | ich0 0 | och0 0 | och3 0 | och4 0 |
isp0 ctx 2: | ich0 0 | och0 30 |
-------------------------------------------------------------------
Flow3 FPS
-------------------------------------------------------------------
vin1 ctx 0: | ich0 0 | och0 0 | och3 0 | och4 0 |
isp0 ctx 3: | ich0 0 | och0 30 |
说明:
此
命令:
cat /sys/devices/virtual/vps/flow/fps_stats
输出
flowid mod c_id chn fcnt avg_fps cur_fps
0 vin2 0
0 0 0.000 0.000
8 0 0.000 0.000
11 0 0.000 0.000
12 0 0.000 0.000
0 isp0 0
0 0 0.000 0.000
8 95 10.070 0.000
0 vse0 0
0 0 0.000 0.000
8 95 10.074 0.000
9 0 0.000 0.000
10 0 0.000 0.000
11 0 0.000 0.000
12 0 0.000 0.000
13 0 0.000 0.000
0 gdc0 0
0 95 10.074 0.000
8 95 10.079 0.000
说明:
打印
"function": {
"enable_frame_id": 1,
"set_init_frame_id": 1,
"time_stamp_en": 1,
"time_stamp_mode": 3,
"ts_trigger_source": 1,
"pps_trigger_source": 6
}
5.3.2.5. 时间戳信息
功能:输出
命令:
cat /sys/devices/virtual/vps/flow/vio_delay
输出
------------------------------- pipe 0 vio info -------------------------------
frameid module FS FE QB DQ
00000515 sif 00000184.562367 00000184.595320 00000184.592899 00000184.592901
00000516 sif 00000184.595700 00000184.628653 00000184.626232 00000184.626235
00000517 sif 00000184.629033 00000184.661986 00000184.659558 00000184.659560
00000518 sif 00000184.662366 00000000.000000 00000000.000000 00000000.000000
00000514 sif 00000184.529033 00000184.561986 00000184.559557 00000184.559560
00000515 isp 00000184.593734 00000184.596138 00000184.596186 00000000.000000
00000516 isp 00000184.627070 00000184.629533 00000184.629521 00000000.000000
00000517 isp 00000184.660506 00000184.662958 00000184.662946 00000000.000000
00000513 isp 00000184.527066 00000184.529460 00000184.529506 00000000.000000
00000514 isp 00000184.560459 00000184.562863 00000184.562910 00000000.000000
00000000 vse 00000000.000000 00000184.599267 00000184.599266 00000184.596168
00000000 vse 00000000.000000 00000184.632600 00000184.632600 00000184.629503
00000000 vse 00000000.000000 00000184.666027 00000184.666026 00000184.662929
00000000 vse 00000000.000000 00000184.532586 00000184.532585 00000184.529489
00000000 vse 00000000.000000 00000184.565982 00000184.565981 00000184.562894
00000000 gdc 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 gdc 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 gdc 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 gdc 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 gdc 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 n2d 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 n2d 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 n2d 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 n2d 00000000.000000 00000000.000000 00000000.000000 00000000.000000
00000000 n2d 00000000.000000 00000000.000000 00000000.000000 00000000.000000
说明:
打印
5.3.2.6. 延时信息
功能:输出模块
命令:
cat /sys/devices/virtual/vps/flow/delay_stats
输出
---------------------------------------------------------------------------------------
flowid module ctx_id chn cur_delay_ms min_delay_ms avg_delay_ms max_delay_ms
---------------------------------------------------------------------------------------
0 vin0 0
ich0 0 0 0 0
och0 30 30 30 30
och3 0 0 0 0
och4 0 0 0 0
0 isp0 0
ich0 0 0 0 0
och0 33 33 33 34
0 vse0 0
ich0 0 0 0 0
och0 36 36 36 37
och1 36 36 36 37
och2 36 36 36 37
och3 36 36 36 37
och4 36 36 36 37
och5 36 36 36 37
说明:
SIF 在 Frame start 时,会
5.3.2.7. 丢帧信息
功能:输出模块
命令:
cat /sys/devices/virtual/vps/flow/drop_info
cat /sys/devices/virtual/vps/flow/drop_stats
说明:
第一条
5.3.2.8. 驱动 buffer 状态
功能:输出 buffer 状态。
命令:
cat /sys/devices/virtual/vps/flow/fmgr_stats
输出
------------------------------------------------------------------------------
flowid module ctx_id chn FREE REQUEST PROCESS COMPLETE USED
------------------------------------------------------------------------------
0 vin0 0
ich0 16 0 0 0 0
och0 0 5 1 0 0
0 isp0 0
ich0 10 0 0 0 6
och0 0 6 0 0 0
0 vse0 0
ich0 10 0 0 0 6
och0 0 4 0 0 0
och1 0 4 0 0 0
och2 0 4 0 0 0
och3 0 4 0 0 0
och4 0 4 0 0 0
och5 0 4 0 0 0
说明:
打印
5.3.2.9. vio 通路信息
功能:输出
命令:
cat /sys/devices/virtual/vps/flow/path_stat
输出
(active)[S0] vin0_C0*(dma)-m2m-isp0_C0-m2m-vse0_C0
说明:
打印
5.3.2.10. MIPI 中断
功能:查看 MIPI 中断
命令:
cat /proc/interrupts |grep mipi_host
输出
66: 0 0 0 0 0 0 0 0 GICv3 76 Level 3d060000.mipi_host
67: 0 0 0 0 0 0 0 0 GICv3 78 Level 3d070000.mipi_host
68: 0 0 0 0 0 0 0 0 GICv3 77 Level 3d080000.mipi_host
69: 0 0 0 0 0 0 0 0 GICv3 79 Level 3d090000.mipi_host
说明:
在 MIPI 模块
5.3.2.11. MIPI 状态寄存器
功能:查看 MIPI 中断
命令:
cat /sys/class/vps/mipi_host0/status/regs
输出
root@buildroot:/userdata/gmsl# cat /sys/class/vps/mipi_host0/status/regs
0x000: 0x30313534 - VERSION
0x004: 0x3 - N_LANES
0x008: 0x0 - CSI2_RESETN
0x040: 0x0 - PHY_SHUTDOWNZ
0x044: 0x0 - DPHY_RSTZ
0x048: 0x10000 - PHY_RX
0x04c: 0x0 - PHY_STOPSTATE
0x0cc: 0x0 - PHY_CAL
0x0a0: 0x1111 - IPI_SOFTRSTN
0x010: 0x0 - DATA_IDS_1
0x014: 0x0 - DATA_IDS_2
0x018: 0x0 - PHY_CFG
0x01c: 0x0 - PHY_MODE
0x030: 0x0 - DATA_IDS_VC1
0x034: 0x0 - DATA_IDS_VC2
0x00c: 0x0 - INT_ST_MAIN
0x0e0: 0x0 - INT_ST_PHY_FATAL
0x0f0: 0x0 - INT_ST_PKT_FATAL
0x110: 0x0 - INT_ST_PHY
0x130: 0x0 - INT_ST_LINE
0x140: 0x0 - INT_ST_IPI
0x150: 0x0 - INT_ST_IPI2
0x160: 0x0 - INT_ST_IPI3
0x170: 0x0 - INT_ST_IPI4
0x280: 0x0 - INT_ST_BNDRY_FRAME_FATAL
0x290: 0x0 - INT_ST_SEQ_FRAME_FATAL
0x2a0: 0x0 - INT_ST_CRC_FRAME_FATAL
0x2b0: 0x0 - INT_ST_PLD_CRC_FATAL
0x2c0: 0x0 - INT_ST_DATA_ID
0x2d0: 0x0 - INT_ST_ECC_CORRECT
0x0e4: 0x0 - INT_MSK_PHY_FATAL
0x0f4: 0x0 - INT_MSK_PKT_FATAL
0x114: 0x0 - INT_MSK_PHY
0x134: 0x0 - INT_MSK_LINE
0x144: 0x0 - INT_MSK_IPI
0x154: 0x0 - INT_MSK_IPI2
0x164: 0x0 - INT_MSK_IPI3
0x174: 0x0 - INT_MSK_IPI4
0x284: 0x0 - INT_MSK_BNDRY_FRAME_FATAL
0x294: 0x0 - INT_MSK_SEQ_FRAME_FATAL
0x2a4: 0x0 - INT_MSK_CRC_FRAME_FATAL
0x2b4: 0x0 - INT_MSK_PLD_CRC_FATAL
0x2c4: 0x0 - INT_MSK_DATA_ID
0x2d4: 0x0 - INT_MSK_ECC_CORRECT
0x080: 0x1010000 - IPI_MODE
0x084: 0x0 - IPI_VCID
0x088: 0x1e - IPI_DATA_TYPE
0x08c: 0x100 - IPI_MEM_FLUSH
0x090: 0x4 - IPI_HSA_TIME
0x094: 0x4 - IPI_HBP_TIME
0x098: 0x1a - IPI_HSD_TIME
0x09c: 0x0 - IPI_HLINE_TIME
0x0ac: 0x1030000 - IPI_ADV_FEATURES
0x0b0: 0x0 - IPI_VSA_LINES
0x0b4: 0x0 - IPI_VBP_LINES
0x0b8: 0x0 - IPI_VFP_LINES
0x0bc: 0x0 - IPI_VACTIVE_LINES
0x200: 0x1010000 - IPI2_MODE
0x204: 0x1 - IPI2_VCID
0x208: 0x1e - IPI2_DATA_TYPE
0x20c: 0x100 - IPI2_MEM_FLUSH
0x210: 0x4 - IPI2_HSA_TIME
0x214: 0x4 - IPI2_HBP_TIME
0x218: 0x1a - IPI2_HSD_TIME
0x21c: 0x1030000 - IPI2_ADV_FEATURES
说明:
以下
INT_ST_PHY_FATAL
[7:0]: 0xff phy_errsotsynchs_7..0 :
报错:对应 data lane 的 SOT 错 ( 未
收到 sync)。 排查:配置文件
是否 正确
[8]: 0x100 err_deskew
报错: lane 间 skew 大于 2 个 rxworldhs,数据
丢失
INT_ST_SEQ_FRAME_FATAL
[31:0]: 0xFFFFFFFF err_f_seq_vc31..0 :
报错:对应
的 VC 帧 号 不 连续,丢 帧。 排查:带宽
是否 足够, serdes 状态 和 硬件 信号
INT_ST_CRC_FRAME_FATAL
[31:0]: 0XFFFFFFFF err_frame_data_vc31..0
报错:对应 vc 上
的 帧 中 至少 有 1 个 CRC 错误 排查: serdes 状态
和 硬件 信号
INT_ST_PHY
[7:0]: 0x0000FF phy_errsoths_7..0
报错:对应 data lane 的 SOT 错 ( 未
收到 sync)。 排查:配置文件 mipiclk 和 settle 配置
是否 正确
[23:16]: 0xFF0000 phy_errsoths_7..0
报错:对应 data lane 的 SOT 错 ( 未
收到 sync)。 排查:配置文件 mipiclk 和 settle 配置
是否 正确
5.3.2.12. MIPI 中断打印
功能:查看
命令:
# 查看当前限制 :
cat /sys/class/vps/mipi_host0/param/irq_cnt
命令:
# 配置无限制 (debug 使用 ):
echo 0xffffffff > /sys/class/vps/mipi_host0/param/irq_cnt
输出
root@buildroot:/userdata/gmsl# cat /sys/class/vps/mipi_host0/param/irq_cnt
10
说明:
如果