BOOL ENC28J60_LWIP_Driver::Close( ENC28J60_LWIP_DRIVER_CONFIG* config, int index ) { NATIVE_PROFILE_HAL_DRIVERS_ETHERNET(); if(config == NULL) return FALSE; LwipUpTimeCompletion.Abort(); netif_set_link_down( &g_ENC28J60_NetIF ); netif_set_down( &g_ENC28J60_NetIF ); netif_remove( &g_ENC28J60_NetIF ); /* Disable the INTERRUPT pin */ CPU_GPIO_EnableInputPin2(config->INT_Pin, FALSE, /* Glitch filter enable */ NULL, /* ISR */ 0, /* minor number */ GPIO_INT_NONE, /* Interrupt edge */ RESISTOR_PULLUP); /* Resistor State */ InterruptTaskContinuation.Abort(); LwipNetworkStatus = FALSE; enc28j60_lwip_close( &g_ENC28J60_NetIF ); memset(&g_ENC28J60_NetIF, 0, sizeof(g_ENC28J60_NetIF)); return TRUE; }
void Events_SetBoolTimer( BOOL* TimerCompleteFlag, UINT32 MillisecondsFromNow ) { NATIVE_PROFILE_PAL_EVENTS(); // we assume only 1 can be active, abort previous just in case g_Events_BoolTimerCompletion.Abort(); if(TimerCompleteFlag) { g_Events_BoolTimerCompletion.InitializeForISR( local_Events_SetBoolTimer_Callback, TimerCompleteFlag ); g_Events_BoolTimerCompletion.EnqueueDelta( MillisecondsFromNow * 1000 ); } }
/*----------------------------------------------------------------------* rtp_thread_kill *----------------------------------------------------------------------*/ int rtp_thread_kill (RTP_HANDLE * newThread, RTP_ENTRY_POINT_FN entryPoint, const char * name, int stackSizeIndex, int priorityIndex, void * userData) { int * index = (int *) userData; if ((rtp_strcmp(name, "ip interpret") == 0) && IPTaskInitialized[*index]) { IPTaskInitialized[*index] = 0; IPTaskContinuation[*index].Abort(); } else if ((rtp_strcmp(name, "timer comp") == 0) && TimerTaskCompInitialized) { TimerTaskCompInitialized = 0; TimerTaskCompletion.Abort(); } else if ((rtp_strcmp(name, "timer cont") == 0) && TimerTaskContInitialized) { TimerTaskContInitialized = 0; TimerTaskContinuation.Abort(); } else if ((rtp_strcmp(name, "interrupt task") == 0) && InterruptTaskContInitialized[*index]) { InterruptTaskContInitialized[*index] = 0; InterruptTaskContinuation[*index].Abort(); } else if ((rtp_strcmp(name, "dhcp") == 0) && DHCPTaskInitialized) { DHCPTaskInitialized = 0; DHCPTaskContinuation.Abort(); } return (0); }
BOOL AT91_EMAC_LWIP_Driver::Close(void) { LwipUpTimeCompletion.Abort(); CPU_INTC_DeactivateInterrupt(AT91C_ID_EMAC); InterruptTaskContinuation.Abort(); LwipNetworkStatus = 0; netif_set_down( &g_AT91_EMAC_NetIF ); netif_remove( &g_AT91_EMAC_NetIF ); AT91_EMAC_LWIP_close( &g_AT91_EMAC_NetIF ); memset( &g_AT91_EMAC_NetIF, 0, sizeof g_AT91_EMAC_NetIF ); return TRUE; }
BOOL LPC24XX_EMAC_LWIP_Driver::Close( ) { LwipUpTimeCompletion.Abort(); /* Disable the interrupt */ CPU_INTC_DeactivateInterrupt(LPC24XX_VIC::c_IRQ_INDEX_EMAC); InterruptTaskContinuation.Abort(); LwipNetworkStatus = 0; netif_set_down( &g_LPC24XX_EMAC_NetIF ); netif_remove( &g_LPC24XX_EMAC_NetIF ); LPC24XX_EMAC_lwip_close( &g_LPC24XX_EMAC_NetIF ); memset( &g_LPC24XX_EMAC_NetIF, 0, sizeof g_LPC24XX_EMAC_NetIF); return TRUE; }
BOOL SH7264_SMSC_LWIP_Driver::Close(void) { LwipUpTimeCompletion.Abort(); //CPU_INTC_DeactivateInterrupt(SH7264C_ID_EDMAC); CPU_INTC_DeactivateInterrupt(81); InterruptTaskContinuation.Abort(); LwipNetworkStatus = 0; netif_set_down( &g_SH7264_SMSC_NetIF ); netif_remove( &g_SH7264_SMSC_NetIF ); SH7264_SMSC_lwip_close( &g_SH7264_SMSC_NetIF ); memset( &g_SH7264_SMSC_NetIF, 0, sizeof g_SH7264_SMSC_NetIF); return TRUE; }
BOOL Events_Uninitialize() { NATIVE_PROFILE_PAL_EVENTS(); g_Events_BoolTimerCompletion.Abort(); return TRUE; }
void DeInitContinuations() { LwipUpTimeCompletion.Abort(); InterruptTaskContinuation.Abort(); }