Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Functions | Variables
pmcc4_drv.c File Reference
#include <linux/types.h>
#include "pmcc4_sysdep.h"
#include <linux/errno.h>
#include <linux/kernel.h>
#include <linux/sched.h>
#include <linux/timer.h>
#include <linux/hdlc.h>
#include <asm/io.h>
#include "sbecom_inline_linux.h"
#include "libsbew.h"
#include "pmcc4_private.h"
#include "pmcc4.h"
#include "pmcc4_ioctls.h"
#include "musycc.h"
#include "comet.h"
#include "sbe_bid.h"

Go to the source code of this file.

Macros

#define pr_fmt(fmt)   KBUILD_MODNAME ": " fmt
 
#define STATIC   static
 
#define KERN_WARN   KERN_WARNING
 
#define sbeLinkMask
 
#define sbeLinkChange   0x40
 
#define sbeLinkDown   0x01
 
#define sbeAlarmsMask   0x07 /* red / yellow / blue alarm conditions */
 
#define sbeE1AlarmsMask   0x107 /* alarm conditions */
 
#define COMET_LBCMD_READ   0x80 /* read only (do not set, return read value) */
 

Functions

status_t c4_wk_chan_init (mpi_t *, mch_t *)
 
void c4_wq_port_cleanup (mpi_t *)
 
status_t c4_wq_port_init (mpi_t *)
 
int c4_loop_port (ci_t *, int, u_int8_t)
 
status_t c4_set_port (ci_t *, int)
 
status_t musycc_chan_down (ci_t *, int)
 
u_int32_t musycc_chan_proto (int)
 
status_t musycc_dump_ring (ci_t *, unsigned int)
 
status_t __init musycc_init (ci_t *)
 
void musycc_init_mdt (mpi_t *)
 
void musycc_serv_req (mpi_t *, u_int32_t)
 
void musycc_update_timeslots (mpi_t *)
 
void musycc_update_tx_thp (mch_t *)
 
void sbecom_set_loglevel (int d)
 
mch_tc4_find_chan (int channum)
 
ci_t *__init c4_new (void *hi)
 
void checkPorts (ci_t *ci)
 
STATIC void c4_watchdog (ci_t *ci)
 
void c4_cleanup (void)
 
int c4_get_portcfg (ci_t *ci)
 
status_t __init c4_init (ci_t *ci, u_char *func0, u_char *func1)
 
status_t __init c4_init2 (ci_t *ci)
 
status_t c4_frame_rw (ci_t *ci, struct sbecom_port_param *pp)
 
status_t c4_pld_rw (ci_t *ci, struct sbecom_port_param *pp)
 
status_t c4_musycc_rw (ci_t *ci, struct c4_musycc_param *mcp)
 
status_t c4_get_port (ci_t *ci, int portnum)
 
status_t c4_new_chan (ci_t *ci, int portnum, int channum, void *user)
 
status_t c4_del_chan (int channum)
 
status_t c4_del_chan_stats (int channum)
 
status_t c4_set_chan (int channum, struct sbecom_chan_param *p)
 
status_t c4_get_chan (int channum, struct sbecom_chan_param *p)
 
status_t c4_get_chan_stats (int channum, struct sbecom_chan_stats *p)
 
STATIC int c4_fifo_alloc (mpi_t *pi, int chan, int *len)
 
void c4_fifo_free (mpi_t *pi, int chan)
 
status_t c4_chan_up (ci_t *ci, int channum)
 
void c4_stopwd (ci_t *ci)
 
void sbecom_get_brdinfo (ci_t *ci, struct sbe_brd_info *bip, u_int8_t *bsn)
 
status_t c4_get_iidinfo (ci_t *ci, struct sbe_iid_info *iip)
 

Variables

int cxt1e1_log_level
 
int cxt1e1_max_mru
 
int cxt1e1_max_mtu
 
int max_rxdesc_used
 
int max_rxdesc_default
 
int max_txdesc_used
 
int max_txdesc_default
 
int drvr_state = SBE_DRVR_INIT
 
ci_tc4_list = 0
 
ci_tCI
 
unsigned int max_int = 0
 

Macro Definition Documentation

#define COMET_LBCMD_READ   0x80 /* read only (do not set, return read value) */

Definition at line 192 of file pmcc4_drv.c.

#define KERN_WARN   KERN_WARNING

Definition at line 49 of file pmcc4_drv.c.

#define pr_fmt (   fmt)    KBUILD_MODNAME ": " fmt

Definition at line 22 of file pmcc4_drv.c.

#define sbeAlarmsMask   0x07 /* red / yellow / blue alarm conditions */

Definition at line 189 of file pmcc4_drv.c.

#define sbeE1AlarmsMask   0x107 /* alarm conditions */

Definition at line 190 of file pmcc4_drv.c.

#define sbeLinkChange   0x40

Definition at line 187 of file pmcc4_drv.c.

#define sbeLinkDown   0x01

Definition at line 188 of file pmcc4_drv.c.

#define sbeLinkMask
Value:
0x41 /* change in signal status (lost/recovered) +
* state */

Definition at line 186 of file pmcc4_drv.c.

#define STATIC   static

Definition at line 45 of file pmcc4_drv.c.

Function Documentation

status_t c4_chan_up ( ci_t ci,
int  channum 
)

Definition at line 1238 of file pmcc4_drv.c.

void c4_cleanup ( void  )

Definition at line 476 of file pmcc4_drv.c.

status_t c4_del_chan ( int  channum)

Definition at line 1084 of file pmcc4_drv.c.

status_t c4_del_chan_stats ( int  channum)

Definition at line 1100 of file pmcc4_drv.c.

STATIC int c4_fifo_alloc ( mpi_t pi,
int  chan,
int len 
)

Definition at line 1187 of file pmcc4_drv.c.

void c4_fifo_free ( mpi_t pi,
int  chan 
)

Definition at line 1224 of file pmcc4_drv.c.

mch_t* c4_find_chan ( int  channum)

Definition at line 112 of file pmcc4_drv.c.

status_t c4_frame_rw ( ci_t ci,
struct sbecom_port_param pp 
)

Definition at line 759 of file pmcc4_drv.c.

status_t c4_get_chan ( int  channum,
struct sbecom_chan_param p 
)

Definition at line 1164 of file pmcc4_drv.c.

status_t c4_get_chan_stats ( int  channum,
struct sbecom_chan_stats p 
)

Definition at line 1175 of file pmcc4_drv.c.

status_t c4_get_iidinfo ( ci_t ci,
struct sbe_iid_info iip 
)

Definition at line 1537 of file pmcc4_drv.c.

status_t c4_get_port ( ci_t ci,
int  portnum 
)

Definition at line 900 of file pmcc4_drv.c.

int c4_get_portcfg ( ci_t ci)

Definition at line 514 of file pmcc4_drv.c.

status_t __init c4_init ( ci_t ci,
u_char func0,
u_char func1 
)

Definition at line 538 of file pmcc4_drv.c.

status_t __init c4_init2 ( ci_t ci)

Definition at line 672 of file pmcc4_drv.c.

int c4_loop_port ( ci_t ci,
int  portnum,
u_int8_t  cmd 
)

Definition at line 700 of file pmcc4_drv.c.

status_t c4_musycc_rw ( ci_t ci,
struct c4_musycc_param mcp 
)

Definition at line 836 of file pmcc4_drv.c.

ci_t* __init c4_new ( void hi)

Definition at line 134 of file pmcc4_drv.c.

status_t c4_new_chan ( ci_t ci,
int  portnum,
int  channum,
void user 
)

Definition at line 1020 of file pmcc4_drv.c.

status_t c4_pld_rw ( ci_t ci,
struct sbecom_port_param pp 
)

Definition at line 798 of file pmcc4_drv.c.

status_t c4_set_chan ( int  channum,
struct sbecom_chan_param p 
)

Definition at line 1113 of file pmcc4_drv.c.

status_t c4_set_port ( ci_t ci,
int  portnum 
)

Definition at line 915 of file pmcc4_drv.c.

void c4_stopwd ( ci_t ci)

Definition at line 1469 of file pmcc4_drv.c.

STATIC void c4_watchdog ( ci_t ci)

Definition at line 461 of file pmcc4_drv.c.

status_t c4_wk_chan_init ( mpi_t ,
mch_t  
)

INIT_WORK (struct work_struct *work, void (*function)(void *), void *data);

Definition at line 206 of file linux.c.

void c4_wq_port_cleanup ( mpi_t )

Definition at line 244 of file linux.c.

status_t c4_wq_port_init ( mpi_t )

Definition at line 221 of file linux.c.

void checkPorts ( ci_t ci)

Definition at line 195 of file pmcc4_drv.c.

status_t musycc_chan_down ( ci_t ,
int   
)
u_int32_t musycc_chan_proto ( int  )

Definition at line 726 of file musycc.c.

status_t musycc_dump_ring ( ci_t ,
unsigned  int 
)

Definition at line 223 of file musycc.c.

status_t __init musycc_init ( ci_t )

Definition at line 787 of file musycc.c.

void musycc_init_mdt ( mpi_t )

Definition at line 285 of file musycc.c.

void musycc_serv_req ( mpi_t ,
u_int32_t   
)

Definition at line 510 of file musycc.c.

void musycc_update_timeslots ( mpi_t )
void musycc_update_tx_thp ( mch_t )

Definition at line 311 of file musycc.c.

void sbecom_get_brdinfo ( ci_t ci,
struct sbe_brd_info bip,
u_int8_t bsn 
)

Definition at line 1478 of file pmcc4_drv.c.

void sbecom_set_loglevel ( int  d)

Definition at line 86 of file pmcc4_drv.c.

Variable Documentation

ci_t* c4_list = 0

Definition at line 80 of file pmcc4_drv.c.

ci_t* CI

Read some reserved location w/in the COMET chip as a usable VMETRO trigger point or other trace marking event.

Definition at line 81 of file pmcc4_drv.c.

int cxt1e1_log_level

Definition at line 112 of file linux.c.

int cxt1e1_max_mru

Definition at line 116 of file linux.c.

int cxt1e1_max_mtu

Definition at line 120 of file linux.c.

int drvr_state = SBE_DRVR_INIT

Definition at line 79 of file pmcc4_drv.c.

unsigned int max_int = 0

Definition at line 1017 of file pmcc4_drv.c.

int max_rxdesc_default

Definition at line 129 of file linux.c.

int max_rxdesc_used

Definition at line 128 of file linux.c.

int max_txdesc_default

Definition at line 125 of file linux.c.

int max_txdesc_used

Definition at line 124 of file linux.c.