Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions
cx231xx-core.c File Reference
#include <linux/init.h>
#include <linux/list.h>
#include <linux/module.h>
#include <linux/slab.h>
#include <linux/usb.h>
#include <linux/vmalloc.h>
#include <media/v4l2-common.h>
#include <media/tuner.h>
#include "cx231xx.h"
#include "cx231xx-reg.h"

Go to the source code of this file.

Macros

#define cx231xx_coredbg(fmt, arg...)
 
#define cx231xx_isocdbg(fmt, arg...)
 

Functions

 module_param (core_debug, int, 0644)
 
 MODULE_PARM_DESC (core_debug,"enable debug messages [core]")
 
 module_param (reg_debug, int, 0644)
 
 MODULE_PARM_DESC (reg_debug,"enable debug messages [URB reg]")
 
 module_param (alt, int, 0644)
 
 MODULE_PARM_DESC (alt,"alternate setting to use for video endpoint")
 
 LIST_HEAD (cx231xx_devlist)
 
void cx231xx_remove_from_devlist (struct cx231xx *dev)
 
void cx231xx_add_into_devlist (struct cx231xx *dev)
 
int cx231xx_register_extension (struct cx231xx_ops *ops)
 
 EXPORT_SYMBOL (cx231xx_register_extension)
 
void cx231xx_unregister_extension (struct cx231xx_ops *ops)
 
 EXPORT_SYMBOL (cx231xx_unregister_extension)
 
void cx231xx_init_extension (struct cx231xx *dev)
 
void cx231xx_close_extension (struct cx231xx *dev)
 
int cx231xx_send_usb_command (struct cx231xx_i2c *i2c_bus, struct cx231xx_i2c_xfer_data *req_data)
 
 EXPORT_SYMBOL_GPL (cx231xx_send_usb_command)
 
int cx231xx_read_ctrl_reg (struct cx231xx *dev, u8 req, u16 reg, char *buf, int len)
 
int cx231xx_send_vendor_cmd (struct cx231xx *dev, struct VENDOR_REQUEST_IN *ven_req)
 
int cx231xx_write_ctrl_reg (struct cx231xx *dev, u8 req, u16 reg, char *buf, int len)
 
int cx231xx_set_video_alternate (struct cx231xx *dev)
 
int cx231xx_set_alt_setting (struct cx231xx *dev, u8 index, u8 alt)
 
 EXPORT_SYMBOL_GPL (cx231xx_set_alt_setting)
 
int cx231xx_gpio_set (struct cx231xx *dev, struct cx231xx_reg_seq *gpio)
 
int cx231xx_demod_reset (struct cx231xx *dev)
 
 EXPORT_SYMBOL_GPL (cx231xx_demod_reset)
 
int is_fw_load (struct cx231xx *dev)
 
 EXPORT_SYMBOL_GPL (is_fw_load)
 
int cx231xx_set_mode (struct cx231xx *dev, enum cx231xx_mode set_mode)
 
 EXPORT_SYMBOL_GPL (cx231xx_set_mode)
 
int cx231xx_ep5_bulkout (struct cx231xx *dev, u8 *firmware, u16 size)
 
void cx231xx_uninit_isoc (struct cx231xx *dev)
 
 EXPORT_SYMBOL_GPL (cx231xx_uninit_isoc)
 
void cx231xx_uninit_bulk (struct cx231xx *dev)
 
 EXPORT_SYMBOL_GPL (cx231xx_uninit_bulk)
 
int cx231xx_init_isoc (struct cx231xx *dev, int max_packets, int num_bufs, int max_pkt_size, int(*isoc_copy)(struct cx231xx *dev, struct urb *urb))
 
 EXPORT_SYMBOL_GPL (cx231xx_init_isoc)
 
int cx231xx_init_bulk (struct cx231xx *dev, int max_packets, int num_bufs, int max_pkt_size, int(*bulk_copy)(struct cx231xx *dev, struct urb *urb))
 
 EXPORT_SYMBOL_GPL (cx231xx_init_bulk)
 
void cx231xx_stop_TS1 (struct cx231xx *dev)
 
void cx231xx_start_TS1 (struct cx231xx *dev)
 
int cx231xx_dev_init (struct cx231xx *dev)
 
 EXPORT_SYMBOL_GPL (cx231xx_dev_init)
 
void cx231xx_dev_uninit (struct cx231xx *dev)
 
 EXPORT_SYMBOL_GPL (cx231xx_dev_uninit)
 
int cx231xx_send_gpio_cmd (struct cx231xx *dev, u32 gpio_bit, u8 *gpio_val, u8 len, u8 request, u8 direction)
 
 EXPORT_SYMBOL_GPL (cx231xx_send_gpio_cmd)
 
int cx231xx_mode_register (struct cx231xx *dev, u16 address, u32 mode)
 
int cx231xx_read_i2c_master (struct cx231xx *dev, u8 dev_addr, u16 saddr, u8 saddr_len, u32 *data, u8 data_len, int master)
 
int cx231xx_write_i2c_master (struct cx231xx *dev, u8 dev_addr, u16 saddr, u8 saddr_len, u32 data, u8 data_len, int master)
 
int cx231xx_read_i2c_data (struct cx231xx *dev, u8 dev_addr, u16 saddr, u8 saddr_len, u32 *data, u8 data_len)
 
int cx231xx_write_i2c_data (struct cx231xx *dev, u8 dev_addr, u16 saddr, u8 saddr_len, u32 data, u8 data_len)
 
int cx231xx_reg_mask_write (struct cx231xx *dev, u8 dev_addr, u8 size, u16 register_address, u8 bit_start, u8 bit_end, u32 value)
 
int cx231xx_read_modify_write_i2c_dword (struct cx231xx *dev, u8 dev_addr, u16 saddr, u32 mask, u32 value)
 
u32 cx231xx_set_field (u32 field_mask, u32 data)
 

Macro Definition Documentation

#define cx231xx_coredbg (   fmt,
  arg... 
)
Value:
do {\
if (core_debug) \
printk(KERN_INFO "%s %s :"fmt, \
dev->name, __func__ , ##arg); } while (0)

Definition at line 41 of file cx231xx-core.c.

#define cx231xx_isocdbg (   fmt,
  arg... 
)
Value:
do {\
if (core_debug) \
printk(KERN_INFO "%s %s :"fmt, \
dev->name, __func__ , ##arg); } while (0)

Definition at line 54 of file cx231xx-core.c.

Function Documentation

void cx231xx_add_into_devlist ( struct cx231xx dev)

Definition at line 86 of file cx231xx-core.c.

void cx231xx_close_extension ( struct cx231xx dev)

Definition at line 140 of file cx231xx-core.c.

int cx231xx_demod_reset ( struct cx231xx dev)

Definition at line 651 of file cx231xx-core.c.

int cx231xx_dev_init ( struct cx231xx dev)

Definition at line 1269 of file cx231xx-core.c.

void cx231xx_dev_uninit ( struct cx231xx dev)

Definition at line 1411 of file cx231xx-core.c.

int cx231xx_ep5_bulkout ( struct cx231xx dev,
u8 firmware,
u16  size 
)

Definition at line 761 of file cx231xx-core.c.

int cx231xx_gpio_set ( struct cx231xx dev,
struct cx231xx_reg_seq gpio 
)

Definition at line 630 of file cx231xx-core.c.

int cx231xx_init_bulk ( struct cx231xx dev,
int  max_packets,
int  num_bufs,
int  max_pkt_size,
int(*)(struct cx231xx *dev, struct urb *urb bulk_copy 
)

Definition at line 1110 of file cx231xx-core.c.

void cx231xx_init_extension ( struct cx231xx dev)

Definition at line 126 of file cx231xx-core.c.

int cx231xx_init_isoc ( struct cx231xx dev,
int  max_packets,
int  num_bufs,
int  max_pkt_size,
int(*)(struct cx231xx *dev, struct urb *urb isoc_copy 
)

Definition at line 973 of file cx231xx-core.c.

int cx231xx_mode_register ( struct cx231xx dev,
u16  address,
u32  mode 
)

Definition at line 1480 of file cx231xx-core.c.

int cx231xx_read_ctrl_reg ( struct cx231xx dev,
u8  req,
u16  reg,
char buf,
int  len 
)

Definition at line 304 of file cx231xx-core.c.

int cx231xx_read_i2c_data ( struct cx231xx dev,
u8  dev_addr,
u16  saddr,
u8  saddr_len,
u32 data,
u8  data_len 
)

Definition at line 1593 of file cx231xx-core.c.

int cx231xx_read_i2c_master ( struct cx231xx dev,
u8  dev_addr,
u16  saddr,
u8  saddr_len,
u32 data,
u8  data_len,
int  master 
)

Definition at line 1508 of file cx231xx-core.c.

int cx231xx_read_modify_write_i2c_dword ( struct cx231xx dev,
u8  dev_addr,
u16  saddr,
u32  mask,
u32  value 
)

Definition at line 1709 of file cx231xx-core.c.

int cx231xx_reg_mask_write ( struct cx231xx dev,
u8  dev_addr,
u8  size,
u16  register_address,
u8  bit_start,
u8  bit_end,
u32  value 
)

Definition at line 1660 of file cx231xx-core.c.

int cx231xx_register_extension ( struct cx231xx_ops ops)

Definition at line 96 of file cx231xx-core.c.

void cx231xx_remove_from_devlist ( struct cx231xx dev)

Definition at line 71 of file cx231xx-core.c.

int cx231xx_send_gpio_cmd ( struct cx231xx dev,
u32  gpio_bit,
u8 gpio_val,
u8  len,
u8  request,
u8  direction 
)

Definition at line 1423 of file cx231xx-core.c.

int cx231xx_send_usb_command ( struct cx231xx_i2c i2c_bus,
struct cx231xx_i2c_xfer_data req_data 
)

Definition at line 157 of file cx231xx-core.c.

int cx231xx_send_vendor_cmd ( struct cx231xx dev,
struct VENDOR_REQUEST_IN ven_req 
)

Definition at line 343 of file cx231xx-core.c.

int cx231xx_set_alt_setting ( struct cx231xx dev,
u8  index,
u8  alt 
)

Definition at line 536 of file cx231xx-core.c.

u32 cx231xx_set_field ( u32  field_mask,
u32  data 
)

Definition at line 1728 of file cx231xx-core.c.

int cx231xx_set_mode ( struct cx231xx dev,
enum cx231xx_mode  set_mode 
)

Definition at line 697 of file cx231xx-core.c.

int cx231xx_set_video_alternate ( struct cx231xx dev)

Definition at line 476 of file cx231xx-core.c.

void cx231xx_start_TS1 ( struct cx231xx dev)

Definition at line 1247 of file cx231xx-core.c.

void cx231xx_stop_TS1 ( struct cx231xx dev)

Definition at line 1228 of file cx231xx-core.c.

void cx231xx_uninit_bulk ( struct cx231xx dev)

Definition at line 925 of file cx231xx-core.c.

void cx231xx_uninit_isoc ( struct cx231xx dev)

Definition at line 874 of file cx231xx-core.c.

void cx231xx_unregister_extension ( struct cx231xx_ops ops)

Definition at line 111 of file cx231xx-core.c.

int cx231xx_write_ctrl_reg ( struct cx231xx dev,
u8  req,
u16  reg,
char buf,
int  len 
)

Definition at line 417 of file cx231xx-core.c.

int cx231xx_write_i2c_data ( struct cx231xx dev,
u8  dev_addr,
u16  saddr,
u8  saddr_len,
u32  data,
u8  data_len 
)

Definition at line 1629 of file cx231xx-core.c.

int cx231xx_write_i2c_master ( struct cx231xx dev,
u8  dev_addr,
u16  saddr,
u8  saddr_len,
u32  data,
u8  data_len,
int  master 
)

Definition at line 1554 of file cx231xx-core.c.

EXPORT_SYMBOL ( cx231xx_register_extension  )
EXPORT_SYMBOL ( cx231xx_unregister_extension  )
EXPORT_SYMBOL_GPL ( cx231xx_send_usb_command  )
EXPORT_SYMBOL_GPL ( cx231xx_set_alt_setting  )
EXPORT_SYMBOL_GPL ( cx231xx_demod_reset  )
EXPORT_SYMBOL_GPL ( is_fw_load  )
EXPORT_SYMBOL_GPL ( cx231xx_set_mode  )
EXPORT_SYMBOL_GPL ( cx231xx_uninit_isoc  )
EXPORT_SYMBOL_GPL ( cx231xx_uninit_bulk  )
EXPORT_SYMBOL_GPL ( cx231xx_init_isoc  )
EXPORT_SYMBOL_GPL ( cx231xx_init_bulk  )
EXPORT_SYMBOL_GPL ( cx231xx_dev_init  )
EXPORT_SYMBOL_GPL ( cx231xx_dev_uninit  )
EXPORT_SYMBOL_GPL ( cx231xx_send_gpio_cmd  )
int is_fw_load ( struct cx231xx dev)

Definition at line 691 of file cx231xx-core.c.

LIST_HEAD ( cx231xx_devlist  )
module_param ( core_debug  ,
int  ,
0644   
)
module_param ( reg_debug  ,
int  ,
0644   
)
module_param ( alt  ,
int  ,
0644   
)
MODULE_PARM_DESC ( core_debug  ,
"enable debug messages "  [core] 
)
MODULE_PARM_DESC ( reg_debug  ,
"enable debug messages "  [URB reg] 
)
MODULE_PARM_DESC ( alt  ,
"alternate setting to use for video endpoint  
)