Ack, 
Not tested.
Mathi.

> -----Original Message-----
> From: Alex Jones [mailto:[email protected]]
> Sent: Friday, September 18, 2015 8:25 PM
> To: Mathivanan Naickan Palanivelu
> Cc: [email protected]
> Subject: [PATCH 1 of 1] plm: fix deactivate for ATCA [#1289]
> 
>  osaf/services/saf/plmsv/plms/plms_he_pres_fsm.c |  6 ++++++
>  1 files changed, 6 insertions(+), 0 deletions(-)
> 
> 
> When SA_PLM_ADMIN_DEACTIVATE is issued for an ATCA FRU, the HE
> presence state gets stuck in SA_PLM_HE_PRESENCE_DEACTIVATING, and
> never transitions to SA_PLM_HE_PRESENCE_INACTIVE.
> 
> The "act_in_pro" and "deact_in_pro" variables for the entity are not cleared.
> So, when the HPI hotswap state event occurs which says that the entity has
> been deactivated, PLM never transitions the state to INACTIVE.
> 
> "act_in_pro" and "deact_in_pro" need to be cleared before setting
> SA_PLM_HE_PRESENCE_DEACTIVATING and
> SA_PLM_HE_PRESENCE_ACTIVATING, respectively, so that when we receive
> the HPI hotswap state event, the FRU can be deactivated or activated.
> 
> diff --git a/osaf/services/saf/plmsv/plms/plms_he_pres_fsm.c
> b/osaf/services/saf/plmsv/plms/plms_he_pres_fsm.c
> --- a/osaf/services/saf/plmsv/plms/plms_he_pres_fsm.c
> +++ b/osaf/services/saf/plmsv/plms/plms_he_pres_fsm.c
> @@ -182,6 +182,9 @@ static SaUint32T plms_HE_inact_np_to_ins
>               TRACE_LEAVE2("Return Val: %d",ret_err);
>               return ret_err;
>       }
> +
> +     ent->act_in_pro = false;
> +
>       /* Mark the presence state of the HE to activating.*/
> 
>       plms_presence_state_set(ent,SA_PLM_HE_PRESENCE_ACTIVATING
> ,NULL,
>                                       SA_NTF_OBJECT_OPERATION,
> @@ -765,6 +768,9 @@ static SaUint32T plms_HE_act_to_extpendi
>               TRACE_LEAVE2("Return Val: %d",NCSCC_RC_FAILURE);
>               return NCSCC_RC_FAILURE;
>       }
> +
> +     ent->deact_in_pro = false;
> +
> 
>       plms_presence_state_set(ent,SA_PLM_HE_PRESENCE_DEACTIVATI
> NG,
> 
>       NULL,SA_NTF_OBJECT_OPERATION,
> 
>       SA_PLM_NTFID_STATE_CHANGE_ROOT);
> 

------------------------------------------------------------------------------
_______________________________________________
Opensaf-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-devel

Reply via email to