Linux Kernel
3.7.1
|
#include <linux/list.h>
#include <media/v4l2-common.h>
#include <media/v4l2-dev.h>
#include <media/videobuf2-core.h>
Go to the source code of this file.
Data Structures | |
struct | mcam_camera |
Macros | |
#define | MAX_DMA_BUFS 3 |
#define | REG_Y0BAR 0x00 |
#define | REG_Y1BAR 0x04 |
#define | REG_Y2BAR 0x08 |
#define | REG_IMGPITCH 0x24 /* Image pitch register */ |
#define | IMGP_YP_SHFT 2 /* Y pitch params */ |
#define | IMGP_YP_MASK 0x00003ffc /* Y pitch field */ |
#define | IMGP_UVP_SHFT 18 /* UV pitch (planar) */ |
#define | IMGP_UVP_MASK 0x3ffc0000 |
#define | REG_IRQSTATRAW 0x28 /* RAW IRQ Status */ |
#define | IRQ_EOF0 0x00000001 /* End of frame 0 */ |
#define | IRQ_EOF1 0x00000002 /* End of frame 1 */ |
#define | IRQ_EOF2 0x00000004 /* End of frame 2 */ |
#define | IRQ_SOF0 0x00000008 /* Start of frame 0 */ |
#define | IRQ_SOF1 0x00000010 /* Start of frame 1 */ |
#define | IRQ_SOF2 0x00000020 /* Start of frame 2 */ |
#define | IRQ_OVERFLOW 0x00000040 /* FIFO overflow */ |
#define | IRQ_TWSIW 0x00010000 /* TWSI (smbus) write */ |
#define | IRQ_TWSIR 0x00020000 /* TWSI read */ |
#define | IRQ_TWSIE 0x00040000 /* TWSI error */ |
#define | TWSIIRQS (IRQ_TWSIW|IRQ_TWSIR|IRQ_TWSIE) |
#define | FRAMEIRQS (IRQ_EOF0|IRQ_EOF1|IRQ_EOF2|IRQ_SOF0|IRQ_SOF1|IRQ_SOF2) |
#define | ALLIRQS (TWSIIRQS|FRAMEIRQS|IRQ_OVERFLOW) |
#define | REG_IRQMASK 0x2c /* IRQ mask - same bits as IRQSTAT */ |
#define | REG_IRQSTAT 0x30 /* IRQ status / clear */ |
#define | REG_IMGSIZE 0x34 /* Image size */ |
#define | IMGSZ_V_MASK 0x1fff0000 |
#define | IMGSZ_V_SHIFT 16 |
#define | IMGSZ_H_MASK 0x00003fff |
#define | REG_IMGOFFSET 0x38 /* IMage offset */ |
#define | REG_CTRL0 0x3c /* Control 0 */ |
#define | C0_ENABLE 0x00000001 /* Makes the whole thing go */ |
#define | C0_DF_MASK 0x00fffffc /* Bits 2-23 */ |
#define | C0_RGB4_RGBX 0x00000000 |
#define | C0_RGB4_XRGB 0x00000004 |
#define | C0_RGB4_BGRX 0x00000008 |
#define | C0_RGB4_XBGR 0x0000000c |
#define | C0_RGB5_RGGB 0x00000000 |
#define | C0_RGB5_GRBG 0x00000004 |
#define | C0_RGB5_GBRG 0x00000008 |
#define | C0_RGB5_BGGR 0x0000000c |
#define | C0_DF_YUV 0x00000000 /* Data is YUV */ |
#define | C0_DF_RGB 0x000000a0 /* ... RGB */ |
#define | C0_DF_BAYER 0x00000140 /* ... Bayer */ |
#define | C0_RGBF_565 0x00000000 |
#define | C0_RGBF_444 0x00000800 |
#define | C0_RGB_BGR 0x00001000 /* Blue comes first */ |
#define | C0_YUV_PLANAR 0x00000000 /* YUV 422 planar format */ |
#define | C0_YUV_PACKED 0x00008000 /* YUV 422 packed */ |
#define | C0_YUV_420PL 0x0000a000 /* YUV 420 planar */ |
#define | C0_YUVE_YUYV 0x00000000 /* Y1CbY0Cr */ |
#define | C0_YUVE_YVYU 0x00010000 /* Y1CrY0Cb */ |
#define | C0_YUVE_VYUY 0x00020000 /* CrY1CbY0 */ |
#define | C0_YUVE_UYVY 0x00030000 /* CbY1CrY0 */ |
#define | C0_YUVE_XYUV 0x00000000 /* 420: .YUV */ |
#define | C0_YUVE_XYVU 0x00010000 /* 420: .YVU */ |
#define | C0_YUVE_XUVY 0x00020000 /* 420: .UVY */ |
#define | C0_YUVE_XVUY 0x00030000 /* 420: .VUY */ |
#define | C0_HPOL_LOW 0x01000000 /* HSYNC polarity active low */ |
#define | C0_VPOL_LOW 0x02000000 /* VSYNC polarity active low */ |
#define | C0_VCLK_LOW 0x04000000 /* VCLK on falling edge */ |
#define | C0_DOWNSCALE 0x08000000 /* Enable downscaler */ |
#define | C0_SIFM_MASK 0xc0000000 /* SIF mode bits */ |
#define | C0_SIF_HVSYNC 0x00000000 /* Use H/VSYNC */ |
#define | CO_SOF_NOSYNC 0x40000000 /* Use inband active signaling */ |
#define | REG_CTRL1 0x40 /* Control 1 */ |
#define | C1_CLKGATE 0x00000001 /* Sensor clock gate */ |
#define | C1_DESC_ENA 0x00000100 /* DMA descriptor enable */ |
#define | C1_DESC_3WORD 0x00000200 /* Three-word descriptors used */ |
#define | C1_444ALPHA 0x00f00000 /* Alpha field in RGB444 */ |
#define | C1_ALPHA_SHFT 20 |
#define | C1_DMAB32 0x00000000 /* 32-byte DMA burst */ |
#define | C1_DMAB16 0x02000000 /* 16-byte DMA burst */ |
#define | C1_DMAB64 0x04000000 /* 64-byte DMA burst */ |
#define | C1_DMAB_MASK 0x06000000 |
#define | C1_TWOBUFS 0x08000000 /* Use only two DMA buffers */ |
#define | C1_PWRDWN 0x10000000 /* Power down */ |
#define | REG_CLKCTRL 0x88 /* Clock control */ |
#define | CLK_DIV_MASK 0x0000ffff /* Upper bits RW "reserved" */ |
#define | REG_UBAR 0xc4 /* Upper base address register */ |
#define | REG_DMA_DESC_Y 0x200 |
#define | REG_DMA_DESC_U 0x204 |
#define | REG_DMA_DESC_V 0x208 |
#define | REG_DESC_LEN_Y 0x20c /* Lengths are in bytes */ |
#define | REG_DESC_LEN_U 0x210 |
#define | REG_DESC_LEN_V 0x214 |
#define | VGA_WIDTH 640 |
#define | VGA_HEIGHT 480 |
Enumerations | |
enum | mcam_state { S_NOTREADY, S_IDLE, S_FLAKED, S_STREAMING, S_BUFWAIT } |
enum | mcam_buffer_mode { B_vmalloc = 0, B_DMA_contig = 1, B_DMA_sg = 2 } |
Functions | |
int | mccic_register (struct mcam_camera *cam) |
int | mccic_irq (struct mcam_camera *cam, unsigned int irqs) |
void | mccic_shutdown (struct mcam_camera *cam) |
#define ALLIRQS (TWSIIRQS|FRAMEIRQS|IRQ_OVERFLOW) |
Definition at line 232 of file mcam-core.h.
#define C0_DF_BAYER 0x00000140 /* ... Bayer */ |
Definition at line 262 of file mcam-core.h.
#define C0_DF_MASK 0x00fffffc /* Bits 2-23 */ |
Definition at line 246 of file mcam-core.h.
#define C0_DF_RGB 0x000000a0 /* ... RGB */ |
Definition at line 261 of file mcam-core.h.
#define C0_DF_YUV 0x00000000 /* Data is YUV */ |
Definition at line 260 of file mcam-core.h.
#define C0_DOWNSCALE 0x08000000 /* Enable downscaler */ |
Definition at line 283 of file mcam-core.h.
#define C0_ENABLE 0x00000001 /* Makes the whole thing go */ |
Definition at line 243 of file mcam-core.h.
#define C0_HPOL_LOW 0x01000000 /* HSYNC polarity active low */ |
Definition at line 280 of file mcam-core.h.
#define C0_RGB4_BGRX 0x00000008 |
Definition at line 251 of file mcam-core.h.
#define C0_RGB4_RGBX 0x00000000 |
Definition at line 249 of file mcam-core.h.
#define C0_RGB4_XBGR 0x0000000c |
Definition at line 252 of file mcam-core.h.
#define C0_RGB4_XRGB 0x00000004 |
Definition at line 250 of file mcam-core.h.
#define C0_RGB5_BGGR 0x0000000c |
Definition at line 256 of file mcam-core.h.
#define C0_RGB5_GBRG 0x00000008 |
Definition at line 255 of file mcam-core.h.
#define C0_RGB5_GRBG 0x00000004 |
Definition at line 254 of file mcam-core.h.
#define C0_RGB5_RGGB 0x00000000 |
Definition at line 253 of file mcam-core.h.
#define C0_RGB_BGR 0x00001000 /* Blue comes first */ |
Definition at line 266 of file mcam-core.h.
#define C0_RGBF_444 0x00000800 |
Definition at line 265 of file mcam-core.h.
#define C0_RGBF_565 0x00000000 |
Definition at line 264 of file mcam-core.h.
#define C0_SIF_HVSYNC 0x00000000 /* Use H/VSYNC */ |
Definition at line 285 of file mcam-core.h.
#define C0_SIFM_MASK 0xc0000000 /* SIF mode bits */ |
Definition at line 284 of file mcam-core.h.
#define C0_VCLK_LOW 0x04000000 /* VCLK on falling edge */ |
Definition at line 282 of file mcam-core.h.
#define C0_VPOL_LOW 0x02000000 /* VSYNC polarity active low */ |
Definition at line 281 of file mcam-core.h.
#define C0_YUV_420PL 0x0000a000 /* YUV 420 planar */ |
Definition at line 269 of file mcam-core.h.
#define C0_YUV_PACKED 0x00008000 /* YUV 422 packed */ |
Definition at line 268 of file mcam-core.h.
#define C0_YUV_PLANAR 0x00000000 /* YUV 422 planar format */ |
Definition at line 267 of file mcam-core.h.
#define C0_YUVE_UYVY 0x00030000 /* CbY1CrY0 */ |
Definition at line 274 of file mcam-core.h.
#define C0_YUVE_VYUY 0x00020000 /* CrY1CbY0 */ |
Definition at line 273 of file mcam-core.h.
#define C0_YUVE_XUVY 0x00020000 /* 420: .UVY */ |
Definition at line 277 of file mcam-core.h.
#define C0_YUVE_XVUY 0x00030000 /* 420: .VUY */ |
Definition at line 278 of file mcam-core.h.
#define C0_YUVE_XYUV 0x00000000 /* 420: .YUV */ |
Definition at line 275 of file mcam-core.h.
#define C0_YUVE_XYVU 0x00010000 /* 420: .YVU */ |
Definition at line 276 of file mcam-core.h.
#define C0_YUVE_YUYV 0x00000000 /* Y1CbY0Cr */ |
Definition at line 271 of file mcam-core.h.
#define C0_YUVE_YVYU 0x00010000 /* Y1CrY0Cb */ |
Definition at line 272 of file mcam-core.h.
#define C1_444ALPHA 0x00f00000 /* Alpha field in RGB444 */ |
Definition at line 293 of file mcam-core.h.
#define C1_ALPHA_SHFT 20 |
Definition at line 294 of file mcam-core.h.
#define C1_CLKGATE 0x00000001 /* Sensor clock gate */ |
Definition at line 290 of file mcam-core.h.
#define C1_DESC_3WORD 0x00000200 /* Three-word descriptors used */ |
Definition at line 292 of file mcam-core.h.
#define C1_DESC_ENA 0x00000100 /* DMA descriptor enable */ |
Definition at line 291 of file mcam-core.h.
#define C1_DMAB16 0x02000000 /* 16-byte DMA burst */ |
Definition at line 296 of file mcam-core.h.
#define C1_DMAB32 0x00000000 /* 32-byte DMA burst */ |
Definition at line 295 of file mcam-core.h.
#define C1_DMAB64 0x04000000 /* 64-byte DMA burst */ |
Definition at line 297 of file mcam-core.h.
#define C1_DMAB_MASK 0x06000000 |
Definition at line 298 of file mcam-core.h.
#define C1_PWRDWN 0x10000000 /* Power down */ |
Definition at line 300 of file mcam-core.h.
#define C1_TWOBUFS 0x08000000 /* Use only two DMA buffers */ |
Definition at line 299 of file mcam-core.h.
#define CLK_DIV_MASK 0x0000ffff /* Upper bits RW "reserved" */ |
Definition at line 303 of file mcam-core.h.
#define CO_SOF_NOSYNC 0x40000000 /* Use inband active signaling */ |
Definition at line 286 of file mcam-core.h.
Definition at line 231 of file mcam-core.h.
#define IMGP_UVP_MASK 0x3ffc0000 |
Definition at line 218 of file mcam-core.h.
#define IMGP_UVP_SHFT 18 /* UV pitch (planar) */ |
Definition at line 217 of file mcam-core.h.
#define IMGP_YP_MASK 0x00003ffc /* Y pitch field */ |
Definition at line 216 of file mcam-core.h.
#define IMGP_YP_SHFT 2 /* Y pitch params */ |
Definition at line 215 of file mcam-core.h.
#define IMGSZ_H_MASK 0x00003fff |
Definition at line 239 of file mcam-core.h.
#define IMGSZ_V_MASK 0x1fff0000 |
Definition at line 237 of file mcam-core.h.
#define IMGSZ_V_SHIFT 16 |
Definition at line 238 of file mcam-core.h.
#define IRQ_EOF0 0x00000001 /* End of frame 0 */ |
Definition at line 220 of file mcam-core.h.
#define IRQ_EOF1 0x00000002 /* End of frame 1 */ |
Definition at line 221 of file mcam-core.h.
#define IRQ_EOF2 0x00000004 /* End of frame 2 */ |
Definition at line 222 of file mcam-core.h.
#define IRQ_OVERFLOW 0x00000040 /* FIFO overflow */ |
Definition at line 226 of file mcam-core.h.
#define IRQ_SOF0 0x00000008 /* Start of frame 0 */ |
Definition at line 223 of file mcam-core.h.
#define IRQ_SOF1 0x00000010 /* Start of frame 1 */ |
Definition at line 224 of file mcam-core.h.
#define IRQ_SOF2 0x00000020 /* Start of frame 2 */ |
Definition at line 225 of file mcam-core.h.
#define IRQ_TWSIE 0x00040000 /* TWSI error */ |
Definition at line 229 of file mcam-core.h.
#define IRQ_TWSIR 0x00020000 /* TWSI read */ |
Definition at line 228 of file mcam-core.h.
#define IRQ_TWSIW 0x00010000 /* TWSI (smbus) write */ |
Definition at line 227 of file mcam-core.h.
#define MAX_DMA_BUFS 3 |
Definition at line 43 of file mcam-core.h.
#define REG_CLKCTRL 0x88 /* Clock control */ |
Definition at line 302 of file mcam-core.h.
#define REG_CTRL0 0x3c /* Control 0 */ |
Definition at line 242 of file mcam-core.h.
#define REG_CTRL1 0x40 /* Control 1 */ |
Definition at line 289 of file mcam-core.h.
#define REG_DESC_LEN_U 0x210 |
Definition at line 313 of file mcam-core.h.
#define REG_DESC_LEN_V 0x214 |
Definition at line 314 of file mcam-core.h.
#define REG_DESC_LEN_Y 0x20c /* Lengths are in bytes */ |
Definition at line 312 of file mcam-core.h.
#define REG_DMA_DESC_U 0x204 |
Definition at line 310 of file mcam-core.h.
#define REG_DMA_DESC_V 0x208 |
Definition at line 311 of file mcam-core.h.
#define REG_DMA_DESC_Y 0x200 |
Definition at line 309 of file mcam-core.h.
#define REG_IMGOFFSET 0x38 /* IMage offset */ |
Definition at line 240 of file mcam-core.h.
#define REG_IMGPITCH 0x24 /* Image pitch register */ |
Definition at line 214 of file mcam-core.h.
#define REG_IMGSIZE 0x34 /* Image size */ |
Definition at line 236 of file mcam-core.h.
#define REG_IRQMASK 0x2c /* IRQ mask - same bits as IRQSTAT */ |
Definition at line 233 of file mcam-core.h.
#define REG_IRQSTAT 0x30 /* IRQ status / clear */ |
Definition at line 234 of file mcam-core.h.
#define REG_IRQSTATRAW 0x28 /* RAW IRQ Status */ |
Definition at line 219 of file mcam-core.h.
#define REG_UBAR 0xc4 /* Upper base address register */ |
Definition at line 306 of file mcam-core.h.
#define REG_Y0BAR 0x00 |
Definition at line 209 of file mcam-core.h.
#define REG_Y1BAR 0x04 |
Definition at line 210 of file mcam-core.h.
#define REG_Y2BAR 0x08 |
Definition at line 211 of file mcam-core.h.
Definition at line 230 of file mcam-core.h.
#define VGA_HEIGHT 480 |
Definition at line 320 of file mcam-core.h.
#define VGA_WIDTH 640 |
Definition at line 319 of file mcam-core.h.
enum mcam_buffer_mode |
Definition at line 49 of file mcam-core.h.
enum mcam_state |
Definition at line 36 of file mcam-core.h.
int mccic_irq | ( | struct mcam_camera * | cam, |
unsigned int | irqs | ||
) |
Definition at line 1680 of file mcam-core.c.
int mccic_register | ( | struct mcam_camera * | cam | ) |
Definition at line 1730 of file mcam-core.c.
void mccic_shutdown | ( | struct mcam_camera * | cam | ) |
Definition at line 1816 of file mcam-core.c.