Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Enumerations | Functions
exynos_mipi_dsi_common.c File Reference
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/errno.h>
#include <linux/mutex.h>
#include <linux/wait.h>
#include <linux/fs.h>
#include <linux/mm.h>
#include <linux/fb.h>
#include <linux/ctype.h>
#include <linux/platform_device.h>
#include <linux/io.h>
#include <linux/memory.h>
#include <linux/delay.h>
#include <linux/kthread.h>
#include <video/mipi_display.h>
#include <video/exynos_mipi_dsim.h>
#include <mach/map.h>
#include "exynos_mipi_dsi_regs.h"
#include "exynos_mipi_dsi_lowlevel.h"
#include "exynos_mipi_dsi_common.h"

Go to the source code of this file.

Macros

#define MIPI_FIFO_TIMEOUT   msecs_to_jiffies(250)
 
#define MIPI_RX_FIFO_READ_DONE   0x30800002
 
#define MIPI_MAX_RX_FIFO   20
 
#define MHZ   (1000 * 1000)
 
#define FIN_HZ   (24 * MHZ)
 
#define DFIN_PLL_MIN_HZ   (6 * MHZ)
 
#define DFIN_PLL_MAX_HZ   (12 * MHZ)
 
#define DFVCO_MIN_HZ   (500 * MHZ)
 
#define DFVCO_MAX_HZ   (1000 * MHZ)
 
#define TRY_GET_FIFO_TIMEOUT   (5000 * 2)
 
#define TRY_FIFO_CLEAR   (10)
 

Enumerations

enum  { DSIM_STATE_INIT, DSIM_STATE_STOP, DSIM_STATE_HSCLKEN, DSIM_STATE_ULPS }
 
enum  {
  DSIM_LANE_CLOCK = (1 << 0), DSIM_LANE_DATA0 = (1 << 1), DSIM_LANE_DATA1 = (1 << 2), DSIM_LANE_DATA2 = (1 << 3),
  DSIM_LANE_DATA3 = (1 << 4)
}
 

Functions

irqreturn_t exynos_mipi_dsi_interrupt_handler (int irq, void *dev_id)
 
int exynos_mipi_dsi_wr_data (struct mipi_dsim_device *dsim, unsigned int data_id, const unsigned char *data0, unsigned int data_size)
 
int exynos_mipi_dsi_rd_data (struct mipi_dsim_device *dsim, unsigned int data_id, unsigned int data0, unsigned int req_size, u8 *rx_buf)
 
int exynos_mipi_dsi_init_dsim (struct mipi_dsim_device *dsim)
 
void exynos_mipi_dsi_init_interrupt (struct mipi_dsim_device *dsim)
 
int exynos_mipi_dsi_enable_frame_done_int (struct mipi_dsim_device *dsim, unsigned int enable)
 
void exynos_mipi_dsi_stand_by (struct mipi_dsim_device *dsim, unsigned int enable)
 
int exynos_mipi_dsi_set_display_mode (struct mipi_dsim_device *dsim, struct mipi_dsim_config *dsim_config)
 
int exynos_mipi_dsi_init_link (struct mipi_dsim_device *dsim)
 
int exynos_mipi_dsi_set_hs_enable (struct mipi_dsim_device *dsim)
 
int exynos_mipi_dsi_set_data_transfer_mode (struct mipi_dsim_device *dsim, unsigned int mode)
 
int exynos_mipi_dsi_get_frame_done_status (struct mipi_dsim_device *dsim)
 
int exynos_mipi_dsi_clear_frame_done (struct mipi_dsim_device *dsim)
 
int exynos_mipi_dsi_fifo_clear (struct mipi_dsim_device *dsim, unsigned int val)
 
 MODULE_AUTHOR ("InKi Dae <[email protected]>")
 
 MODULE_DESCRIPTION ("Samusung SoC MIPI-DSI common driver")
 
 MODULE_LICENSE ("GPL")
 

Macro Definition Documentation

#define DFIN_PLL_MAX_HZ   (12 * MHZ)

Definition at line 46 of file exynos_mipi_dsi_common.c.

#define DFIN_PLL_MIN_HZ   (6 * MHZ)

Definition at line 45 of file exynos_mipi_dsi_common.c.

#define DFVCO_MAX_HZ   (1000 * MHZ)

Definition at line 49 of file exynos_mipi_dsi_common.c.

#define DFVCO_MIN_HZ   (500 * MHZ)

Definition at line 48 of file exynos_mipi_dsi_common.c.

#define FIN_HZ   (24 * MHZ)

Definition at line 43 of file exynos_mipi_dsi_common.c.

#define MHZ   (1000 * 1000)

Definition at line 42 of file exynos_mipi_dsi_common.c.

#define MIPI_FIFO_TIMEOUT   msecs_to_jiffies(250)

Definition at line 39 of file exynos_mipi_dsi_common.c.

#define MIPI_MAX_RX_FIFO   20

Definition at line 41 of file exynos_mipi_dsi_common.c.

#define MIPI_RX_FIFO_READ_DONE   0x30800002

Definition at line 40 of file exynos_mipi_dsi_common.c.

#define TRY_FIFO_CLEAR   (10)

Definition at line 52 of file exynos_mipi_dsi_common.c.

#define TRY_GET_FIFO_TIMEOUT   (5000 * 2)

Definition at line 51 of file exynos_mipi_dsi_common.c.

Enumeration Type Documentation

anonymous enum
Enumerator:
DSIM_STATE_INIT 
DSIM_STATE_STOP 
DSIM_STATE_HSCLKEN 
DSIM_STATE_ULPS 

Definition at line 55 of file exynos_mipi_dsi_common.c.

anonymous enum
Enumerator:
DSIM_LANE_CLOCK 
DSIM_LANE_DATA0 
DSIM_LANE_DATA1 
DSIM_LANE_DATA2 
DSIM_LANE_DATA3 

Definition at line 63 of file exynos_mipi_dsi_common.c.

Function Documentation

int exynos_mipi_dsi_clear_frame_done ( struct mipi_dsim_device dsim)

Definition at line 851 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_enable_frame_done_int ( struct mipi_dsim_device dsim,
unsigned int  enable 
)

Definition at line 693 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_fifo_clear ( struct mipi_dsim_device dsim,
unsigned int  val 
)

Definition at line 858 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_get_frame_done_status ( struct mipi_dsim_device dsim)

Definition at line 846 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_init_dsim ( struct mipi_dsim_device dsim)

Definition at line 649 of file exynos_mipi_dsi_common.c.

void exynos_mipi_dsi_init_interrupt ( struct mipi_dsim_device dsim)

Definition at line 681 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_init_link ( struct mipi_dsim_device dsim)

Definition at line 747 of file exynos_mipi_dsi_common.c.

irqreturn_t exynos_mipi_dsi_interrupt_handler ( int  irq,
void dev_id 
)

Definition at line 77 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_rd_data ( struct mipi_dsim_device dsim,
unsigned int  data_id,
unsigned int  data0,
unsigned int  req_size,
u8 rx_buf 
)

Definition at line 343 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_set_data_transfer_mode ( struct mipi_dsim_device dsim,
unsigned int  mode 
)

Definition at line 822 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_set_display_mode ( struct mipi_dsim_device dsim,
struct mipi_dsim_config dsim_config 
)

Definition at line 711 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_set_hs_enable ( struct mipi_dsim_device dsim)

Definition at line 800 of file exynos_mipi_dsi_common.c.

void exynos_mipi_dsi_stand_by ( struct mipi_dsim_device dsim,
unsigned int  enable 
)

Definition at line 702 of file exynos_mipi_dsi_common.c.

int exynos_mipi_dsi_wr_data ( struct mipi_dsim_device dsim,
unsigned int  data_id,
const unsigned char data0,
unsigned int  data_size 
)

Definition at line 157 of file exynos_mipi_dsi_common.c.

MODULE_AUTHOR ( "InKi Dae <[email protected]>"  )
MODULE_DESCRIPTION ( "Samusung SoC MIPI-DSI common driver )
MODULE_LICENSE ( "GPL"  )