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

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

?? mutex.hxx

?? eCos/RedBoot for勤研ARM AnywhereII(4510) 含全部源代碼
?? HXX
字號:
#ifndef CYGONCE_KERNEL_MUTEX_HXX
#define CYGONCE_KERNEL_MUTEX_HXX

//==========================================================================
//
//      mutex.hxx
//
//      Mutex class declarations
//
//==========================================================================
//####ECOSGPLCOPYRIGHTBEGIN####
// -------------------------------------------
// This file is part of eCos, the Embedded Configurable Operating System.
// Copyright (C) 1998, 1999, 2000, 2001, 2002 Red Hat, Inc.
//
// eCos is free software; you can redistribute it and/or modify it under
// the terms of the GNU General Public License as published by the Free
// Software Foundation; either version 2 or (at your option) any later version.
//
// eCos is distributed in the hope that it will be useful, but WITHOUT ANY
// WARRANTY; without even the implied warranty of MERCHANTABILITY or
// FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
// for more details.
//
// You should have received a copy of the GNU General Public License along
// with eCos; if not, write to the Free Software Foundation, Inc.,
// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA.
//
// As a special exception, if other files instantiate templates or use macros
// or inline functions from this file, or you compile this file and link it
// with other works to produce a work based on this file, this file does not
// by itself cause the resulting work to be covered by the GNU General Public
// License. However the source code for this file must still be made available
// in accordance with section (3) of the GNU General Public License.
//
// This exception does not invalidate any other reasons why a work based on
// this file might be covered by the GNU General Public License.
//
// Alternative licenses for eCos may be arranged by contacting Red Hat, Inc.
// at http://sources.redhat.com/ecos/ecos-license/
// -------------------------------------------
//####ECOSGPLCOPYRIGHTEND####
//==========================================================================
//#####DESCRIPTIONBEGIN####
//
// Author(s):   nickg
// Contributors:        nickg
// Date:        1997-09-09
// Purpose:     Define Mutex class interfaces
// Description: The classes defined here provide the APIs for mutexes
//              and condition variables.
// Usage:       #include <cyg/kernel/mutex.hxx>
//              
//
//####DESCRIPTIONEND####
//
//==========================================================================

#include <cyg/kernel/ktypes.h>
#include <cyg/infra/cyg_ass.h>         // assertion macros

#include <cyg/kernel/thread.hxx>

// -------------------------------------------------------------------------
// Mutex.

class Cyg_Mutex
{
    friend class Cyg_Condition_Variable;
    
    cyg_atomic          locked;         // true if locked. This may seem
                                        // redundant due to "owner" below,
                                        // but is intentionally present for
                                        // future SMP support.

    Cyg_Thread          *owner;         // Current locking thread

    Cyg_ThreadQueue     queue;          // Queue of waiting threads

#ifdef CYGSEM_KERNEL_SYNCH_MUTEX_PRIORITY_INVERSION_PROTOCOL_DYNAMIC

public:    
    enum cyg_protcol
    {
        NONE = 0,                       // no inversion protocol
        INHERIT,                        // priority inheritance protocol
        CEILING                         // priority ceiling protocol
    };

private:    
    cyg_protcol protocol;               // this mutex's protocol
    
#endif    
    
#ifdef CYGSEM_KERNEL_SYNCH_MUTEX_PRIORITY_INVERSION_PROTOCOL_CEILING

private:    
    cyg_priority        ceiling;        // mutex priority ceiling
    
#endif
    
public:

    CYGDBG_DEFINE_CHECK_THIS
    
    Cyg_Mutex();                        // Create in unlocked state

#ifdef CYGSEM_KERNEL_SYNCH_MUTEX_PRIORITY_INVERSION_PROTOCOL_DYNAMIC
    
    Cyg_Mutex( cyg_protcol protocol );  // Create with defined protocol

#endif
    
    ~Cyg_Mutex();                       // Destructor
        
    cyg_bool    lock();                 // lock and/or wait

    cyg_bool    trylock();              // try to lock and return success

    void        unlock();               // unlock

    void        release();              // release all waiting threads

    // Get the current owning thread
    inline Cyg_Thread *get_owner() { return owner; }
    
#ifdef CYGSEM_KERNEL_SYNCH_MUTEX_PRIORITY_INVERSION_PROTOCOL_CEILING

    // set ceiling priority for priority ceiling protocol
    void        set_ceiling( cyg_priority priority );

    cyg_priority get_ceiling(void) { return ceiling; };
    
#endif

#ifdef CYGSEM_KERNEL_SYNCH_MUTEX_PRIORITY_INVERSION_PROTOCOL_DYNAMIC

    // set inversion protocol
    void        set_protocol( cyg_protcol new_protocol );
#endif
    
};

// -------------------------------------------------------------------------
// Condition variable.

class Cyg_Condition_Variable
{
    Cyg_Mutex           *mutex;         // Associated mutex

    Cyg_ThreadQueue     queue;          // Queue of waiting threads

    // Private internal implementation function for wait operations
    cyg_bool wait_inner( Cyg_Mutex *mutex );

#ifdef CYGMFN_KERNEL_SYNCH_CONDVAR_TIMED_WAIT

    // Private internal implementation function for timed wait operations
    cyg_bool wait_inner( Cyg_Mutex *mutex, cyg_tick_count timeout );

#endif
    
public:

    CYGDBG_DEFINE_CHECK_THIS

    Cyg_Condition_Variable();           // simple constructor
    
    Cyg_Condition_Variable(
        Cyg_Mutex &mutex                // linked mutex
        );

    ~Cyg_Condition_Variable();          // Destructor
        

    void     signal();                  // Set cond true, wake one thread

    void     broadcast();               // Set cond true, wake all threads

    // Wait for condition to be true
    inline cyg_bool wait() { return wait_inner( mutex ); }
    
#ifdef CYGMFN_KERNEL_SYNCH_CONDVAR_TIMED_WAIT

    // Wait until a signal or timeout expiry
    inline cyg_bool wait( cyg_tick_count timeout )
    { return wait_inner( mutex, timeout ); }

#endif

#ifdef CYGMFN_KERNEL_SYNCH_CONDVAR_WAIT_MUTEX

    // Wait for condition to be true using the supplied mutex    
    inline cyg_bool wait( Cyg_Mutex &mx ) { return wait_inner( &mx ); }
    

#ifdef CYGMFN_KERNEL_SYNCH_CONDVAR_TIMED_WAIT

    // Wait until a signal or timeout expiry, using the supplied mutex
    inline cyg_bool wait( Cyg_Mutex &mx, cyg_tick_count timeout )
    { return wait_inner( &mx, timeout ); }        
    
#endif    
#endif    

    // Return a pointer to this variables thread queue. Used mainly
    // for testing whether a thread is on the queue for a particular
    // cv.
    inline Cyg_ThreadQueue *get_queue() { return &queue; };
    
};


// -------------------------------------------------------------------------

#endif // ifndef CYGONCE_KERNEL_MUTEX_HXX
// EOF mutex.hxx

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲精品在线免费播放| 日日摸夜夜添夜夜添亚洲女人| 日韩一级大片在线| 91色.com| 国产99精品国产| 黄色精品一二区| 日韩av网站在线观看| 亚洲综合色在线| 亚洲视频在线一区| 国产精品视频一区二区三区不卡| 精品久久五月天| 日韩视频在线你懂得| 欧美日韩一区二区在线观看视频| 91免费看视频| 一本色道亚洲精品aⅴ| 欧美性生活一区| 成人福利视频在线| 青青草一区二区三区| 亚洲一区二区三区激情| 亚洲乱码精品一二三四区日韩在线| 久久精品在线免费观看| 精品99999| 欧美成人aa大片| 日韩小视频在线观看专区| 91麻豆精品国产| 6080yy午夜一二三区久久| 欧美性xxxxxxxx| 欧美日韩国产片| 911精品国产一区二区在线| 亚洲免费伊人电影| 亚洲欧美偷拍卡通变态| 精品国产一区二区三区久久影院| 欧美日韩精品一二三区| 另类人妖一区二区av| 久久成人精品无人区| 精品一区二区三区在线播放| 久久99久久久久| 国产成人综合精品三级| 成人激情电影免费在线观看| 99riav久久精品riav| 色综合中文综合网| 欧美国产欧美亚州国产日韩mv天天看完整| 日本一区二区三区免费乱视频 | 亚洲视频在线一区| 一区二区成人在线视频| 麻豆久久久久久久| 国产精品综合av一区二区国产馆| 精品在线播放免费| 色综合久久中文综合久久97| 欧美午夜理伦三级在线观看| 日韩精品专区在线影院重磅| 日本一区二区高清| 亚洲精品免费播放| 狠狠色丁香久久婷婷综| 成人一区在线看| 中文字幕亚洲一区二区av在线| 美美哒免费高清在线观看视频一区二区| 欧美在线视频全部完| 中文字幕中文字幕在线一区| 亚洲国产精品麻豆| 韩日欧美一区二区三区| 日韩免费视频一区二区| 中文在线免费一区三区高中清不卡| 久久综合精品国产一区二区三区| 国产精品一区二区久激情瑜伽 | 久久久www免费人成精品| 精品欧美黑人一区二区三区| 国产蜜臀97一区二区三区| 天天色天天操综合| 91丨国产丨九色丨pron| 欧美mv日韩mv国产网站app| 一卡二卡三卡日韩欧美| 国产精品一级黄| 欧美老肥妇做.爰bbww| 中文字幕中文字幕在线一区| 最新久久zyz资源站| 亚洲日本电影在线| 久久er99精品| 激情综合色丁香一区二区| 成人av在线网站| 欧美日韩一卡二卡| 久久综合九色综合97婷婷女人| 亚洲美女视频一区| 国产精品欧美久久久久无广告| 亚洲第一精品在线| 日本亚洲最大的色成网站www| 久久精品国产99国产| 亚洲成人tv网| 免费成人美女在线观看| www.综合网.com| 欧美人妇做爰xxxⅹ性高电影 | 99精品一区二区三区| 日韩精品一区在线| 午夜影视日本亚洲欧洲精品| 成人免费视频网站在线观看| 51午夜精品国产| 亚洲欧美日韩一区二区三区在线观看| 亚洲一区二区综合| 99久久er热在这里只有精品15| 精品成人一区二区三区| 亚洲午夜久久久久久久久电影院| 成人午夜看片网址| 精品电影一区二区| 色综合久久久久综合体桃花网| 亚洲午夜久久久久久久久电影网| 国产乱人伦偷精品视频不卡 | 精品一区二区三区不卡| 欧美性videosxxxxx| 欧美极品少妇xxxxⅹ高跟鞋 | 综合中文字幕亚洲| 国产主播一区二区| 日韩精品专区在线| 日韩精品一二三区| 99久久er热在这里只有精品15| 欧美日韩的一区二区| 欧美在线观看视频一区二区 | 成人一区二区三区中文字幕| 久久精品日韩一区二区三区| 国产在线视频一区二区| 一区二区三区中文在线观看| 2020国产精品| 日韩精品专区在线| 色综合av在线| 亚洲人成亚洲人成在线观看图片| 成人高清视频在线观看| 欧美激情在线看| 成人av在线看| 亚洲女子a中天字幕| 色悠久久久久综合欧美99| 国产精品传媒在线| 成人avav在线| 亚洲三级在线播放| 欧洲一区二区三区在线| 色综合久久综合中文综合网| 中文字幕在线观看不卡| 亚洲综合久久av| 欧美丝袜第三区| 天天操天天色综合| 日韩三级免费观看| 国产一区二区精品在线观看| 国产欧美日韩在线观看| 欧美mv日韩mv亚洲| 中文字幕一区二区三区四区不卡| 国产三级欧美三级| xf在线a精品一区二区视频网站| 在线一区二区视频| 在线观看91av| 欧美一区永久视频免费观看| 综合电影一区二区三区| 精品国产乱码久久久久久久久| 成人av网站在线| 99久久伊人久久99| 成人av在线资源网站| av一区二区三区在线| 色婷婷久久久久swag精品| 久久精品国产秦先生| 国产精品一区二区果冻传媒| 91社区在线播放| 欧美三级电影在线看| 日韩免费福利电影在线观看| 91精品久久久久久久久99蜜臂| 欧美乱妇15p| 亚洲精品一区二区在线观看| 久久精品免视看| 国产精品天干天干在观线| 久久电影网站中文字幕 | 91精品国产综合久久久久| 日韩美一区二区三区| 久久久久久久久久久电影| 亚洲精品国产一区二区精华液| 一区二区三区小说| 午夜精品一区二区三区三上悠亚| 热久久久久久久| 91丝袜美腿高跟国产极品老师| 这里是久久伊人| 亚洲乱码中文字幕| 91亚洲国产成人精品一区二三| 在线观看日韩国产| 国产精品高潮呻吟| 北岛玲一区二区三区四区| xf在线a精品一区二区视频网站| 麻豆精品一二三| 久久久精品一品道一区| 石原莉奈一区二区三区在线观看| 欧美日韩视频在线第一区 | 精品一区二区久久久| 中文在线一区二区| 91精品久久久久久蜜臀| 国产999精品久久| 亚洲午夜在线视频| 久久久久久久久久美女| 欧美性生活影院| 99精品国产99久久久久久白柏| 亚洲 欧美综合在线网络| 自拍av一区二区三区| 久久久久久97三级| 欧美不卡视频一区| 欧美日韩精品高清| 欧美日韩视频在线第一区| 91在线视频在线|