⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 libs.h

📁 T-kernel 的extension源代码
💻 H
字号:
/* *---------------------------------------------------------------------- *    T-Kernel / Standard Extension * *    Copyright (C) 2006 by Ken Sakamura. All rights reserved. *    T-Kernel / Standard Extension is distributed  *      under the T-License for T-Kernel / Standard Extension. *---------------------------------------------------------------------- * *    Version:   1.00.00 *    Released by T-Engine Forum(http://www.t-engine.org) at 2006/8/11. * *---------------------------------------------------------------------- *//* *	@(#)libs.h (sys) * *	Internal library functions */#ifndef __SYS_LIBS_H__#define __SYS_LIBS_H__#include <basic.h>#include <sys/queue.h>#ifdef __cplusplusextern "C" {#endif/* * Internal library error during process startup sequence  */IMPORT ER	_StartupError;/* * TRUE for multitasking library  */IMPORT BOOL	_isUseMT( void );/* * Common exclusion control lock in library  */IMPORT ER	_lib_lock( W lockno, BOOL ignore_mintr );IMPORT ER	_lib_locktmo( W lockno, W tmo, BOOL ignore_mintr );IMPORT void	_lib_unlock( W lockno );/* Lockno (0 - 15) */#define _LL_MEMALLOC	0	/* Allocate memory */#define _LL_DLL		1	/* Dynamic loader */#define _LL_GCC		2	/* Gcc run-time support */#define	_LL_ERRNO	2	/* Errno initialize (same as _LL_GCC) */#define _LL_TF		3	/* TRON Code Framework (libtf) */#define _LL_LOOKUP	4	/* Character search library (liblookup) */#define _LL_STLPORT	5	/* C++ class library(libstlport) */#define _LL_STDIO	6	/* Stdio library (libg) */#define	_LL_LIBCTX	7	/* Library context */#define	_LL_MISC	8	/* Local lock *//* * Library context */IMPORT ER	_CreateLibCtxKey( void (*destroy)( void* ) );IMPORT ER	_SetLibCtx( ID keyid, void *value );IMPORT ER	_GetLibCtx( ID keyid, void **value );IMPORT ER	_DeleteLibCtxKey( ID keyid );IMPORT void	_DeleteLibCtxTask( ID tskid );IMPORT void	_DeleteAllLibCtx( void );/* * Processing when task context is discarded */IMPORT int	__atdelctx( void (*func)( ID tskid ) );IMPORT void	_delete_libctx( ID tskid );/* * FIFO lock */typedef struct FiFoLock {	QUEUE	q;	/* A lock wait queue */	ID	tid;	/* A wait task ID/Lock-obtain-state */} FiFoLock;IMPORT void	InitFFLock( FiFoLock* );IMPORT ER	FFLock( FiFoLock* );IMPORT ER	FFUnlock( FiFoLock* );#ifdef __cplusplus}#endif#endif /* __SYS_LIBS_H__ */

⌨️ 快捷键说明

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