IAP restart policy
[Policy modules]


Defines

#define POLICY_IAP_RESTART_MIN   0
#define POLICY_IAP_RESTART_DEFAULT   25
#define POLICY_IAP_RESTART_MAX   40
#define POLICY_IAP_RESTART_COUNT_GCONF_PATH

Functions

void icd_policy_init (struct icd_policy_api *policy_api, icd_policy_nw_add_fn add_network)
static gint policy_iap_restart_value (void)
static enum icd_policy_status policy_iap_restart (struct icd_policy_request *request, guint restart_count, gpointer *private)

Define Documentation

#define POLICY_IAP_RESTART_COUNT_GCONF_PATH

Value:

ICD_GCONF_SETTINGS \
                     "/policy/policy_iap_restart/restart_count"
gconf location for restart count

Referenced by policy_iap_restart_value().

#define POLICY_IAP_RESTART_DEFAULT   25

default value for restart count

Referenced by policy_iap_restart_value().

#define POLICY_IAP_RESTART_MAX   40

max value for restart count

Referenced by policy_iap_restart_value().

#define POLICY_IAP_RESTART_MIN   0

min value for restart count

Referenced by policy_iap_restart_value().


Function Documentation

void icd_policy_init ( struct icd_policy_api policy_api,
icd_policy_nw_add_fn  add_network 
)

Policy module initialization function.

Parameters:
policy_api policy API structure to be filled in by the module
add_network function to add a network in response to a policy

References policy_iap_restart(), and icd_policy_api::restart.

static enum icd_policy_status policy_iap_restart ( struct icd_policy_request request,
guint  restart_count,
gpointer *  private 
) [static]

Restart policy

Parameters:
request the connection request
restart_count how many times the network module has requested ICD_NW_RESTART
private not used

References ICD_POLICY_ACCEPTED, ICD_POLICY_REJECTED, and policy_iap_restart_value().

Referenced by icd_policy_init().

static gint policy_iap_restart_value ( void   )  [static]

Read the restart count value from gconf

Returns:
restart count value between POLICY_IAP_RESTART_MIN and POLICY_IAP_RESTART_MAX.

References ILOG_DEBUG, ILOG_WARN, POLICY_IAP_RESTART_COUNT_GCONF_PATH, POLICY_IAP_RESTART_DEFAULT, POLICY_IAP_RESTART_MAX, and POLICY_IAP_RESTART_MIN.

Referenced by policy_iap_restart().


Generated on Thu Mar 11 09:04:50 2010 for ICd2 by  doxygen 1.5.6