亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? tcc.c

?? nucleus plus ARM9 source code
?? C
?? 第 1 頁 / 共 5 頁
字號:
#endif

#ifdef  NU_ENABLE_HISTORY

    /* Make an entry that corresponds to this function in the system history
       log.  */
    HIC_Make_History_Entry(NU_TERMINATE_TASK_ID, (UNSIGNED) task,
                                        (UNSIGNED) 0, (UNSIGNED) 0);

#endif

    /* Determine if the calling task is the current task.  */
    if (task == (TC_TCB *) TCD_Current_Thread)
    {

        /* Protect system  data structures.  */
        TCT_Protect(&TCD_System_Protect);

#ifdef INCLUDE_PROVIEW
    _RTProf_DumpTask(task,RT_PROF_TERMINATE_TASK);
#endif /*INCLUDE_PROVIEW*/

        /* Suspend the calling task with the NU_TERMINATED status.  */
        TCC_Suspend_Task(task_ptr, NU_TERMINATED, NU_NULL, NU_NULL,
                                                            NU_SUSPEND);

        /* No need to un-protect, since control never comes back to this
           point and the protection is cleared in TCT_Control_To_System.  */
    }
    else
    {

        /* Protect scheduling structures.  */
        TCT_Protect(&TCD_System_Protect);

#ifdef INCLUDE_PROVIEW
    _RTProf_DumpTask(task,RT_PROF_TERMINATE_TASK);
#endif /*INCLUDE_PROVIEW*/

        /* Keep trying to terminate the specified task until its status
           indicates that it is terminated or finished.  */
        while ((task -> tc_status != NU_FINISHED) &&
                  task -> tc_status != NU_TERMINATED)
        {

            /* Is the task in a ready state?  */
            if (task -> tc_status == NU_READY)
            {

                /* Terminate the specified task.  */
                TCC_Suspend_Task(task_ptr, NU_TERMINATED, NU_NULL,
                                                        NU_NULL,NU_SUSPEND);

                /* Clear system protection.  */
                TCT_Unprotect();
            }
            else
            {

                /* Task is suspended currently.  Pickup the suspension
                   protection.  */
                suspend_protect =  task -> tc_suspend_protect;

                /* Save the current status.  */
                status =           task -> tc_status;

                /* Release protection on system structures.  */
                TCT_Unprotect();

                /* Determine if there was a suspension protection.  If so
                   protect it first before the scheduling list protection.
                   This avoids a deadlock situation.  */
                if (suspend_protect)

                    /* Protect the terminated task's last suspension
                       structures.  */
                    TCT_Protect(suspend_protect);

                /* Protect the system structures again.  */
                TCT_Protect(&TCD_System_Protect);

                /* Now determine if the same suspension is in force.  */
                if ((task -> tc_status == status) &&
                    (task -> tc_suspend_protect == suspend_protect))
                {

                    /* Yes, same suspension is in force.  */

                    /* Call cleanup routine, if there is one.  */
                    if (task -> tc_cleanup)

                        /* Call cleanup function.  */
                        (*(task -> tc_cleanup)) (task -> tc_cleanup_info);

                    /* Status the task as terminated.  */
                    task -> tc_status =  NU_TERMINATED;

                    /* Determine if there is a timer active.  */
                    if (task -> tc_timer_active)
                    {

                        /* Call the stop timer function.  */
                        TMC_Stop_Task_Timer(&(task -> tc_timer_control));

                        /* Clear the timer active flag.  */
                        task -> tc_timer_active =  NU_FALSE;
                    }
                }

                /* Cleanup the protection.  */
                if (suspend_protect)
                {

                    /* Release specific protection.  */
                    TCT_Unprotect_Specific(suspend_protect);

                    /* Clear the suspend protect field.  */
                    task -> tc_suspend_protect =  NU_NULL;
                }

                /* Release current protection.  */
                TCT_Unprotect();
            }

            /* Protect the scheduling list again.  */
            TCT_Protect(&TCD_System_Protect);
        }

        /* Release the protection.  */
        TCT_Unprotect();
    }

    /* Return to user mode */
    NU_USER_MODE();

    /* Return successful completion.  */
    return(NU_SUCCESS);
}


/*************************************************************************/
/*                                                                       */
/* FUNCTION                                                              */
/*                                                                       */
/*      TCC_Resume_Task                                                  */
/*                                                                       */
/* DESCRIPTION                                                           */
/*                                                                       */
/*      This function resumes a previously suspended task.  The task     */
/*      task must currently be suspended for the same reason indicated   */
/*      by this request.  If the task resumed is higher priority than    */
/*      the calling task and the current task is preemptable, this       */
/*      function returns a value of NU_TRUE.  Otherwise, if no           */
/*      preemption is required, a NU_FALSE is returned.  This routine    */
/*      must be called from Supervisor mode in a Supervisor/User mode    */
/*      switching kernel.                                                */
/*                                                                       */
/* CALLED BY                                                             */
/*                                                                       */
/*      Other Components                                                 */
/*      TCC_Resume_Service                  Resume service function      */
/*                                                                       */
/* CALLS                                                                 */
/*                                                                       */
/*      [TCT_Check_Stack]                   Stack checking function      */
/*      TCT_Set_Current_Protect             Set current protection field */
/*      TCT_Set_Execute_Task                Set TCD_Execute_Task pointer */
/*      TMC_Stop_Task_Timer                 Stop task timer              */
/*                                                                       */
/* INPUTS                                                                */
/*                                                                       */
/*      task_ptr                            Task control block pointer   */
/*      suspend_type                        Type of suspension to lift   */
/*                                                                       */
/* OUTPUTS                                                               */
/*                                                                       */
/*      NU_TRUE                             A higher priority task is    */
/*                                            ready to execute           */
/*      NU_FALSE                            No change in the task to     */
/*                                            execute                    */
/*                                                                       */
/* HISTORY                                                               */
/*                                                                       */
/*        DATE                    REMARKS                                */
/*                                                                       */
/*      03-01-1993      Created initial version 1.0                      */
/*      04-19-1993      Verified version 1.0                             */
/*      09-19-1993      Corrected an initialization                      */
/*                      problem of de-referencing a                      */
/*                      NULL pointer, resulting in                       */
/*                      version 1.0d                                     */
/*      09-19-1993      Verified version 1.0d                            */
/*      03-01-1994      Modified function interface,                     */
/*                      added register optimizations,                    */
/*                      modified protection logic to                     */
/*                      assume that system protection                    */
/*                      is already in force, resulting                   */
/*                      in version 1.1                                   */
/*                                                                       */
/*      03-18-1994      Verified version 1.1                             */
/*      10-29-1997      Changed so that tc_cleanup,                      */
/*                      tc_cleanup_info, and                             */
/*                      tc_suspend_protect are cleared                   */
/*                      only if a signal is not active                   */
/*                      (SPR115)                                         */
/*      03-20-1998      Corrected SPR455.                                */
/*                                                                       */
/*************************************************************************/
STATUS  TCC_Resume_Task(NU_TASK *task_ptr, OPTION suspend_type)
{

R1 TC_TCB      *task;                       /* Task control block ptr    */
R2 TC_TCB      *head;                       /* Pointer to priority list  */
STATUS          status =  NU_FALSE;         /* Status variable           */

    /* Move task pointer into internal pointer.  */
    task =  (TC_TCB *) task_ptr;


#ifdef  NU_ENABLE_STACK_CHECK

    /* Call stack checking function to check for an overflow condition.  */
    TCT_Check_Stack();

#endif


    /* Check to see if the task is suspended for the reason that this
       resume is attempting to clear.  */
    if (task -> tc_status == suspend_type)
    {

        /* Yes, this resume call is valid.  */

        /* If signals are not active, clear any suspend or cleanup
           information (SPR115).  */
        if (!task -> tc_signal_active)
        {
            task -> tc_suspend_protect =        NU_NULL;
            task -> tc_cleanup =                NU_NULL;
            task -> tc_cleanup_info =           NU_NULL;
        }

        /* Determine if there is a timer active and the task is not being
           resumed to handle a signal.  */
        if ((task -> tc_timer_active) && (!task -> tc_signal_active))
        {

            /* Call the stop timer function.  */
            TMC_Stop_Task_Timer(&(task -> tc_timer_control));

            /* Clear the timer active flag.  */
            task -> tc_timer_active =  NU_FALSE;
        }

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
午夜精品久久久久久久99水蜜桃| 久久91精品国产91久久小草| 日韩高清电影一区| 国产成人免费av在线| 欧美性三三影院| 欧美高清在线视频| 七七婷婷婷婷精品国产| 色综合婷婷久久| 国产午夜精品福利| 日本欧美加勒比视频| 色呦呦国产精品| 国产欧美va欧美不卡在线| 天天色天天操综合| 在线亚洲精品福利网址导航| 国产亚洲视频系列| 另类小说综合欧美亚洲| 欧美视频中文字幕| 亚洲精品一二三四区| 成人中文字幕在线| 欧美精品一区二区三区蜜桃视频| 午夜久久福利影院| 色综合 综合色| 中文字幕综合网| 成人高清视频免费观看| 国产亚洲短视频| 国产乱码精品一区二区三| 欧美一区二区视频网站| 五月激情丁香一区二区三区| 91国产丝袜在线播放| 亚洲欧美日韩国产另类专区| 不卡视频在线观看| 中文字幕在线不卡一区 | 精品欧美久久久| 日韩成人一级片| 欧美一区二区三区视频| 免费三级欧美电影| 欧美sm极限捆绑bd| 国内精品久久久久影院薰衣草| 欧美成人精精品一区二区频| 蜜臀99久久精品久久久久久软件| 欧美精品日韩一本| 日本午夜一区二区| 精品嫩草影院久久| 国产原创一区二区| 欧美国产精品中文字幕| 99视频在线精品| 亚洲最新视频在线观看| 91精品免费观看| 国产在线播放一区| 亚洲欧美精品午睡沙发| 在线欧美日韩精品| 青娱乐精品视频| 亚洲精品一区二区三区福利 | 成人国产精品免费观看动漫| 成人欧美一区二区三区| 91福利视频网站| 日韩精品成人一区二区三区| 欧美精品一区视频| 99精品桃花视频在线观看| 亚洲与欧洲av电影| 欧美一级欧美一级在线播放| 国产一区二区剧情av在线| 国产精品久久久久久久久免费樱桃 | 成人黄色大片在线观看| 怡红院av一区二区三区| 欧美一级欧美一级在线播放| 国产成人99久久亚洲综合精品| 亚洲欧美一区二区不卡| 欧美一级欧美三级| 99re66热这里只有精品3直播| 国产最新精品免费| 亚洲免费观看高清完整版在线观看 | 91在线视频免费观看| 视频一区视频二区中文| 国产无遮挡一区二区三区毛片日本| 色狠狠综合天天综合综合| 理论片日本一区| 亚洲欧美中日韩| 欧美电影免费观看高清完整版在线| av网站免费线看精品| 美国毛片一区二区| 亚洲黄色免费电影| 久久久久久久综合日本| 在线观看一区二区视频| 精品一区二区免费在线观看| 玉足女爽爽91| 国产精品三级av在线播放| 日韩女优毛片在线| 欧美日韩一级片网站| av午夜精品一区二区三区| 久久99精品久久久久婷婷| 亚洲国产精品欧美一二99| 国产精品久久久久影院色老大| 欧美一区永久视频免费观看| 日本二三区不卡| 成人黄色网址在线观看| 狠狠色综合色综合网络| 日韩精品色哟哟| 亚洲成人动漫精品| 一区二区三区在线视频免费观看| 欧美激情一区在线观看| 久久日韩粉嫩一区二区三区| 欧美一区二区三区视频免费播放| 欧美日韩一区视频| 在线欧美日韩精品| 色一情一乱一乱一91av| 91视频xxxx| 97久久精品人人爽人人爽蜜臀| 国产高清精品网站| 国产福利精品导航| 国产高清精品网站| 成人一级黄色片| 成人sese在线| 99国产精品国产精品久久| av爱爱亚洲一区| 91美女视频网站| 欧洲精品中文字幕| 欧美偷拍一区二区| 8x福利精品第一导航| 欧美电影在哪看比较好| 欧美久久久久免费| 欧美一级黄色大片| 精品卡一卡二卡三卡四在线| 欧美精品一区二区三区在线| 久久先锋影音av鲁色资源| 国产亚洲婷婷免费| 综合婷婷亚洲小说| 一区二区三区影院| 婷婷一区二区三区| 久久爱www久久做| 国产精品综合二区| 一本色道久久综合亚洲aⅴ蜜桃| 91麻豆swag| 91麻豆精品久久久久蜜臀| 日韩欧美国产午夜精品| 久久精品无码一区二区三区| 亚洲国产精品传媒在线观看| 亚洲免费观看高清| 午夜一区二区三区视频| 捆绑调教美女网站视频一区| 国产经典欧美精品| 91丨国产丨九色丨pron| 欧美伦理影视网| 久久天天做天天爱综合色| 亚洲人成伊人成综合网小说| 亚洲国产精品精华液网站| 久国产精品韩国三级视频| zzijzzij亚洲日本少妇熟睡| 欧美日本一区二区| 国产三级精品三级在线专区| 一区二区三区不卡在线观看| 欧美aⅴ一区二区三区视频| 国产精品一品二品| 欧美色爱综合网| 久久精品夜色噜噜亚洲aⅴ| 亚洲国产日韩一级| 国产一区二区三区不卡在线观看 | 亚洲欧美在线观看| 日韩和欧美的一区| 成人丝袜视频网| 337p亚洲精品色噜噜| 国产精品久久久久久久久免费桃花| 亚洲第一主播视频| 成人黄色大片在线观看| 91精品久久久久久久91蜜桃| 亚洲欧洲国产专区| 韩国三级中文字幕hd久久精品| 色综合天天综合| 久久久久久久综合色一本| 亚洲成人在线网站| 99久久精品国产毛片| 久久久久亚洲蜜桃| 天堂一区二区在线| 色综合色综合色综合色综合色综合 | 国产一区二区在线看| 欧美日韩一级片在线观看| 1区2区3区欧美| 国产一二精品视频| 91久久久免费一区二区| 日韩一级黄色大片| 亚洲一区二三区| 99久久99久久综合| 日本一区二区在线不卡| 久久精品免费观看| 91精品国产91久久久久久一区二区 | 日本午夜一本久久久综合| 色婷婷久久99综合精品jk白丝 | 精品区一区二区| 爽爽淫人综合网网站| 91黄色激情网站| 亚洲欧美日本韩国| 99久久免费视频.com| 国产欧美视频一区二区| 国产精品123区| 久久综合精品国产一区二区三区| 肉色丝袜一区二区| 欧美丰满嫩嫩电影| 日韩中文字幕亚洲一区二区va在线| 欧美亚洲一区二区在线观看| 亚洲最色的网站|