Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions | Variables
saa7146_vv.h File Reference
#include <media/v4l2-common.h>
#include <media/v4l2-ioctl.h>
#include <media/v4l2-fh.h>
#include <media/saa7146.h>
#include <media/videobuf-dma-sg.h>

Go to the source code of this file.

Data Structures

struct  saa7146_video_dma
 
struct  saa7146_format
 
struct  saa7146_standard
 
struct  saa7146_buf
 
struct  saa7146_dmaqueue
 
struct  saa7146_overlay
 
struct  saa7146_fh
 
struct  saa7146_vv
 
struct  saa7146_ext_vv
 
struct  saa7146_use_ops
 

Macros

#define MAX_SAA7146_CAPTURE_BUFFERS   32 /* arbitrary */
 
#define BUFFER_TIMEOUT   (HZ/2) /* 0.5 seconds */
 
#define WRITE_RPS0(x)
 
#define WRITE_RPS1(x)
 
#define FORMAT_BYTE_SWAP   0x1
 
#define FORMAT_IS_PLANAR   0x2
 
#define STATUS_OVERLAY   0x01
 
#define STATUS_CAPTURE   0x02
 
#define SAA7146_USE_PORT_B_FOR_VBI   0x2 /* use input port b for vbi hardware bug workaround */
 
#define RESOURCE_DMA1_HPS   0x1
 
#define RESOURCE_DMA2_CLP   0x2
 
#define RESOURCE_DMA3_BRS   0x4
 
#define SAA7146_HPS_SOURCE_PORT_A   0x00
 
#define SAA7146_HPS_SOURCE_PORT_B   0x01
 
#define SAA7146_HPS_SOURCE_YPB_CPA   0x02
 
#define SAA7146_HPS_SOURCE_YPA_CPB   0x03
 
#define SAA7146_HPS_SYNC_PORT_A   0x00
 
#define SAA7146_HPS_SYNC_PORT_B   0x01
 
#define SAA7146_CLIPPING_MEM   (16 * 4 * sizeof(u32))
 
#define SAA7146_CLIPPING_RECT   0x4
 
#define SAA7146_CLIPPING_RECT_INVERTED   0x5
 
#define SAA7146_CLIPPING_MASK   0x6
 
#define SAA7146_CLIPPING_MASK_INVERTED   0x7
 
#define RGB08_COMPOSED   0x0217 /* composed is used in the sense of "not-planar" */
 
#define RGB15_COMPOSED   0x0213
 
#define RGB16_COMPOSED   0x0210
 
#define RGB24_COMPOSED   0x0201
 
#define RGB32_COMPOSED   0x0202
 
#define Y8   0x0006
 
#define YUV411_COMPOSED   0x0003
 
#define YUV422_COMPOSED   0x0000
 
#define YUV411_DECOMPOSED   0x100b
 
#define YUV422_DECOMPOSED   0x1009
 
#define YUV420_DECOMPOSED   0x100a
 
#define IS_PLANAR(x)   (x & 0xf000)
 
#define SAA7146_NO_SWAP   (0x0)
 
#define SAA7146_TWO_BYTE_SWAP   (0x1)
 
#define SAA7146_FOUR_BYTE_SWAP   (0x2)
 

Functions

int saa7146_register_device (struct video_device **vid, struct saa7146_dev *dev, char *name, int type)
 
int saa7146_unregister_device (struct video_device **vid, struct saa7146_dev *dev)
 
void saa7146_buffer_finish (struct saa7146_dev *dev, struct saa7146_dmaqueue *q, int state)
 
void saa7146_buffer_next (struct saa7146_dev *dev, struct saa7146_dmaqueue *q, int vbi)
 
int saa7146_buffer_queue (struct saa7146_dev *dev, struct saa7146_dmaqueue *q, struct saa7146_buf *buf)
 
void saa7146_buffer_timeout (unsigned long data)
 
void saa7146_dma_free (struct saa7146_dev *dev, struct videobuf_queue *q, struct saa7146_buf *buf)
 
int saa7146_vv_init (struct saa7146_dev *dev, struct saa7146_ext_vv *ext_vv)
 
int saa7146_vv_release (struct saa7146_dev *dev)
 
int saa7146_enable_overlay (struct saa7146_fh *fh)
 
void saa7146_disable_overlay (struct saa7146_fh *fh)
 
void saa7146_set_capture (struct saa7146_dev *dev, struct saa7146_buf *buf, struct saa7146_buf *next)
 
void saa7146_write_out_dma (struct saa7146_dev *dev, int which, struct saa7146_video_dma *vdma)
 
void saa7146_set_hps_source_and_sync (struct saa7146_dev *saa, int source, int sync)
 
void saa7146_set_gpio (struct saa7146_dev *saa, u8 pin, u8 data)
 
int saa7146_start_preview (struct saa7146_fh *fh)
 
int saa7146_stop_preview (struct saa7146_fh *fh)
 
long saa7146_video_do_ioctl (struct file *file, unsigned int cmd, void *arg)
 
int saa7146_s_ctrl (struct v4l2_ctrl *ctrl)
 
int saa7146_res_get (struct saa7146_fh *fh, unsigned int bit)
 
void saa7146_res_free (struct saa7146_fh *fh, unsigned int bits)
 

Variables

struct v4l2_ioctl_ops saa7146_video_ioctl_ops
 
struct v4l2_ioctl_ops saa7146_vbi_ioctl_ops
 
struct saa7146_use_ops saa7146_video_uops
 
struct saa7146_use_ops saa7146_vbi_uops
 

Macro Definition Documentation

#define BUFFER_TIMEOUT   (HZ/2) /* 0.5 seconds */

Definition at line 11 of file saa7146_vv.h.

#define FORMAT_BYTE_SWAP   0x1

Definition at line 30 of file saa7146_vv.h.

#define FORMAT_IS_PLANAR   0x2

Definition at line 31 of file saa7146_vv.h.

#define IS_PLANAR (   x)    (x & 0xf000)

Definition at line 258 of file saa7146_vv.h.

#define MAX_SAA7146_CAPTURE_BUFFERS   32 /* arbitrary */

Definition at line 10 of file saa7146_vv.h.

#define RESOURCE_DMA1_HPS   0x1

Definition at line 218 of file saa7146_vv.h.

#define RESOURCE_DMA2_CLP   0x2

Definition at line 219 of file saa7146_vv.h.

#define RESOURCE_DMA3_BRS   0x4

Definition at line 220 of file saa7146_vv.h.

#define RGB08_COMPOSED   0x0217 /* composed is used in the sense of "not-planar" */

Definition at line 243 of file saa7146_vv.h.

#define RGB15_COMPOSED   0x0213

Definition at line 245 of file saa7146_vv.h.

#define RGB16_COMPOSED   0x0210

Definition at line 246 of file saa7146_vv.h.

#define RGB24_COMPOSED   0x0201

Definition at line 247 of file saa7146_vv.h.

#define RGB32_COMPOSED   0x0202

Definition at line 248 of file saa7146_vv.h.

#define SAA7146_CLIPPING_MASK   0x6

Definition at line 239 of file saa7146_vv.h.

#define SAA7146_CLIPPING_MASK_INVERTED   0x7

Definition at line 240 of file saa7146_vv.h.

#define SAA7146_CLIPPING_MEM   (16 * 4 * sizeof(u32))

Definition at line 234 of file saa7146_vv.h.

#define SAA7146_CLIPPING_RECT   0x4

Definition at line 237 of file saa7146_vv.h.

#define SAA7146_CLIPPING_RECT_INVERTED   0x5

Definition at line 238 of file saa7146_vv.h.

#define SAA7146_FOUR_BYTE_SWAP   (0x2)

Definition at line 263 of file saa7146_vv.h.

#define SAA7146_HPS_SOURCE_PORT_A   0x00

Definition at line 223 of file saa7146_vv.h.

#define SAA7146_HPS_SOURCE_PORT_B   0x01

Definition at line 224 of file saa7146_vv.h.

#define SAA7146_HPS_SOURCE_YPA_CPB   0x03

Definition at line 226 of file saa7146_vv.h.

#define SAA7146_HPS_SOURCE_YPB_CPA   0x02

Definition at line 225 of file saa7146_vv.h.

#define SAA7146_HPS_SYNC_PORT_A   0x00

Definition at line 229 of file saa7146_vv.h.

#define SAA7146_HPS_SYNC_PORT_B   0x01

Definition at line 230 of file saa7146_vv.h.

#define SAA7146_NO_SWAP   (0x0)

Definition at line 261 of file saa7146_vv.h.

#define SAA7146_TWO_BYTE_SWAP   (0x1)

Definition at line 262 of file saa7146_vv.h.

#define SAA7146_USE_PORT_B_FOR_VBI   0x2 /* use input port b for vbi hardware bug workaround */

Definition at line 148 of file saa7146_vv.h.

#define STATUS_CAPTURE   0x02

Definition at line 102 of file saa7146_vv.h.

#define STATUS_OVERLAY   0x01

Definition at line 101 of file saa7146_vv.h.

#define WRITE_RPS0 (   x)
Value:
do { \
dev->d_rps0.cpu_addr[ count++ ] = cpu_to_le32(x); \
} while (0);

Definition at line 13 of file saa7146_vv.h.

#define WRITE_RPS1 (   x)
Value:
do { \
dev->d_rps1.cpu_addr[ count++ ] = cpu_to_le32(x); \
} while (0);

Definition at line 17 of file saa7146_vv.h.

#define Y8   0x0006

Definition at line 250 of file saa7146_vv.h.

#define YUV411_COMPOSED   0x0003

Definition at line 251 of file saa7146_vv.h.

#define YUV411_DECOMPOSED   0x100b

Definition at line 254 of file saa7146_vv.h.

#define YUV420_DECOMPOSED   0x100a

Definition at line 256 of file saa7146_vv.h.

#define YUV422_COMPOSED   0x0000

Definition at line 252 of file saa7146_vv.h.

#define YUV422_DECOMPOSED   0x1009

Definition at line 255 of file saa7146_vv.h.

Function Documentation

void saa7146_buffer_finish ( struct saa7146_dev dev,
struct saa7146_dmaqueue q,
int  state 
)

Definition at line 91 of file saa7146_fops.c.

void saa7146_buffer_next ( struct saa7146_dev dev,
struct saa7146_dmaqueue q,
int  vbi 
)

Definition at line 114 of file saa7146_fops.c.

int saa7146_buffer_queue ( struct saa7146_dev dev,
struct saa7146_dmaqueue q,
struct saa7146_buf buf 
)

Definition at line 69 of file saa7146_fops.c.

void saa7146_buffer_timeout ( unsigned long  data)

Definition at line 166 of file saa7146_fops.c.

void saa7146_disable_overlay ( struct saa7146_fh fh)

Definition at line 665 of file saa7146_hlp.c.

void saa7146_dma_free ( struct saa7146_dev dev,
struct videobuf_queue q,
struct saa7146_buf buf 
)

Definition at line 51 of file saa7146_fops.c.

int saa7146_enable_overlay ( struct saa7146_fh fh)

Definition at line 650 of file saa7146_hlp.c.

int saa7146_register_device ( struct video_device **  vid,
struct saa7146_dev dev,
char name,
int  type 
)

Definition at line 594 of file saa7146_fops.c.

void saa7146_res_free ( struct saa7146_fh fh,
unsigned int  bits 
)

Definition at line 35 of file saa7146_fops.c.

int saa7146_res_get ( struct saa7146_fh fh,
unsigned int  bit 
)

Definition at line 9 of file saa7146_fops.c.

int saa7146_s_ctrl ( struct v4l2_ctrl ctrl)

Definition at line 532 of file saa7146_video.c.

void saa7146_set_capture ( struct saa7146_dev dev,
struct saa7146_buf buf,
struct saa7146_buf next 
)

Definition at line 999 of file saa7146_hlp.c.

void saa7146_set_gpio ( struct saa7146_dev saa,
u8  pin,
u8  data 
)
void saa7146_set_hps_source_and_sync ( struct saa7146_dev saa,
int  source,
int  sync 
)

Definition at line 630 of file saa7146_hlp.c.

int saa7146_start_preview ( struct saa7146_fh fh)

Definition at line 108 of file saa7146_video.c.

int saa7146_stop_preview ( struct saa7146_fh fh)

Definition at line 170 of file saa7146_video.c.

int saa7146_unregister_device ( struct video_device **  vid,
struct saa7146_dev dev 
)

Definition at line 638 of file saa7146_fops.c.

long saa7146_video_do_ioctl ( struct file file,
unsigned int  cmd,
void arg 
)
int saa7146_vv_init ( struct saa7146_dev dev,
struct saa7146_ext_vv ext_vv 
)

Definition at line 471 of file saa7146_fops.c.

int saa7146_vv_release ( struct saa7146_dev dev)

Definition at line 577 of file saa7146_fops.c.

void saa7146_write_out_dma ( struct saa7146_dev dev,
int  which,
struct saa7146_video_dma vdma 
)

Definition at line 674 of file saa7146_hlp.c.

Variable Documentation

struct v4l2_ioctl_ops saa7146_vbi_ioctl_ops

Definition at line 1039 of file saa7146_video.c.

struct saa7146_use_ops saa7146_vbi_uops

Definition at line 492 of file saa7146_vbi.c.

struct v4l2_ioctl_ops saa7146_video_ioctl_ops

Definition at line 1011 of file saa7146_video.c.

struct saa7146_use_ops saa7146_video_uops

Definition at line 1326 of file saa7146_video.c.