Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Data Structures | Macros | Enumerations | Functions
cx24116.c File Reference
#include <linux/slab.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/init.h>
#include <linux/firmware.h>
#include "dvb_frontend.h"
#include "cx24116.h"

Go to the source code of this file.

Data Structures

struct  cx24116_tuning
 
struct  cx24116_cmd
 
struct  cx24116_state
 
struct  cx24116_modfec
 

Macros

#define dprintk(args...)
 
#define CX24116_DEFAULT_FIRMWARE   "dvb-fe-cx24116.fw"
 
#define CX24116_SEARCH_RANGE_KHZ   5000
 
#define CX24116_REG_COMMAND   (0x00) /* command args 0x00..0x1e */
 
#define CX24116_REG_EXECUTE   (0x1f) /* execute command */
 
#define CX24116_REG_MAILBOX   (0x96) /* FW or multipurpose mailbox? */
 
#define CX24116_REG_RESET   (0x20) /* reset status > 0 */
 
#define CX24116_REG_SIGNAL   (0x9e) /* signal low */
 
#define CX24116_REG_SSTATUS   (0x9d) /* signal high / status */
 
#define CX24116_REG_QUALITY8   (0xa3)
 
#define CX24116_REG_QSTATUS   (0xbc)
 
#define CX24116_REG_QUALITY0   (0xd5)
 
#define CX24116_REG_BER0   (0xc9)
 
#define CX24116_REG_BER8   (0xc8)
 
#define CX24116_REG_BER16   (0xc7)
 
#define CX24116_REG_BER24   (0xc6)
 
#define CX24116_REG_UCB0   (0xcb)
 
#define CX24116_REG_UCB8   (0xca)
 
#define CX24116_REG_CLKDIV   (0xf3)
 
#define CX24116_REG_RATEDIV   (0xf9)
 
#define CX24116_REG_FECSTATUS   (0x9c)
 
#define CX24116_FEC_FECMASK   (0x1f)
 
#define CX24116_FEC_DVBS   (0x20)
 
#define CX24116_FEC_UNKNOWN   (0x40) /* Unknown/unused */
 
#define CX24116_FEC_PILOT   (0x80)
 
#define CX24116_ARGLEN   (0x1e)
 
#define CX24116_ROLLOFF_020   (0x00)
 
#define CX24116_ROLLOFF_025   (0x01)
 
#define CX24116_ROLLOFF_035   (0x02)
 
#define CX24116_PILOT_OFF   (0x00)
 
#define CX24116_PILOT_ON   (0x40)
 
#define CX24116_HAS_SIGNAL   (0x01)
 
#define CX24116_HAS_CARRIER   (0x02)
 
#define CX24116_HAS_VITERBI   (0x04)
 
#define CX24116_HAS_SYNCLOCK   (0x08)
 
#define CX24116_HAS_UNKNOWN1   (0x10)
 
#define CX24116_HAS_UNKNOWN2   (0x20)
 
#define CX24116_STATUS_MASK   (0x0f)
 
#define CX24116_SIGNAL_MASK   (0xc0)
 
#define CX24116_DISEQC_TONEOFF   (0) /* toneburst never sent */
 
#define CX24116_DISEQC_TONECACHE   (1) /* toneburst cached */
 
#define CX24116_DISEQC_MESGCACHE   (2) /* message cached */
 
#define CX24116_DISEQC_BURST   (1)
 
#define CX24116_DISEQC_ARG2_2   (2) /* unknown value=2 */
 
#define CX24116_DISEQC_ARG3_0   (3) /* unknown value=0 */
 
#define CX24116_DISEQC_ARG4_0   (4) /* unknown value=0 */
 
#define CX24116_DISEQC_MSGLEN   (5)
 
#define CX24116_DISEQC_MSGOFS   (6)
 
#define CX24116_DISEQC_MINI_A   (0)
 
#define CX24116_DISEQC_MINI_B   (1)
 

Enumerations

enum  cmds {
  CMD_SET_VCO = 0x10, CMD_TUNEREQUEST = 0x11, CMD_MPEGCONFIG = 0x13, CMD_TUNERINIT = 0x14,
  CMD_BANDWIDTH = 0x15, CMD_GETAGC = 0x19, CMD_LNBCONFIG = 0x20, CMD_LNBSEND = 0x21,
  CMD_LNBDCLEVEL = 0x22, CMD_SET_TONE = 0x23, CMD_UPDFWVERS = 0x35, CMD_TUNERSLEEP = 0x36,
  CMD_AGCCONTROL = 0x3b
}
 

Functions

 module_param (debug, int, 0644)
 
 MODULE_PARM_DESC (debug,"Activates frontend debugging (default:0)")
 
 module_param (toneburst, int, 0644)
 
 MODULE_PARM_DESC (toneburst,"DiSEqC toneburst 0=OFF, 1=TONE CACHE, ""2=MESSAGE CACHE (default:1)")
 
 module_param (esno_snr, int, 0644)
 
 MODULE_PARM_DESC (esno_snr,"SNR return units, 0=PERCENTAGE 0-100, ""1=ESNO(db * 10) (default:0)")
 
struct dvb_frontendcx24116_attach (const struct cx24116_config *config, struct i2c_adapter *i2c)
 
 EXPORT_SYMBOL (cx24116_attach)
 
 MODULE_DESCRIPTION ("DVB Frontend module for Conexant cx24116/cx24118 hardware")
 
 MODULE_AUTHOR ("Steven Toth")
 
 MODULE_LICENSE ("GPL")
 

Macro Definition Documentation

#define CX24116_ARGLEN   (0x1e)

Definition at line 94 of file cx24116.c.

#define CX24116_DEFAULT_FIRMWARE   "dvb-fe-cx24116.fw"

Definition at line 57 of file cx24116.c.

#define CX24116_DISEQC_ARG2_2   (2) /* unknown value=2 */

Definition at line 121 of file cx24116.c.

#define CX24116_DISEQC_ARG3_0   (3) /* unknown value=0 */

Definition at line 122 of file cx24116.c.

#define CX24116_DISEQC_ARG4_0   (4) /* unknown value=0 */

Definition at line 123 of file cx24116.c.

#define CX24116_DISEQC_BURST   (1)

Definition at line 120 of file cx24116.c.

#define CX24116_DISEQC_MESGCACHE   (2) /* message cached */

Definition at line 117 of file cx24116.c.

#define CX24116_DISEQC_MINI_A   (0)

Definition at line 128 of file cx24116.c.

#define CX24116_DISEQC_MINI_B   (1)

Definition at line 129 of file cx24116.c.

#define CX24116_DISEQC_MSGLEN   (5)

Definition at line 124 of file cx24116.c.

#define CX24116_DISEQC_MSGOFS   (6)

Definition at line 125 of file cx24116.c.

#define CX24116_DISEQC_TONECACHE   (1) /* toneburst cached */

Definition at line 116 of file cx24116.c.

#define CX24116_DISEQC_TONEOFF   (0) /* toneburst never sent */

Definition at line 115 of file cx24116.c.

#define CX24116_FEC_DVBS   (0x20)

Definition at line 87 of file cx24116.c.

#define CX24116_FEC_FECMASK   (0x1f)

Definition at line 84 of file cx24116.c.

#define CX24116_FEC_PILOT   (0x80)

Definition at line 91 of file cx24116.c.

#define CX24116_FEC_UNKNOWN   (0x40) /* Unknown/unused */

Definition at line 88 of file cx24116.c.

#define CX24116_HAS_CARRIER   (0x02)

Definition at line 107 of file cx24116.c.

#define CX24116_HAS_SIGNAL   (0x01)

Definition at line 106 of file cx24116.c.

#define CX24116_HAS_SYNCLOCK   (0x08)

Definition at line 109 of file cx24116.c.

#define CX24116_HAS_UNKNOWN1   (0x10)

Definition at line 110 of file cx24116.c.

#define CX24116_HAS_UNKNOWN2   (0x20)

Definition at line 111 of file cx24116.c.

#define CX24116_HAS_VITERBI   (0x04)

Definition at line 108 of file cx24116.c.

#define CX24116_PILOT_OFF   (0x00)

Definition at line 102 of file cx24116.c.

#define CX24116_PILOT_ON   (0x40)

Definition at line 103 of file cx24116.c.

#define CX24116_REG_BER0   (0xc9)

Definition at line 70 of file cx24116.c.

#define CX24116_REG_BER16   (0xc7)

Definition at line 72 of file cx24116.c.

#define CX24116_REG_BER24   (0xc6)

Definition at line 73 of file cx24116.c.

#define CX24116_REG_BER8   (0xc8)

Definition at line 71 of file cx24116.c.

#define CX24116_REG_CLKDIV   (0xf3)

Definition at line 76 of file cx24116.c.

#define CX24116_REG_COMMAND   (0x00) /* command args 0x00..0x1e */

Definition at line 61 of file cx24116.c.

#define CX24116_REG_EXECUTE   (0x1f) /* execute command */

Definition at line 62 of file cx24116.c.

#define CX24116_REG_FECSTATUS   (0x9c)

Definition at line 80 of file cx24116.c.

#define CX24116_REG_MAILBOX   (0x96) /* FW or multipurpose mailbox? */

Definition at line 63 of file cx24116.c.

#define CX24116_REG_QSTATUS   (0xbc)

Definition at line 68 of file cx24116.c.

#define CX24116_REG_QUALITY0   (0xd5)

Definition at line 69 of file cx24116.c.

#define CX24116_REG_QUALITY8   (0xa3)

Definition at line 67 of file cx24116.c.

#define CX24116_REG_RATEDIV   (0xf9)

Definition at line 77 of file cx24116.c.

#define CX24116_REG_RESET   (0x20) /* reset status > 0 */

Definition at line 64 of file cx24116.c.

#define CX24116_REG_SIGNAL   (0x9e) /* signal low */

Definition at line 65 of file cx24116.c.

#define CX24116_REG_SSTATUS   (0x9d) /* signal high / status */

Definition at line 66 of file cx24116.c.

#define CX24116_REG_UCB0   (0xcb)

Definition at line 74 of file cx24116.c.

#define CX24116_REG_UCB8   (0xca)

Definition at line 75 of file cx24116.c.

#define CX24116_ROLLOFF_020   (0x00)

Definition at line 97 of file cx24116.c.

#define CX24116_ROLLOFF_025   (0x01)

Definition at line 98 of file cx24116.c.

#define CX24116_ROLLOFF_035   (0x02)

Definition at line 99 of file cx24116.c.

#define CX24116_SEARCH_RANGE_KHZ   5000

Definition at line 58 of file cx24116.c.

#define CX24116_SIGNAL_MASK   (0xc0)

Definition at line 113 of file cx24116.c.

#define CX24116_STATUS_MASK   (0x0f)

Definition at line 112 of file cx24116.c.

#define dprintk (   args...)
Value:
do { \
if (debug) \
printk(KERN_INFO "cx24116: " args); \
} while (0)

Definition at line 51 of file cx24116.c.

Enumeration Type Documentation

enum cmds
Enumerator:
CMD_SET_VCO 
CMD_TUNEREQUEST 
CMD_MPEGCONFIG 
CMD_TUNERINIT 
CMD_BANDWIDTH 
CMD_GETAGC 
CMD_LNBCONFIG 
CMD_LNBSEND 
CMD_LNBDCLEVEL 
CMD_SET_TONE 
CMD_UPDFWVERS 
CMD_TUNERSLEEP 
CMD_AGCCONTROL 

Definition at line 143 of file cx24116.c.

Function Documentation

struct dvb_frontend* cx24116_attach ( const struct cx24116_config config,
struct i2c_adapter i2c 
)
read

Definition at line 1119 of file cx24116.c.

EXPORT_SYMBOL ( cx24116_attach  )
MODULE_AUTHOR ( "Steven Toth"  )
MODULE_DESCRIPTION ( "DVB Frontend module for Conexant cx24116/cx24118 hardware )
MODULE_LICENSE ( "GPL"  )
module_param ( debug  ,
int  ,
0644   
)
module_param ( toneburst  ,
int  ,
0644   
)
module_param ( esno_snr  ,
int  ,
0644   
)
MODULE_PARM_DESC ( debug  ,
"Activates frontend debugging (default:0)"   
)
MODULE_PARM_DESC ( toneburst  ,
"DiSEqC toneburst  0 = OFF,
= TONE CACHE 
)
MODULE_PARM_DESC ( esno_snr  ,
"SNR return  units,
= PERCENTAGE 0-100 
)