summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorShixiang Zheng <shixiang.zheng@rock-chips.com>2018-04-25 15:19:19 +0800
committerTao Huang <huangtao@rock-chips.com>2018-04-27 10:43:43 +0800
commit9fd9c79820e9e0338c7913137f6a4dc1b8be1ae0 (patch)
tree5791c09185294f958c2c7813d4707222eaf4e5a2 /include
parent1c40af5de0ac8ac6670f417db06b5cee8233191c (diff)
drm/rockchip: add a debug node to dump buf from application
dump path: /data/vop_buf debug nod: d/dri/0/ff900000.vop/vop_dump/dump echo dump > dump to dump one frame echo dumpon > dump to start vop keep dumping echo dumpoff > dump to stop keep dumping echo dumpn > dump n is the number of dump times if fd err -3 try rm -r /data/vopbuf echo dump1 > dump can fix it if fd err -28 save needed data try rm -r /data/vopbuf Change-Id: Id5fefa428db1b5669ceae418cd8bddfa52e52f61 Signed-off-by: Shixiang Zheng <shixiang.zheng@rock-chips.com>
Diffstat (limited to 'include')
-rw-r--r--include/drm/drm_crtc.h40
1 files changed, 40 insertions, 0 deletions
diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h
index 1ff48539154a..4b06e1aa2885 100644
--- a/include/drm/drm_crtc.h
+++ b/include/drm/drm_crtc.h
@@ -525,6 +525,31 @@ struct drm_crtc_funcs {
void (*early_unregister)(struct drm_crtc *crtc);
};
+#if defined(CONFIG_ROCKCHIP_DRM_DEBUG)
+struct vop_dump_info {
+ int win_id;
+ int area_id;
+ unsigned int pitches;
+ unsigned int height;
+ u32 pixel_format;
+ bool AFBC_flag;
+ bool yuv_format;
+ unsigned long offset;
+ unsigned long num_pages;
+ struct page **pages;
+};
+
+struct vop_dump_list {
+ struct list_head entry;
+ struct vop_dump_info dump_info;
+};
+
+enum vop_dump_status {
+ DUMP_DISABLE = 0,
+ DUMP_KEEP
+};
+#endif
+
/**
* struct drm_crtc - central CRTC control structure
* @dev: parent DRM device
@@ -629,6 +654,21 @@ struct drm_crtc {
* context.
*/
struct drm_modeset_acquire_ctx *acquire_ctx;
+
+#if defined(CONFIG_ROCKCHIP_DRM_DEBUG)
+ /**
+ * @vop_dump_status the status of vop dump control
+ * @vop_dump_list_head the list head of vop dump list
+ * @vop_dump_list_init_flag init once
+ * @vop_dump_times control the dump times
+ * @frme_count the frame of dump buf
+ */
+ enum vop_dump_status vop_dump_status;
+ struct list_head vop_dump_list_head;
+ bool vop_dump_list_init_flag;
+ int vop_dump_times;
+ int frame_count;
+#endif
};
/**