GLAST / LAT > DAQ and FSW > FSW > Doxygen Index> LCBD / dev > lcbd / rad750


Interface   Data Structures   File List   Data Fields   Globals  

LCBD_p.h File Reference

Definitions of private LCBD Drivers structures. More...

#include <LCBD/LCBD_clk.h>
#include <LCBD/LCBD_evt.h>
#include <LCBD/LCBD_nut.h>
#include <LCBD/LCBD_rst.h>
#include <LCBD/LCBD_stats.h>
#include <PBS/FORK.h>
#include <PBS/TASK.h>
#include <PBS/L.h>
#include <PBS/MTX.h>
#include <PBS/SEM.h>
#include <MSG/MSG_pubdefs.h>
#include <PBI/Endianness.h>
#include <PBI/Attribute.h>
#include <PBS/BSWP.ih>
#include <LCBD/LCBD_drv.h>

Classes

struct  _LCBD_clk_ucb
 Clock Unit Control Block. More...
struct  _LCBD_hcb
 Handler control block. More...
struct  _LCBD_rst_msg
 Result dispatch messsage. More...
struct  _LCBD_rst_flush_msg
 Result flush dispatch messsage. More...
struct  _LCBD_rst_ccb
 The Command Control Block, describes the control information for needed to control access to the LCB's command request queue. More...
struct  _LCBD_rst_ucb
 Result Unit Control Block. More...
struct  _LCBD_evt_msg
 Event dispatch messsage. More...
struct  _LCBD_evt_cbb
 Cached information about the circular buffer. More...
struct  _LCBD_evt_fcb
 Event Unit free control block. More...
struct  _LCBD_evt_ucb
 Event Unit control block. More...
struct  _LCBD_siv_bf
 The driver's State Informat Vector, bit field representation. More...
struct  _LCBD_siv_us
 The driver's State Informat Vector, unsigned shorts. More...
union  _LCBD_siv
 Union of the bit field representation of the state vector with an unsigned int. More...
struct  _LCBD_ucb
 Control block for the 3 units that comprise the LCB. More...
struct  _LCBD_scb
 Statistics control block. More...
struct  _LCBD_ncb_msg
 Format of the fork notification messsage. More...
struct  _LCBD_ncb
 Notification control block. More...
struct  _LCBD_icb
 Interrupt control block. More...
struct  _LCBD_aib
 Asycnchronous Initialization Block. More...
struct  _LCBD
 Struct containing fundamental parameters for the LCB. More...

Defines

#define _DPRINTF(format, args...)
 expands to empty statement for production builds
#define CHECK_EQ(n, a, b)   struct Check_ ## n { int x[1 / (a == b) ]; }
 Checks is a = b, and if not the compiler will issue an error.
#define LCBD_K_INTERNAL_OP_STALL   0
 Used as the stall value for commands to the LCBD internal registers.

Typedefs

typedef enum _LCBD_DISPATCH_TYPE LCBD_DISPATCH_TYPE
 Typedef for enum __LCBD_DISPATCH_TYPE.
typedef struct _LCBD_clk_ucb LCBD_clk_ucb
 Typedef for struct _LCBD_clk_ucb.
typedef struct _LCBD_hcb LCBD_hcb
 Typedef for struct _LCBD_hcb.
typedef struct _LCBD_rst_msg LCBD_rst_msg
 Typedef for struct _LCBD_rst_msg.
typedef struct _LCBD_rst_flush_msg LCBD_rst_flush_msg
 Typedef for struct _LCBD_rst_flush_msg.
typedef struct _LCBD_rst_ccb LCBD_rst_ccb
 Typedef for struct _LCBD_rst_ccb.
typedef struct _LCBD_rst_ucb LCBD_rst_ucb
 Typedef for struct _LCBD_rst_ucb.
typedef struct _LCBD_evt_msg LCBD_evt_msg
 Typedef for struct _LCBD_evt_msg.
typedef struct _LCBD_evt_cbb LCBD_evt_cbb
 Typedef for struct _LCBD_evt_cbb.
typedef struct _LCBD_evt_fcb LCBD_evt_fcb
 Typedef for struct _LCBD_evt_fcb.
typedef struct _LCBD_evt_ucb LCBD_evt_ucb
 Typedef for struct _LCBD_evt_ucb.
typedef enum _LCBD_SIV_V LCBD_SIV_V
 Typedef for enum _LCBD_SIV_V.
typedef enum _LCBD_SIV_M LCBD_SIV_M
 Typedef for enum _LCBD_SIV_M.
typedef struct _LCBD_siv_bf LCBD_siv_bf
 Typedef for enum _LCBD_siv_bf.
typedef struct _LCBD_siv_us LCBD_siv_us
 Typedef for enum _LCBD_siv_us.
typedef union _LCBD_siv LCBD_siv
 Typedef for union _LCBD_siv.
typedef struct _LCBD_ucb LCBD_ucb
 Typedef for struct _LCBD_ucb.
typedef struct _LCBD_scb LCBD_scb
 Typedef for struct _LCBD_scb.
typedef struct _LCBD_ncb_msg LCBD_ncb_msg
 Typedef for struct _LCBD_ncb_msg.
typedef struct _LCBD_ncb LCBD_ncb
 Typedef for struct _LCBD_ncb.
typedef enum _LCBD_ICB_K_TYPE LCBD_ICB_K_TYPE
 Typedef for enum _LCBD_ICB_K_TYPE.
typedef struct _LCBD_icb LCBD_icb
 Typedef for struct _LCBD_icb.
typedef void(* LCBD_acb )(void *prm, LCBD lcb)
 Callback for LCBD_load asynchronous completion.
typedef enum _LCBD_aib_action LCBD_aib_action
 Typedef for enum _LCBD_aib_action.
typedef struct _LCBD_aib LCBD_aib
 Typedef for struct _LCBD_aib.

Enumerations

enum  _LCBD_DISPATCH_TYPE {
  LCBD_DISPATCH_TYPE_ISR = 0,
  LCBD_DISPATCH_TYPE_USR = 1
}
 Enumeration of the different types of events that cause bottom half processing. More...
enum  _LCBD_SIV_V {
  LCBD_SIV_V_PCI_UNINITIALIZED = 0,
  LCBD_SIV_V_SW_UNINITIALIZED = 1,
  LCBD_SIV_V_LATP_UNINITIALIZED = 2,
  LCBD_SIV_V_NOCLOCK = 3,
  LCBD_SIV_V_DISCONNECTED = 4,
  LCBD_SIV_V_RESULT_DISABLED = 5,
  LCBD_SIV_V_CNT = 6,
  LCBD_SIV_V_STATE = 16
}
 Bit field offsets for the State Information Vector. More...
enum  _LCBD_SIV_M {
  LCBD_SIV_M_PCI_UNINITIALIZED = (1 << LCBD_SIV_V_PCI_UNINITIALIZED),
  LCBD_SIV_M_SW_UNINITIALIZED = (1 << LCBD_SIV_V_SW_UNINITIALIZED),
  LCBD_SIV_M_LATP_UNINITIALIZED = (1 << LCBD_SIV_V_LATP_UNINITIALIZED),
  LCBD_SIV_M_NOCLOCK = (1 << LCBD_SIV_V_NOCLOCK),
  LCBD_SIV_M_DISCONNECTED = (1 << LCBD_SIV_V_DISCONNECTED),
  LCBD_SIV_M_RESULT_DISABLED = (1 << LCBD_SIV_V_RESULT_DISABLED),
  LCBD_SIV_M_STATE = 0xFFFF0000,
  LCBD_SIV_M_VEC_INITIAL_VALUE = (1 << LCBD_SIV_V_CNT) - 1,
  LCBD_SIV_M_STATE_ONLINE = (LCBD_STATE_ONLINE << LCBD_SIV_V_STATE),
  LCBD_SIV_M_STATE_OFFLINE = (LCBD_STATE_OFFLINE << LCBD_SIV_V_STATE),
  LCBD_SIV_M_STATE_UNINITIALIZED,
  LCBD_SIV_M_STATE_UNLOADING = (LCBD_STATE_UNLOADING << LCBD_SIV_V_STATE),
  LCBD_SIV_M_INITIAL_VALUE
}
 Bit field masks for the State Information Vector. More...
enum  _LCBD_ICB_K_TYPE {
  LCBD_ICB_K_TYPE_PCI = 0,
  LCBD_ICB_K_TYPE_PID = 1
}
 The interrupt source type.
enum  _LCBD_aib_action {
  LCBD_AIB_ACTION_AVAILABLE = -1,
  LCBD_AIB_ACTION_NO_ACCESS = 0,
  LCBD_AIB_ACTION_COMPLETE = 1,
  LCBD_AIB_ACTION_CANCEL = 2
}
 The action to perform. More...

Functions

static __inline unsigned int LCBD__pciLoad32 (volatile unsigned int *src) ATTR_UNUSED_OK
 Read a 32-bit integer from PCI Memory.
static __inline void LCBD__pciStore32 (volatile unsigned int *dest, unsigned int w) ATTR_UNUSED_OK
 Write a 32-bit integer to PCI Memory.
static __inline void LCBD__pciSynchStore32 (volatile unsigned int *dest, unsigned int w) ATTR_UNUSED_OK
 Write a 32-bit integer to PCI Memory.
static __inline unsigned int msr_get (void)
 Gets the value of the Power PC Machine Status Register.
static __inline unsigned int msr_clr (unsigned int msr)
 Clears the interrupt enable bit in the specified msr.
static __inline void msr_put (unsigned int msr)
 Puts/restores the specified msr back into the Machine Status Register.
unsigned int LCBD_stats_init (LCBD_scb *scb)
 Initializes the statistics control block.
unsigned int LCBD_stats_destroy (LCBD_scb *scb)
 Destroys the statistics control block.
unsigned int lcbd_csr_access (LCBD lcb, unsigned int value, unsigned int field_select, unsigned short int timeout, unsigned int *prv, unsigned int *cur)
 Utility routine to compose and execute an access command to LCB's CSR register independent of whether the driver is offline or online.
unsigned int lcbd_faults_access (LCBD lcb, unsigned int value, unsigned int field_select, unsigned short int timeout, unsigned int *prv, unsigned int *cur)
 Utility routine to compose and execute an access command to LCB's FAULTS register independent of whether the driver is offline or online.
unsigned int lcbd_create_handler (LCBD_hcb *hcb, const char *name, int priority, LCBD lcb, int que_cnt, const FORK_que_cfg *que_cfg, int que_id, unsigned int failure)
 Creates a FORK processing task.
FORK_cb_status lcbd_evt_handler (FORK_cb_prm parameter, FORK_msg_hdr *fork_msg)
 The main LCBD descriptor dispatching routine for event traffic.
FORK_cb_status lcbd_rst_handler (FORK_cb_prm parameter, FORK_msg_hdr *fork_msg)
 The main LCBD descriptor dispatching routine.
FORK_cb_status lcbd_rst_flush_handler (FORK_cb_prm parameter, FORK_msg_hdr *fork_msg)
 The main LCBD descriptor dispatching routine.
unsigned int lcbd_nut_post (LCBD lcb)
 Posts a message to the notify service task.
unsigned int lcbd_nut_handler_destroy (LCBD lcb, unsigned int *exit_status)
 Destroys the notification service task.


Detailed Description

Definitions of private LCBD Drivers structures.

Author:
Curt Brune -- curt@slac.stanford.edu

JJRussell -- russell@slac.stanford.edu

  CVS $Id: LCBD_p.h,v 1.18 2011/03/25 01:58:06 apw Exp $

Define Documentation

#define CHECK_EQ ( n,
a,
 )     struct Check_ ## n { int x[1 / (a == b) ]; }

Checks is a = b, and if not the compiler will issue an error.

Parameters:
n Unique identifying string (helps isolate the error)
a The value to check
b The value to check


Typedef Documentation

Callback for LCBD_load asynchronous completion.

Parameters:
prm A user specified parameter
lcb The LCB handle

Typedef for struct _LCBD_aib.

This structure is used to hold information needed to handle the asynchronous completion of the LATp-side initialization. This is necessary when, in the course of doing the LATp-side initialization, no clocks are found. An handler is attached to the CLK_ON interrupt that wakes-up a callback handler where the final portion of the LATp side initialization takes place.

Typedef for struct _LCBD_evt_fcb.

Information for freeing events

Typedef for struct _LCBD_evt_msg.

Describes the FORK message passed to the event handler

Typedef for struct _LCBD_evt_ucb.

Combines an generic handler control block with a specific message

Typedef for struct _LCBD_hcb.

Describes the parameters of a LCBD handler (either event or result)

Typedef for struct _LCBD_icb.

This structure controls the interrupt connection information

Typedef for struct _LCBD_ncb.

This structure controls the user notification of state transients.

Typedef for struct _LCBD_ncb_msg.

This is the format of the message exchanged by the LCBD notify routines and the fork receiver task.

Typedef for struct _LCBD_rst_ccb.

This data structure keeps track number of command requests that cannot be immediately queued to the driver. It is not completely the property of the result unit, being shared by between the submission code and the result handling code. This is structure represents a crack in the nice model of the LCB as 3 nearly separate units (clock, result and event). There is kind of a 4rth unit, the command submission unit, but this is its only software context, and, as pointed out, even this context is shared with the result unit. So, rather than breaking out another management unit (the command submission unit), this structure has been lumped into the result unit.

Typedef for struct _LCBD_rst_flush_msg.

Describes the FORK message passed to the result flush handler. This handler gets called back whenever the driver goes offline and there are messages on the pending que.

Typedef for struct _LCBD_rst_msg.

Describes the FORK message passed to the result handler

Typedef for struct _LCBD_rst_ucb.

Combines an generic handler control block with a specific message

Typedef for struct _LCBD_scb.

The block contains the context used by the LCBD statistics routines. These routines do not control the accumulation of the statistics, but manage the fetching and clearing of them.

Typedef for union _LCBD_siv.

See also:
union _LCBD_siv

Typedef for enum _LCBD_siv_bf.

The state information vector is a series of bit flags describing the state of driver, such as is the driver is uninitialized, is the driver disconnected from the PCI interrupt, is the clock absent. It is presented in a negative logic fashion so that a state informaton vector of 0 indicates the driver is in an ONLINE state.

Typedef for enum _LCBD_SIV_M.

See also:
enum _LCBD_siv_bf

union _LCBD_siv

Typedef for enum _LCBD_SIV_V.

See also:
enum _LCBD_siv_bf

union _LCBD_siv

Typedef for struct _LCBD_ucb.

The block contains the context used by the LCBD to control each of its three (nearly) distinct units. These units are

  1. Clock
  2. Command/Result Unit
  3. Event


Enumeration Type Documentation

The action to perform.

Enumerator:
LCBD_AIB_ACTION_AVAILABLE  Available
LCBD_AIB_ACTION_NO_ACCESS  Don't use
LCBD_AIB_ACTION_COMPLETE  Complete the initialization
LCBD_AIB_ACTION_CANCEL  Cancel the initialization

Enumeration of the different types of events that cause bottom half processing.

Enumerator:
LCBD_DISPATCH_TYPE_ISR  ISR kicked off the bottom half processing
LCBD_DISPATCH_TYPE_USR  User kicked off the bottom half processing

Bit field masks for the State Information Vector.

Enumerator:
LCBD_SIV_M_PCI_UNINITIALIZED  PCI portion of the driver is uninitialized
LCBD_SIV_M_SW_UNINITIALIZED  Software portion of the driver is uninitialized
LCBD_SIV_M_LATP_UNINITIALIZED  LATP portion of the driver is uninitialized
LCBD_SIV_M_NOCLOCK  Driver has no 20MHz LATp clock
LCBD_SIV_M_DISCONNECTED  Driver is not connect
LCBD_SIV_M_RESULT_DISABLED  Result interrupt has not be user enabled
LCBD_SIV_M_STATE  State word
LCBD_SIV_M_VEC_INITIAL_VALUE  Initial value of the bit vector to start at
LCBD_SIV_M_STATE_ONLINE  Online value in state vector
LCBD_SIV_M_STATE_OFFLINE  Offline value in state vector
LCBD_SIV_M_STATE_UNINITIALIZED  Uninitialized value in state vector
LCBD_SIV_M_STATE_UNLOADING  Unloading value in state vector

Bit field offsets for the State Information Vector.

Enumerator:
LCBD_SIV_V_PCI_UNINITIALIZED  PCI portion of the driver
LCBD_SIV_V_SW_UNINITIALIZED  Software portion of the driver
LCBD_SIV_V_LATP_UNINITIALIZED  LATp side of the driver
LCBD_SIV_V_NOCLOCK  Driver was no 20MHz LATp clock
LCBD_SIV_V_DISCONNECTED  Driver is not connect
LCBD_SIV_V_RESULT_DISABLED  Result interrupt not user enable
LCBD_SIV_V_CNT  Count of state bits
LCBD_SIV_V_STATE  State word


Function Documentation

static __inline unsigned int LCBD__pciLoad32 ( volatile unsigned int *  src  )  [static]

Read a 32-bit integer from PCI Memory.

Parameters:
src Pointer source memory location
Returns:
value at memory location pointed to be src
See also:
LCBD__pciStore32()
This function performs the necessary byte swapping when reading PCI Memory (PCI bus is inherently little-endian).

Referenced by drain_event(), init_latp(), LCBD_enable(), LCBD_evt_conds_set(), lcbd_evt_handler(), LCBD_evt_tickle(), LCBD_fabric_read(), LCBD_fabric_select(), lcbd_isr(), LCBD_pci_csr_read(), LCBD_pci_eventq_read(), LCBD_pci_events_base_read(), LCBD_pci_events_free_read(), LCBD_pci_fabric_select_read(), LCBD_pci_irq_read(), LCBD_pci_requestq_read(), LCBD_pci_resultq_read(), lcbd_rst_handler(), poll(), and submit().

static __inline void LCBD__pciStore32 ( volatile unsigned int *  dest,
unsigned int  w 
) [static]

Write a 32-bit integer to PCI Memory.

Parameters:
dest Pointer destination memory
w 32-bit value to store
Returns:
LCBD_OK on success
See also:
LCBD__pciLoad32()
This function performs the necessary byte swapping when writing PCI Memory (PCI bus is inherently little-endian).

Note:
At one point in time (before 3.25.09), this routine did an eieio instruction after the write. EJS and JJ decided that, in all cases, this was unnecessary and in the case of a write to the request register, was insufficient, where a synch instruction before the write is required. Therefore, all PCI writes to registers other than the request register should use LCBD_pciStore32 and all writes to the request register should use LCBD_pciSynchStore32.

Referenced by init_circ(), init_latp(), init_pci(), LCBD_enable(), LCBD_evt_conds_set(), lcbd_evt_handler(), LCBD_evt_rng_free(), LCBD_evt_tickle(), lcbd_isr(), LCBD_pci_csr_write(), LCBD_pci_events_base_write(), LCBD_pci_events_free_write(), LCBD_pci_fabric_select_write(), LCBD_pci_irq_write(), lcbd_rst_handler(), and select_fabric().

static __inline void LCBD__pciSynchStore32 ( volatile unsigned int *  dest,
unsigned int  w 
) [static]

Write a 32-bit integer to PCI Memory.

Parameters:
dest Pointer destination memory
w 32-bit value to store
Returns:
LCBD_OK on success
See also:
LCBD__pciLoad32()
This function performs the necessary byte swapping when writing PCI Memory (PCI bus is inherently little-endian). For the PowerPC the function also issues an "eieio" instruction to insure the write instruction complete before other loads and stores.

Referenced by LCBD_pci_requestq_write(), and submit().

unsigned int lcbd_create_handler ( LCBD_hcb hcb,
const char *  name,
int  priority,
LCBD  lcb,
int  que_cnt,
const FORK_que_cfg *  que_cfg,
int  que_id,
unsigned int  failure 
)

Creates a FORK processing task.

Returns:
Status
Parameters:
hcb The LCBD handler control block, upon success, this is filled in with information about the newly created FORK task.
name The name of the FORK task
priority The priority of the task
lcb Used as the callback parameter to the handler
que_cnt The number of queues to configure
que_cfg The configuration of each que
que_id The que id to use for the handler
failure Status code to use in case of failure

References _LCBD_hcb::fcb, LCBD_OK, and _LCBD_hcb::que.

Referenced by LCBD_evt_handler_create(), LCBD_nut_handler_create(), and LCBD_rst_handler_create().

unsigned int lcbd_csr_access ( LCBD  lcb,
unsigned int  value,
unsigned int  field_select,
unsigned short int  stall,
unsigned int *  prv,
unsigned int *  cur 
)

Utility routine to compose and execute an access command to LCB's CSR register independent of whether the driver is offline or online.

Returns:
Status
Parameters:
lcb The LCB driver handle
value The value to write. Only bits matching those in the field_select parameter will actually be written.
field_select Pattern of those bits in value to write
stall The stall period, in units of 20MHz clock ticks, for the LCB to wait for completion.
prv Pointer to receive the value of the register before modification. This may be NULL.
cur Pointer to receive the value of the register after modification. This may be NULL.

References LCBC_csr_access(), LCBD_STATE_ONLINE, and poll_csr_access().

Referenced by LCBD_board_id_set(), LCBD_clk_edge_set(), LCBD_evt_enable(), and LCBD_width_set().

FORK_cb_status lcbd_evt_handler ( FORK_cb_prm  parameter,
FORK_msg_hdr *  fork_msg 
)

unsigned int lcbd_faults_access ( LCBD  lcb,
unsigned int  value,
unsigned int  field_select,
unsigned short int  stall,
unsigned int *  prv,
unsigned int *  cur 
)

Utility routine to compose and execute an access command to LCB's FAULTS register independent of whether the driver is offline or online.

Returns:
Status
Parameters:
lcb The LCB driver handle
value The value to write. Only bits matching those in the field_select parameter will actually be written.
field_select Pattern of those bits in value to write
stall The stall time, in units of 20MHz clock ticks, for the LCB to wait for completion.
prv Pointer to receive the value of the register before modification. This may be NULL.
cur Pointer to receive the value of the register after modification. This may be NULL.

References LCBC_faults_access(), LCBD_STATE_ONLINE, and poll_faults_access().

Referenced by LCBD_faults_read().

unsigned int lcbd_nut_handler_destroy ( LCBD  lcb,
unsigned int *  exit_status 
)

Destroys the notification service task.

Returns:
The status of from FORK_destroy
Parameters:
lcb The LCB driver handle
exit_status Pointer to receive the exit status of the notification routine.

References lcbd_nut_post(), and LCBD_OK.

Referenced by destroy_sw().

unsigned int lcbd_nut_post ( LCBD  lcb  ) 

Posts a message to the notify service task.

Returns:
Status from FORK_qusr
Parameters:
lcb The LCB driver handle

References LCBD_OK, and notify().

Referenced by handle_clks(), lcbd_nut_handler_destroy(), and LCBD_nut_notify().

FORK_cb_status lcbd_rst_flush_handler ( FORK_cb_prm  parameter,
FORK_msg_hdr *  fork_msg 
)

The main LCBD descriptor dispatching routine.

Parameters:
parameter lcb Pointer to private LCBD structure
fork_msg FORK system message
Returns:
FORK_C_CONTINUE This routine is the result flushing service. This routine gets called back in the context of the result handling task. When the driver goes offline, a message is queued to this routine containing a list head of all the transaction to dismiss.

References LCB_RST_ERR_XFR_IN_UNDEFINED_7, _LCBD_xcb_sys::prm, _LCBD_xcb_usr::rd, _LCBD_xcb_sys::rtn, _LCBD_xcb::sys, _LCB_rst_dsc::ui, and _LCBD_xcb::usr.

Referenced by handle_clks().

FORK_cb_status lcbd_rst_handler ( FORK_cb_prm  parameter,
FORK_msg_hdr *  fork_msg 
)

The main LCBD descriptor dispatching routine.

Parameters:
parameter lcb Pointer to private LCBD structure
fork_msg FORK system message
Returns:
FORK_C_CONTINUE This routine is the result queue servicing task, where the real work of reading the LCB RESULT Q and dispatching of descriptors is done.
The msg parameter could be use to indicate who "tickled" the processing. The usual suspects are the ISR or a user.

References _LCB_rst_dsc::bf, _LCB_rst_dsc::bfd, _LCBD_rst_ucb::ccb, _LCBD_stats_rst::cnts, _LCB_rst_dsc_bfd::dir, _LCB_prb::irq, LCB_PCI_IRQ_M_ENABLE_RESULT, LCB_RST_DSC_M_ADR, LCB_RST_ERR_XFR_OUT_Q_EMPTY, LCBD__pciLoad32(), LCBD__pciStore32(), LCBD_RST_FATE_M_NO_MORE, LCBD_RST_FATE_M_NO_REARM, locate(), msr_clr(), msr_get(), msr_put(), _LCBD_rst_ucb::null, _LCBD_stats_rst::null, _LCBD_xcb_sys::prm, _LCBD_rst_null_cbp::prm, _LCBD_xcb_usr::rd, _LCBD_rst_msg::rd, _LCB_prb::result_queue, retire(), _LCBD_xcb_sys::rtn, _LCBD_rst_null_cbp::rtn, _LCBD_stats_rst::seq, _LCBD_xcb::sys, _LCB_rst_dsc::ui, _LCBD_xcb::usr, and _LCB_rst_dsc_bf::xstatus.

Referenced by lcbd_isr().

unsigned int LCBD_stats_destroy ( LCBD_scb scb  ) 

Destroys the statistics control block.

Return values:
LCBD_OK,on success
Anything else, failure
Parameters:
scb Pointer to the statistics control block to destroy

References LCBD_OK, _LCBD_scb::ledgerValid, and _LCBD_scb::mutex.

Referenced by destroy_sw().

unsigned int LCBD_stats_init ( LCBD_scb scb  ) 

Initializes the statistics control block.

Return values:
LCBD_OK,on success
LCBD_STATSIFL,on failure
Parameters:
scb Pointer to the statistics control block to initialize

References _LCBD_scb::active, _LCBD_stats_tim::beg, _LCBD_scb::clear, LCBD_OK, _LCBD_scb::ledger, _LCBD_scb::ledgerValid, _LCBD_scb::mutex, _LCBD_scb::stats, and _LCBD_stats::tim.

Referenced by init_sw().

static __inline unsigned int msr_clr ( unsigned int  msr  )  [static]

Clears the interrupt enable bit in the specified msr.

Returns:
The value of the Power PC Machine Status Register with the interrupt enable bit cleared
Parameters:
msr The value of the machine status register to clear the interrupt in.

Referenced by lcbd_evt_handler(), LCBD_evt_rng_free(), and lcbd_rst_handler().

static __inline unsigned int msr_get ( void   )  [static]

Gets the value of the Power PC Machine Status Register.

Returns:
The value of the Power PC Machine Status Register

Referenced by lcbd_evt_handler(), LCBD_evt_rng_free(), and lcbd_rst_handler().

static __inline void msr_put ( unsigned int  msr  )  [static]

Puts/restores the specified msr back into the Machine Status Register.

Parameters:
msr The value of the machine status register to put

Referenced by lcbd_evt_handler(), LCBD_evt_rng_free(), and lcbd_rst_handler().


Generated on Thu Mar 24 19:09:40 2011 by  doxygen 1.5.8