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

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

?? os_cpu_c.c

?? ucos-II在S3C44BO下的移植
?? C
字號:
/*
*********************************************************************************************************
*                                               uC/OS-II
*                                         The Real-Time Kernel
*
*                        (c) Copyright 1992-1998, Jean J. Labrosse, Plantation, FL
*                                          All Rights Reserved
*                        (c) Copyright ARM Limited 1999.  All rights reserved.
*
*                                          ARM Specific code
*
*
* File : OS_CPU_C.C
*********************************************************************************************************
*/

#define  OS_CPU_GLOBALS
#include "includes.h"

/*
*********************************************************************************************************
*                                        INITIALIZE A TASK'S STACK
*
* Description: This function is called by either OSTaskCreate() or OSTaskCreateExt() to initialize the
*              stack frame of the task being created.  This function is highly processor specific.
*
* Arguments  : task          is a pointer to the task code
*
*              pdata         is a pointer to a user supplied data area that will be passed to the task
*                            when the task first executes.
*
*              ptos          is a pointer to the top of stack.  It is assumed that 'ptos' points to
*                            a 'free' entry on the task stack.  If OS_STK_GROWTH is set to 1 then 
*                            'ptos' will contain the HIGHEST valid address of the stack.  Similarly, if
*                            OS_STK_GROWTH is set to 0, the 'ptos' will contains the LOWEST valid address
*                            of the stack.
*
*              opt           specifies options that can be used to alter the behavior of OSTaskStkInit().
*                            (see uCOS_II.H for OS_TASK_OPT_???).
*
* Returns    : Always returns the location of the new top-of-stack' once the processor registers have
*              been placed on the stack in the proper order.
*
* Note(s)    : Interrupts are enabled when your task starts executing. You can change this by setting the
*              PSW to 0x0002 instead.  In this case, interrupts would be disabled upon task startup.  The
*              application code would be responsible for enabling interrupts at the beginning of the task
*              code.  You will need to modify OSTaskIdle() and OSTaskStat() so that they enable 
*              interrupts.  Failure to do this will make your system crash!
*********************************************************************************************************
*/

void *OSTaskStkInit (void (*task)(void *pd), void *pdata, void *ptos, INT16U opt)
{
    unsigned int *stk;

    opt    = opt;                           /* 'opt' is not used, prevent warning                      */
    stk    = (unsigned int *)ptos;          /* Load stack pointer                                      */

    /* build a context for the new task */
    *--stk = (unsigned int) task;       /* pc */
    *--stk = (unsigned int) task;       /* lr */

    *--stk = 0;                         /* r12 */
    *--stk = 0;                         /* r11 */
    *--stk = 0;                         /* r10 */
    *--stk = 0;                         /* r9 */
    *--stk = 0;                         /* r8 */
    *--stk = 0;                         /* r7 */
    *--stk = 0;                         /* r6 */
    *--stk = 0;                         /* r5 */
    *--stk = 0;                         /* r4 */
    *--stk = 0;                         /* r3 */
    *--stk = 0;                         /* r2 */
    *--stk = 0;                         /* r1 */
    *--stk = (unsigned int) pdata;      /* r0 */
    *--stk = (SVC32MODE|0x0);			/* cpsr  IRQ, FIQ disable*/
    *--stk = (SVC32MODE|0x0);			/* spsr  IRQ, FIQ disable */


    return ((void *)stk);
}

/*$PAGE*/
#if OS_CPU_HOOKS_EN
/*
*********************************************************************************************************
*                                          TASK CREATION HOOK
*
* Description: This function is called when a task is created.
*
* Arguments  : ptcb   is a pointer to the task control block of the task being created.
*
* Note(s)    : 1) Interrupts are disabled during this call.
*********************************************************************************************************
*/
void OSTaskCreateHook (OS_TCB *ptcb)
{
    ptcb = ptcb;                       /* Prevent compiler warning                                     */
}


/*
*********************************************************************************************************
*                                           TASK DELETION HOOK
*
* Description: This function is called when a task is deleted.
*
* Arguments  : ptcb   is a pointer to the task control block of the task being deleted.
*
* Note(s)    : 1) Interrupts are disabled during this call.
*********************************************************************************************************
*/
void OSTaskDelHook (OS_TCB *ptcb)
{
    ptcb = ptcb;                       /* Prevent compiler warning                                     */
}

/*
*********************************************************************************************************
*                                           TASK SWITCH HOOK
*
* Description: This function is called when a task switch is performed.  This allows you to perform other
*              operations during a context switch.
*
* Arguments  : none
*
* Note(s)    : 1) Interrupts are disabled during this call.
*              2) It is assumed that the global pointer 'OSTCBHighRdy' points to the TCB of the task that
*                 will be 'switched in' (i.e. the highest priority task) and, 'OSTCBCur' points to the 
*                 task being switched out (i.e. the preempted task).
*********************************************************************************************************
*/
void OSTaskSwHook (void)
{
}

/*
*********************************************************************************************************
*                                           STATISTIC TASK HOOK
*
* Description: This function is called every second by uC/OS-II's statistics task.  This allows your 
*              application to add functionality to the statistics task.
*
* Arguments  : none
*********************************************************************************************************
*/
void OSTaskStatHook (void)
{
}

/*
*********************************************************************************************************
*                                               TICK HOOK
*
* Description: This function is called every tick.
*
* Arguments  : none
*
* Note(s)    : 1) Interrupts may or may not be ENABLED during this call.
*********************************************************************************************************
*/

void OSTimeTickHook (void)
{
}
#endif

#define BUILD_DATE "Date: " __DATE__ "\n"

/*
 * Initialize an ARM Target board
 */
void
 ARMTargetInit(void)
{
    /* ---- Tell the world who we are ---------------------------------- */
    uHALr_printf("uCOS-II Running on a") ;
    //Uart_Printf("uCOS-II Running on a") ;
#if defined(EBSA285)
    uHALr_printf("n EBSA-285 (21285 evaluation board)\n") ;
#elif defined(BRUTUS) 
    uHALr_printf(" Brutus (SA-1100 verification platform)\n") ;
#elif defined(INTEGRATOR) 
    uHALr_printf("n Integrator board\n") ;
#elif defined(PROSPECTOR) 
    uHALr_printf(" Prospector board\n") ;
#elif defined(SAMSUNG)
        uHALr_printf("\n DJT44B0X ");
        uHALr_printf(" board\n") ;

#else
    uHALr_printf("n unknown ARM board\n") ;
#endif
    uHALr_printf(uHAL_VERSION_STRING); 
    uHALr_printf("\n") ;
    uHALr_printf(BUILD_DATE);
    uHALr_printf("\n") ;

#ifdef DEBUG
    uHALr_printf("Initialising target\n");
#endif

    /* ---- disable the MMU        ------------------------------------- */
    uHALr_ResetMMU();

    /* ---- disable interrupts (IRQs) --------------------------------- */
    ARMDisableInt();

    /* ---- soft vectors ---------------------------------------------- */
#ifdef DEBUG
    uHALr_printf("Setting up soft vectors\n");
#endif
    /* Define pre & post-process routines for Interrupt */
    uHALir_DefineIRQ((void *)IrqStart, (void *)IrqFinish, (void *) 0);
    uHALr_InitInterrupts();

#ifdef DEBUG
    uHALr_printf("Timer init\n");
#endif
    uHALr_InitTimers();

#ifdef DEBUG
    uHALr_printf("targetInit() complete\n");
#endif
}                               /* targetInit */

/* start the ARM target running */
void
 ARMTargetStart(void)
{
#ifdef DEBUG
    uHALr_printf("Starting target\n") ;
#endif

    /* request the system timer */
    if (uHALr_RequestSystemTimer(
                                 (void *) OSTimeTick,
                                 (const unsigned char *)"uCOS-II") <= 0)
        uHALr_printf("Timer/IRQ busy\n");

    /* Start system timer & enable the interrupt. */
    uHALr_InstallSystemTimer();
}

extern void IRQContextSwap(void);   /* post DispatchIRQ processing (the _real_ one) */

/* just 'notice' that we need to change context */
int need_to_swap_context = 0 ;
void OSIntCtxSw(void) {
    need_to_swap_context = 1;
}

/* This is what uCOS does at the start of an IRQ */
void IrqStart(void)
{
    /* increment nesting counter */
    OSIntNesting++;
}

/* This is what uCOS does at the end of an IRQ */
void *IrqFinish(void)
{
    OSIntExit() ;
    if (need_to_swap_context) {
//        need_to_swap_context = 0 ;
        return ((void *)IRQContextSwap) ;
    } else {
        return (void *)0;
    }
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
久久99久久久久久久久久久| 在线一区二区三区| 日韩精彩视频在线观看| 色综合激情久久| 自拍偷拍国产精品| 在线国产电影不卡| 偷拍一区二区三区| 久久这里只有精品视频网| 国内精品久久久久影院薰衣草 | 18欧美亚洲精品| 色素色在线综合| 午夜a成v人精品| 日韩欧美高清dvd碟片| 国产乱色国产精品免费视频| 欧美—级在线免费片| 91精品办公室少妇高潮对白| 日韩主播视频在线| 久久亚洲二区三区| 91国偷自产一区二区三区观看| 亚洲成a人片综合在线| 精品日韩在线观看| 91网站最新地址| 美女视频黄 久久| 国产精品久久久久久亚洲伦| 欧美在线小视频| 久久成人综合网| 亚洲精品成a人| 精品电影一区二区三区| 99精品欧美一区| 久久99蜜桃精品| 亚洲精品日产精品乱码不卡| 精品国产91洋老外米糕| 色综合天天性综合| 黑人巨大精品欧美一区| 亚洲人成人一区二区在线观看| 91精品在线麻豆| 成人性生交大片免费看在线播放| 亚洲日本在线视频观看| 成人国产电影网| 一区二区三区欧美| 91精彩视频在线观看| 久久久久久电影| 精品一区二区三区久久| 色琪琪一区二区三区亚洲区| 国产色一区二区| 成人听书哪个软件好| 色爱区综合激月婷婷| 国产亚洲欧美一级| 国产精品视频麻豆| 国产酒店精品激情| 亚洲1区2区3区4区| 亚洲黄色小视频| 国产精品热久久久久夜色精品三区| 91麻豆精品国产自产在线观看一区 | 欧美变态tickle挠乳网站| 91久久精品一区二区| 国产精品夜夜嗨| 老司机免费视频一区二区| 怡红院av一区二区三区| 中文字幕一区二区三区四区不卡| 精品国产免费人成电影在线观看四季 | 亚洲精品在线网站| 日韩欧美一区在线| 欧美精品 国产精品| 在线视频国内自拍亚洲视频| av高清不卡在线| 成人午夜激情视频| 国产精品99久久久久久久vr | 在线不卡中文字幕| 欧美日本在线播放| 欧美性感一区二区三区| 色av成人天堂桃色av| 99精品国产99久久久久久白柏 | 成人欧美一区二区三区黑人麻豆| 精品国产精品一区二区夜夜嗨| 日韩一区二区免费电影| 56国语精品自产拍在线观看| 欧美日韩一区不卡| 欧美三级三级三级爽爽爽| 欧美视频在线观看一区二区| 欧美日韩黄色一区二区| 欧美日韩国产高清一区| 777a∨成人精品桃花网| 3d动漫精品啪啪一区二区竹菊 | 国产盗摄精品一区二区三区在线| 亚洲一区二区综合| 久久久99精品久久| 91麻豆精品国产91久久久使用方法 | 国产校园另类小说区| 久久成人免费网站| 亚洲国产精品久久一线不卡| 亚洲在线视频一区| www.亚洲精品| 97久久久精品综合88久久| 91网站视频在线观看| 欧美偷拍一区二区| 欧美高清www午色夜在线视频| 69久久夜色精品国产69蝌蚪网 | 一本久道中文字幕精品亚洲嫩| 91福利在线看| 日韩一级视频免费观看在线| 久久伊99综合婷婷久久伊| 最新日韩在线视频| 亚洲一级片在线观看| 蜜桃传媒麻豆第一区在线观看| 看片网站欧美日韩| 日韩极品在线观看| 亚洲成av人片| 麻豆一区二区三| 国产乱人伦偷精品视频免下载| 99麻豆久久久国产精品免费| 97aⅴ精品视频一二三区| 一本久道久久综合中文字幕| 欧美三级中文字| 日韩色在线观看| 日韩美一区二区三区| 久久久亚洲高清| **欧美大码日韩| 亚洲一区二三区| 黄色资源网久久资源365| 国产乱色国产精品免费视频| 色视频欧美一区二区三区| 欧美日韩一区二区三区四区 | 久久久噜噜噜久噜久久综合| 中文字幕精品三区| 亚洲一区二区美女| 免费成人在线网站| 国产69精品一区二区亚洲孕妇| 欧美日韩色一区| 国产网红主播福利一区二区| 亚洲黄色尤物视频| 久久国产尿小便嘘嘘尿| 久久99精品国产麻豆婷婷| 欧美午夜宅男影院| 久久精品亚洲麻豆av一区二区 | 国产一区二区三区高清播放| 国产一区999| av不卡一区二区三区| 亚洲国产精品成人久久综合一区| 亚洲色图另类专区| 蜜桃视频第一区免费观看| 国产成人亚洲综合a∨婷婷图片| 91视频免费看| 久久精品人人做人人综合| 成人免费在线播放视频| 五月天视频一区| 国产一二精品视频| 这里只有精品99re| 成人av小说网| 波多野结衣中文一区| 欧美日韩一区二区三区在线| 国产偷国产偷精品高清尤物| 亚洲第一电影网| 国产伦精一区二区三区| 在线亚洲一区观看| 亚洲国产精品av| 蜜臀91精品一区二区三区| 国产一区二区日韩精品| 欧美日本精品一区二区三区| 最新国产精品久久精品| 另类综合日韩欧美亚洲| 色婷婷久久一区二区三区麻豆| 精品久久久久99| 久久精品国产一区二区三 | 久久精品99国产精品日本| 99精品欧美一区二区蜜桃免费| 亚洲精品在线观看网站| 亚洲成人动漫在线免费观看| 欧美另类videos死尸| 亚洲嫩草精品久久| 成人精品鲁一区一区二区| 精品乱人伦小说| 欧美a级理论片| 欧美女孩性生活视频| 曰韩精品一区二区| 色国产精品一区在线观看| 国产精品区一区二区三| 国产一区二区剧情av在线| 国产调教视频一区| 国产精品69毛片高清亚洲| 欧美成人a∨高清免费观看| 日韩国产精品久久久久久亚洲| 国产mv日韩mv欧美| 自拍偷拍国产亚洲| av资源网一区| 自拍av一区二区三区| 成人av电影在线| 亚洲影视在线观看| 欧美日本国产视频| 青娱乐精品在线视频| 7878成人国产在线观看| 国产成人综合精品三级| 国产日韩欧美亚洲| 99在线热播精品免费| 亚洲免费色视频| 欧美精品三级日韩久久| 日韩精品视频网站| 日韩精品最新网址| 国产福利一区二区三区视频在线| 久久综合九色综合97婷婷|