[svn-commits] rmudgett: branch group/ccss r1391 - in /team/group/ccss: ./ doc/

SVN commits to the Digium repositories svn-commits at lists.digium.com
Wed Dec 16 16:56:33 CST 2009


Author: rmudgett
Date: Wed Dec 16 16:56:31 2009
New Revision: 1391

URL: http://svnview.digium.com/svn/libpri?view=rev&rev=1391
Log:
*  Renamed action promote_a_status to promote_raw_a_status.
*  Made A status actions available to all CC FSM's instead of just PTMP.

Modified:
    team/group/ccss/doc/cc_ptmp_agent.fsm
    team/group/ccss/doc/cc_ptmp_agent_flattened.fsm
    team/group/ccss/pri_cc.c
    team/group/ccss/pri_internal.h

Modified: team/group/ccss/doc/cc_ptmp_agent.fsm
URL: http://svnview.digium.com/svn/libpri/team/group/ccss/doc/cc_ptmp_agent.fsm?view=diff&rev=1391&r1=1390&r2=1391
==============================================================================
--- team/group/ccss/doc/cc_ptmp_agent.fsm (original)
+++ team/group/ccss/doc/cc_ptmp_agent.fsm Wed Dec 16 16:56:31 2009
@@ -125,7 +125,7 @@
 		}
 		Stimulus CC_EVENT_A_FREE {
 			Action Set_Raw_A_Status_Free;
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Action Pass_Up_Status_Rsp_A;
 			Action Stop_T_CCBS1;
 		}
@@ -134,7 +134,7 @@
 			Action Pass_Up_Status_Rsp_A;
 		}
 		Stimulus CC_EVENT_TIMEOUT_T_CCBS1 {
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Test = Get_A_Status;
 			Test == Invalid {
 				/*
@@ -172,7 +172,7 @@
 		Stimulus CC_EVENT_A_FREE {
 			Action Send_RemoteUserFree;
 			Action Set_Raw_A_Status_Free;
-			//Action Promote_A_Status;
+			//Action Promote_Raw_A_Status;
 			//Action Pass_Up_A_Status;
 			Test = Get_Extended_T_CCBS1_Status;
 			Test == Active {
@@ -200,7 +200,7 @@
 			}
 			/* Only received User A is busy. */
 			Action Send_CCBSBFree;
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Action Pass_Up_A_Status;
 			Next_State CC_STATE_SUSPENDED;
 		}
@@ -225,7 +225,7 @@
 		}
 		Stimulus CC_EVENT_A_FREE {
 			Action Set_Raw_A_Status_Free;
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Action Pass_Up_A_Status;
 			Test = Get_Extended_T_CCBS1_Status;
 			Test == Active {

Modified: team/group/ccss/doc/cc_ptmp_agent_flattened.fsm
URL: http://svnview.digium.com/svn/libpri/team/group/ccss/doc/cc_ptmp_agent_flattened.fsm?view=diff&rev=1391&r1=1390&r2=1391
==============================================================================
--- team/group/ccss/doc/cc_ptmp_agent_flattened.fsm (original)
+++ team/group/ccss/doc/cc_ptmp_agent_flattened.fsm Wed Dec 16 16:56:31 2009
@@ -139,7 +139,7 @@
 		}
 		Stimulus CC_EVENT_A_FREE {
 			Action Set_Raw_A_Status_Free;
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Action Pass_Up_Status_Rsp_A;
 			Action Stop_T_CCBS1;
 		}
@@ -148,7 +148,7 @@
 			Action Pass_Up_Status_Rsp_A;
 		}
 		Stimulus CC_EVENT_TIMEOUT_T_CCBS1 {
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Test = Get_A_Status;
 			Test == Invalid {
 				/*
@@ -208,7 +208,7 @@
 		Stimulus CC_EVENT_A_FREE {
 			Action Send_RemoteUserFree;
 			Action Set_Raw_A_Status_Free;
-			//Action Promote_A_Status;
+			//Action Promote_Raw_A_Status;
 			//Action Pass_Up_A_Status;
 			Test = Get_Extended_T_CCBS1_Status;
 			Test == Active {
@@ -243,7 +243,7 @@
 			}
 			/* Only received User A is busy. */
 			Action Send_CCBSBFree;
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Action Pass_Up_A_Status;
 			/* Optimization due to flattening. */
 			//Test = Get_T_CCBS1_Status;
@@ -294,7 +294,7 @@
 		}
 		Stimulus CC_EVENT_A_FREE {
 			Action Set_Raw_A_Status_Free;
-			Action Promote_A_Status;
+			Action Promote_Raw_A_Status;
 			Action Pass_Up_A_Status;
 			Test = Get_Extended_T_CCBS1_Status;
 			Test == Active {

Modified: team/group/ccss/pri_cc.c
URL: http://svnview.digium.com/svn/libpri/team/group/ccss/pri_cc.c?view=diff&rev=1391&r1=1390&r2=1391
==============================================================================
--- team/group/ccss/pri_cc.c (original)
+++ team/group/ccss/pri_cc.c Wed Dec 16 16:56:31 2009
@@ -2445,6 +2445,21 @@
 
 /*!
  * \internal
+ * \brief FSM action to promote raw A status.
+ *
+ * \param ctrl D channel controller.
+ * \param cc_record Call completion record to process event.
+ *
+ * \return Nothing
+ */
+static void pri_cc_act_promote_raw_a_status(struct pri *ctrl, struct pri_cc_record *cc_record)
+{
+	PRI_CC_ACT_DEBUG_OUTPUT(ctrl);
+	cc_record->party_a_status = cc_record->fsm.ptmp.party_a_status_acc;
+}
+
+/*!
+ * \internal
  * \brief FSM action to reset A status.
  *
  * \param ctrl D channel controller.
@@ -2455,40 +2470,25 @@
 static void pri_cc_act_reset_a_status(struct pri *ctrl, struct pri_cc_record *cc_record)
 {
 	PRI_CC_ACT_DEBUG_OUTPUT(ctrl);
-	cc_record->fsm.ptmp.party_a_status = CC_PARTY_A_AVAILABILITY_INVALID;
-}
-
-/*!
- * \internal
- * \brief FSM action to promote raw A status.
- *
- * \param ctrl D channel controller.
- * \param cc_record Call completion record to process event.
- *
- * \return Nothing
- */
-static void pri_cc_act_promote_a_status(struct pri *ctrl, struct pri_cc_record *cc_record)
-{
+	cc_record->party_a_status = CC_PARTY_A_AVAILABILITY_INVALID;
+}
+
+/*!
+ * \internal
+ * \brief FSM action to pass up party A status to upper layer.
+ *
+ * \param ctrl D channel controller.
+ * \param cc_record Call completion record to process event.
+ *
+ * \return Nothing
+ */
+static void pri_cc_act_pass_up_a_status(struct pri *ctrl, struct pri_cc_record *cc_record)
+{
+	struct pri_subcommand *subcmd;
+
 	PRI_CC_ACT_DEBUG_OUTPUT(ctrl);
-	cc_record->fsm.ptmp.party_a_status = cc_record->fsm.ptmp.party_a_status_acc;
-}
-
-/*!
- * \internal
- * \brief FSM action to pass up party A status to upper layer.
- *
- * \param ctrl D channel controller.
- * \param cc_record Call completion record to process event.
- *
- * \return Nothing
- */
-static void pri_cc_act_pass_up_a_status(struct pri *ctrl, struct pri_cc_record *cc_record)
-{
-	struct pri_subcommand *subcmd;
-
-	PRI_CC_ACT_DEBUG_OUTPUT(ctrl);
-
-	if (cc_record->fsm.ptmp.party_a_status == CC_PARTY_A_AVAILABILITY_INVALID) {
+
+	if (cc_record->party_a_status == CC_PARTY_A_AVAILABILITY_INVALID) {
 		/* Party A status is invalid so don't pass it up. */
 		return;
 	}
@@ -2501,7 +2501,7 @@
 	subcmd->cmd = PRI_SUBCMD_CC_STATUS;
 	subcmd->u.cc_status.cc_id =  cc_record->record_id;
 	subcmd->u.cc_status.status =
-		(cc_record->fsm.ptmp.party_a_status == CC_PARTY_A_AVAILABILITY_FREE)
+		(cc_record->party_a_status == CC_PARTY_A_AVAILABILITY_FREE)
 		? 0 /* free */ : 1 /* busy */;
 }
 
@@ -2977,7 +2977,7 @@
 		pri_cc_act_send_ccbs_b_free(ctrl, cc_record);
 		break;
 	case CC_EVENT_REMOTE_USER_FREE:
-		switch (cc_record->fsm.ptmp.party_a_status) {
+		switch (cc_record->party_a_status) {
 		case CC_PARTY_A_AVAILABILITY_INVALID:
 			if (!pri_cc_get_t_ccbs1_status(cc_record)) {
 				pri_cc_act_reset_raw_a_status(ctrl, cc_record);
@@ -3022,7 +3022,7 @@
 		break;
 	case CC_EVENT_A_FREE:
 		pri_cc_act_set_raw_a_status_free(ctrl, cc_record);
-		pri_cc_act_promote_a_status(ctrl, cc_record);
+		pri_cc_act_promote_raw_a_status(ctrl, cc_record);
 		pri_cc_act_pass_up_a_status(ctrl, cc_record);
 		pri_cc_act_stop_t_ccbs1(ctrl, cc_record);
 		break;
@@ -3031,8 +3031,8 @@
 		pri_cc_act_pass_up_status_rsp_a(ctrl, cc_record);
 		break;
 	case CC_EVENT_TIMEOUT_T_CCBS1:
-		pri_cc_act_promote_a_status(ctrl, cc_record);
-		if (cc_record->fsm.ptmp.party_a_status == CC_PARTY_A_AVAILABILITY_INVALID) {
+		pri_cc_act_promote_raw_a_status(ctrl, cc_record);
+		if (cc_record->party_a_status == CC_PARTY_A_AVAILABILITY_INVALID) {
 			/*
 			 * Did not get any responses.
 			 * User A no longer present.
@@ -3106,7 +3106,7 @@
 	case CC_EVENT_A_FREE:
 		pri_cc_act_send_remote_user_free(ctrl, cc_record);
 		pri_cc_act_set_raw_a_status_free(ctrl, cc_record);
-		//pri_cc_act_promote_a_status(ctrl, cc_record);
+		//pri_cc_act_promote_raw_a_status(ctrl, cc_record);
 		//pri_cc_act_pass_up_a_status(ctrl, cc_record);
 		if (cc_record->fsm.ptmp.extended_t_ccbs1) {
 			pri_cc_act_pass_up_status_rsp_a(ctrl, cc_record);
@@ -3139,7 +3139,7 @@
 		}
 		/* Only received User A busy. */
 		pri_cc_act_send_ccbs_b_free(ctrl, cc_record);
-		pri_cc_act_promote_a_status(ctrl, cc_record);
+		pri_cc_act_promote_raw_a_status(ctrl, cc_record);
 		pri_cc_act_pass_up_a_status(ctrl, cc_record);
 		/* Optimization due to flattening. */
 		//if (!pri_cc_get_t_ccbs1_status(cc_record))
@@ -3206,7 +3206,7 @@
 		break;
 	case CC_EVENT_A_FREE:
 		pri_cc_act_set_raw_a_status_free(ctrl, cc_record);
-		pri_cc_act_promote_a_status(ctrl, cc_record);
+		pri_cc_act_promote_raw_a_status(ctrl, cc_record);
 		pri_cc_act_pass_up_a_status(ctrl, cc_record);
 		if (cc_record->fsm.ptmp.extended_t_ccbs1) {
 			pri_cc_act_pass_up_status_rsp_a(ctrl, cc_record);

Modified: team/group/ccss/pri_internal.h
URL: http://svnview.digium.com/svn/libpri/team/group/ccss/pri_internal.h?view=diff&rev=1391&r1=1390&r2=1391
==============================================================================
--- team/group/ccss/pri_internal.h (original)
+++ team/group/ccss/pri_internal.h Wed Dec 16 16:56:31 2009
@@ -754,8 +754,6 @@
 			int t_ccbs1_invoke_id;
 			/*! Accumulating party A availability status */
 			enum CC_PARTY_A_AVAILABILITY party_a_status_acc;
-			/*! Party A availability status */
-			enum CC_PARTY_A_AVAILABILITY party_a_status;
 		} ptmp;
 		/*! PTP FSM parameters. */
 		struct {
@@ -771,6 +769,8 @@
 			int code;
 		} cc_req_rsp;
 	} msg;
+	/*! Party A availability status */
+	enum CC_PARTY_A_AVAILABILITY party_a_status;
 	/*!
 	 * \brief PTMP T_RETENTION timer id.
 	 * \note




More information about the svn-commits mailing list