Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Functions
mx1_camera.c File Reference
#include <linux/clk.h>
#include <linux/delay.h>
#include <linux/device.h>
#include <linux/dma-mapping.h>
#include <linux/errno.h>
#include <linux/fs.h>
#include <linux/init.h>
#include <linux/interrupt.h>
#include <linux/io.h>
#include <linux/kernel.h>
#include <linux/mm.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/mutex.h>
#include <linux/platform_device.h>
#include <linux/sched.h>
#include <linux/slab.h>
#include <linux/time.h>
#include <linux/videodev2.h>
#include <media/soc_camera.h>
#include <media/v4l2-common.h>
#include <media/v4l2-dev.h>
#include <media/videobuf-dma-contig.h>
#include <media/soc_mediabus.h>
#include <asm/dma.h>
#include <asm/fiq.h>
#include <mach/dma-mx1-mx2.h>
#include <mach/hardware.h>
#include <mach/irqs.h>
#include <linux/platform_data/camera-mx1.h>

Go to the source code of this file.

Data Structures

struct  mx1_buffer
 
struct  mx1_camera_dev
 

Macros

#define CSICR1   0x00 /* CSI Control Register 1 */
 
#define CSISR   0x08 /* CSI Status Register */
 
#define CSIRXR   0x10 /* CSI RxFIFO Register */
 
#define CSICR1_RXFF_LEVEL(x)   (((x) & 0x3) << 19)
 
#define CSICR1_SOF_POL   (1 << 17)
 
#define CSICR1_SOF_INTEN   (1 << 16)
 
#define CSICR1_MCLKDIV(x)   (((x) & 0xf) << 12)
 
#define CSICR1_MCLKEN   (1 << 9)
 
#define CSICR1_FCC   (1 << 8)
 
#define CSICR1_BIG_ENDIAN   (1 << 7)
 
#define CSICR1_CLR_RXFIFO   (1 << 5)
 
#define CSICR1_GCLK_MODE   (1 << 4)
 
#define CSICR1_DATA_POL   (1 << 2)
 
#define CSICR1_REDGE   (1 << 1)
 
#define CSICR1_EN   (1 << 0)
 
#define CSISR_SFF_OR_INT   (1 << 25)
 
#define CSISR_RFF_OR_INT   (1 << 24)
 
#define CSISR_STATFF_INT   (1 << 21)
 
#define CSISR_RXFF_INT   (1 << 18)
 
#define CSISR_SOF_INT   (1 << 16)
 
#define CSISR_DRDY   (1 << 0)
 
#define DRIVER_VERSION   "0.0.2"
 
#define DRIVER_NAME   "mx1-camera"
 
#define CSI_IRQ_MASK
 
#define CSI_BUS_FLAGS
 
#define MAX_VIDEO_MEM   16 /* Video memory limit in megabytes */
 

Functions

 module_init (mx1_camera_init)
 
 module_exit (mx1_camera_exit)
 
 MODULE_DESCRIPTION ("i.MX1/i.MXL SoC Camera Host driver")
 
 MODULE_AUTHOR ("Paulius Zaleckas <[email protected]>")
 
 MODULE_LICENSE ("GPL v2")
 
 MODULE_VERSION (DRIVER_VERSION)
 
 MODULE_ALIAS ("platform:"DRIVER_NAME)
 

Macro Definition Documentation

#define CSI_BUS_FLAGS
Value:
V4L2_MBUS_VSYNC_ACTIVE_HIGH | V4L2_MBUS_VSYNC_ACTIVE_LOW | \
V4L2_MBUS_PCLK_SAMPLE_RISING | V4L2_MBUS_PCLK_SAMPLE_FALLING | \
V4L2_MBUS_DATA_ACTIVE_HIGH | V4L2_MBUS_DATA_ACTIVE_LOW)

Definition at line 82 of file mx1_camera.c.

#define CSI_IRQ_MASK
Value:

Definition at line 79 of file mx1_camera.c.

#define CSICR1   0x00 /* CSI Control Register 1 */

Definition at line 52 of file mx1_camera.c.

#define CSICR1_BIG_ENDIAN   (1 << 7)

Definition at line 62 of file mx1_camera.c.

#define CSICR1_CLR_RXFIFO   (1 << 5)

Definition at line 63 of file mx1_camera.c.

#define CSICR1_DATA_POL   (1 << 2)

Definition at line 65 of file mx1_camera.c.

#define CSICR1_EN   (1 << 0)

Definition at line 67 of file mx1_camera.c.

#define CSICR1_FCC   (1 << 8)

Definition at line 61 of file mx1_camera.c.

#define CSICR1_GCLK_MODE   (1 << 4)

Definition at line 64 of file mx1_camera.c.

#define CSICR1_MCLKDIV (   x)    (((x) & 0xf) << 12)

Definition at line 59 of file mx1_camera.c.

#define CSICR1_MCLKEN   (1 << 9)

Definition at line 60 of file mx1_camera.c.

#define CSICR1_REDGE   (1 << 1)

Definition at line 66 of file mx1_camera.c.

#define CSICR1_RXFF_LEVEL (   x)    (((x) & 0x3) << 19)

Definition at line 56 of file mx1_camera.c.

#define CSICR1_SOF_INTEN   (1 << 16)

Definition at line 58 of file mx1_camera.c.

#define CSICR1_SOF_POL   (1 << 17)

Definition at line 57 of file mx1_camera.c.

#define CSIRXR   0x10 /* CSI RxFIFO Register */

Definition at line 54 of file mx1_camera.c.

#define CSISR   0x08 /* CSI Status Register */

Definition at line 53 of file mx1_camera.c.

#define CSISR_DRDY   (1 << 0)

Definition at line 74 of file mx1_camera.c.

#define CSISR_RFF_OR_INT   (1 << 24)

Definition at line 70 of file mx1_camera.c.

#define CSISR_RXFF_INT   (1 << 18)

Definition at line 72 of file mx1_camera.c.

#define CSISR_SFF_OR_INT   (1 << 25)

Definition at line 69 of file mx1_camera.c.

#define CSISR_SOF_INT   (1 << 16)

Definition at line 73 of file mx1_camera.c.

#define CSISR_STATFF_INT   (1 << 21)

Definition at line 71 of file mx1_camera.c.

#define DRIVER_NAME   "mx1-camera"

Definition at line 77 of file mx1_camera.c.

#define DRIVER_VERSION   "0.0.2"

Definition at line 76 of file mx1_camera.c.

#define MAX_VIDEO_MEM   16 /* Video memory limit in megabytes */

Definition at line 87 of file mx1_camera.c.

Function Documentation

MODULE_ALIAS ( "platform:"  DRIVER_NAME)
MODULE_AUTHOR ( "Paulius Zaleckas <[email protected]>"  )
MODULE_DESCRIPTION ( "i.MX1/i.MXL SoC Camera Host driver )
module_exit ( mx1_camera_exit  )
module_init ( mx1_camera_init  )
MODULE_LICENSE ( "GPL v2 )
MODULE_VERSION ( DRIVER_VERSION  )