Example #1
0
 public void MarshalSaHpiWatchdogT( SaHpiWatchdogT x )
 {
     MarshalSaHpiBoolT( x.Log );
     MarshalSaHpiBoolT( x.Running );
     MarshalSaHpiWatchdogTimerUseT( x.TimerUse );
     MarshalSaHpiWatchdogActionT( x.TimerAction );
     MarshalSaHpiWatchdogPretimerInterruptT( x.PretimerInterrupt );
     MarshalSaHpiUint32T( x.PreTimeoutInterval );
     MarshalSaHpiWatchdogExpFlagsT( x.TimerUseExpFlags );
     MarshalSaHpiUint32T( x.InitialCount );
     MarshalSaHpiUint32T( x.PresentCount );
 }
Example #2
0
            public static long saHpiWatchdogTimerSet(
        long SessionId,
        long ResourceId,
        long WatchdogNum,
        SaHpiWatchdogT Watchdog
    )
            {
                long rv;
                bool rc;
                rc = HpiUtil.Check( Watchdog );
                if ( !rc ) {
                return HpiConst.SA_ERR_HPI_INVALID_PARAMS;
                }

                HpiSession s = HpiCore.GetSession( SessionId );
                if ( s == null ) {
                return HpiConst.SA_ERR_HPI_INVALID_SESSION;
                }
                OhpiMarshal m = s.GetMarshal();
                if ( m == null ) {
                return HpiConst.SA_ERR_HPI_NO_RESPONSE;
                }

                m.MarshalSaHpiSessionIdT( s.GetRemoteSid() );
                m.MarshalSaHpiResourceIdT( ResourceId );
                m.MarshalSaHpiWatchdogNumT( WatchdogNum );
                m.MarshalSaHpiWatchdogT( Watchdog );
                rc = m.Interchange( OhpiConst.RPC_SAHPI_WATCHDOG_TIMER_SET );
                if ( !rc ) {
                m.Close();
                return HpiConst.SA_ERR_HPI_NO_RESPONSE;
                }
                rv = m.DemarshalSaErrorT();
                if ( rv == HpiConst.SA_OK ) {
                // No output arguments
                }
                s.PutMarshal( m );

                return rv;
            }
Example #3
0
            public SaHpiWatchdogT DemarshalSaHpiWatchdogT()
            {
                SaHpiWatchdogT x = new SaHpiWatchdogT();

                x.Log = DemarshalSaHpiBoolT();
                x.Running = DemarshalSaHpiBoolT();
                x.TimerUse = DemarshalSaHpiWatchdogTimerUseT();
                x.TimerAction = DemarshalSaHpiWatchdogActionT();
                x.PretimerInterrupt = DemarshalSaHpiWatchdogPretimerInterruptT();
                x.PreTimeoutInterval = DemarshalSaHpiUint32T();
                x.TimerUseExpFlags = DemarshalSaHpiWatchdogExpFlagsT();
                x.InitialCount = DemarshalSaHpiUint32T();
                x.PresentCount = DemarshalSaHpiUint32T();

                return x;
            }
Example #4
0
 /**
  * Check function for HPI struct SaHpiWatchdogT
  */
 public static bool Check( SaHpiWatchdogT x )
 {
     if ( x == null ) {
     return false;
     }
     return true;
 }