blob: 1ca7015f1da3fad2e9dc8bd33cce70dec2562b3d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
#ifndef ISP_VIDEO_H
#define ISP_VIDEO_H
#include <linux/mutex.h>
#include <linux/videodev2.h>
#include <media/media-entity.h>
#include <media/v4l2-dev.h>
#include <media/v4l2-device.h>
#include <media/v4l2-fh.h>
#include <media/v4l2-mediabus.h>
#include <media/videobuf2-v4l2.h>
struct isp_buffer {
struct vb2_v4l2_buffer vb;
dma_addr_t addr[3];
struct list_head queue;
};
struct isp_video;
struct isp_video_ops {
int (*queue_buffer)(struct isp_video *vid, struct isp_buffer *buf);
int (*flush_buffers)(struct isp_video *vid,
enum vb2_buffer_state state);
};
struct isp_format_info;
struct isp_video {
struct isp *isp;
struct vb2_queue vb2_q;
struct video_device vdev;
struct media_pad pad;
struct v4l2_format active_fmt;
enum v4l2_buf_type type;
struct media_pipeline pipe;
const struct isp_video_ops *ops;
struct mutex lock;
struct mutex q_lock;
unsigned int bpl_alignment;
unsigned int line_based;
unsigned int nformats;
unsigned int payload;
const struct isp_format_info *formats;
};
void isp_video_stop_streaming(struct isp_video *video);
int isp_video_register(struct isp_video *video, struct v4l2_device *v4l2_dev,
const char *name);
void isp_video_unregister(struct isp_video *video);
#endif /* ISP_VIDEO_H */
|