syncmutex.cpp

来自「自已写的一个嵌入式实时多任务抢占式操作系统。花了几个礼拜」· C++ 代码 · 共 77 行

CPP
77
字号
/*	Implementation module : syncmutex.c

	Copyright 1999, Diab Data, Inc.

	Description :
	The mutex functions are currently used by the DIAB malloc/free

	History :
	When	Who	What
	990702	jb	initial
	990908	kc	split into synclib.c
	991122	fb	split into syncatomic.c
*/

/* never profile nor run-time-check this code */
#pragma option -Xprof-all=0
#pragma option -Xrtc=0
#pragma option -Xstack-probe=0

/**************	Imported modules ********************************/

#include "synclib.h"


/**************	Local data, types, fns and macros ***************/

/**************	Implementation of exported functions ************/

/*
 * _lib_alloc_mutex
 * Allocate and initialize mutex data structure.
 */

extern _lib_mutex _lib_alloc_mutex(void)
{
}


/*
 * _lib_free_mutex
 * Release mutex data structure.
 */

extern void _lib_free_mutex(_lib_mutex mutexp)
{
}


/*
 * _lib_lock_mutex
 * Lock mutex.
 */

extern void _lib_lock_mutex(_lib_mutex mutexp)
{
}


/*
 * _lib_trylock_mutex
 * Try to lock mutex.
 */

extern int _lib_trylock_mutex(_lib_mutex mutexp)
{
}


/*
 * _lib_unlock_mutex
 * Unlock mutex.
 */

extern void _lib_unlock_mutex(_lib_mutex mutexp)
{
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?