Commit 13fc23d3 authored by Lad, Prabhakar's avatar Lad, Prabhakar Committed by Mauro Carvalho Chehab

[media] media: davinci: vpbe: migrate driver to videobuf2

This patch migrates VPBE display driver to videobuf2 framework.
Signed-off-by: default avatarLad, Prabhakar <prabhakar.lad@ti.com>
Signed-off-by: default avatarManjunath Hadli <manjunath.hadli@ti.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent baa29837
...@@ -101,7 +101,7 @@ config VIDEO_DM644X_VPBE ...@@ -101,7 +101,7 @@ config VIDEO_DM644X_VPBE
tristate "DM644X VPBE HW module" tristate "DM644X VPBE HW module"
depends on ARCH_DAVINCI_DM644x depends on ARCH_DAVINCI_DM644x
select VIDEO_VPSS_SYSTEM select VIDEO_VPSS_SYSTEM
select VIDEOBUF_DMA_CONTIG select VIDEOBUF2_DMA_CONTIG
help help
Enables VPBE modules used for display on a DM644x Enables VPBE modules used for display on a DM644x
SoC. SoC.
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
/* Header files */ /* Header files */
#include <linux/videodev2.h> #include <linux/videodev2.h>
#include <media/v4l2-common.h> #include <media/v4l2-common.h>
#include <media/videobuf-dma-contig.h> #include <media/videobuf2-dma-contig.h>
#include <media/davinci/vpbe_types.h> #include <media/davinci/vpbe_types.h>
#include <media/davinci/vpbe_osd.h> #include <media/davinci/vpbe_osd.h>
#include <media/davinci/vpbe.h> #include <media/davinci/vpbe.h>
...@@ -62,6 +62,11 @@ struct display_layer_info { ...@@ -62,6 +62,11 @@ struct display_layer_info {
enum osd_v_exp_ratio v_exp; enum osd_v_exp_ratio v_exp;
}; };
struct vpbe_disp_buffer {
struct vb2_buffer vb;
struct list_head list;
};
/* vpbe display object structure */ /* vpbe display object structure */
struct vpbe_layer { struct vpbe_layer {
/* number of buffers in fbuffers */ /* number of buffers in fbuffers */
...@@ -69,13 +74,15 @@ struct vpbe_layer { ...@@ -69,13 +74,15 @@ struct vpbe_layer {
/* Pointer to the vpbe_display */ /* Pointer to the vpbe_display */
struct vpbe_display *disp_dev; struct vpbe_display *disp_dev;
/* Pointer pointing to current v4l2_buffer */ /* Pointer pointing to current v4l2_buffer */
struct videobuf_buffer *cur_frm; struct vpbe_disp_buffer *cur_frm;
/* Pointer pointing to next v4l2_buffer */ /* Pointer pointing to next v4l2_buffer */
struct videobuf_buffer *next_frm; struct vpbe_disp_buffer *next_frm;
/* videobuf specific parameters /* videobuf specific parameters
* Buffer queue used in video-buf * Buffer queue used in video-buf
*/ */
struct videobuf_queue buffer_queue; struct vb2_queue buffer_queue;
/* allocator-specific contexts for each plane */
struct vb2_alloc_ctx *alloc_ctx;
/* Queue of filled frames */ /* Queue of filled frames */
struct list_head dma_queue; struct list_head dma_queue;
/* Used in video-buf */ /* Used in video-buf */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment