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

📄 unixlib.h

📁 vxworks 6.x 的全部头文件
💻 H
字号:
/* unixLib.h - UNIX kernel compatability library header file *//* * Copyright (c) 1984-2005 Wind River Systems, Inc. * * The right to copy, distribute, modify or otherwise make use * of this software may be licensed only pursuant to the terms * of an applicable Wind River license agreement. *//*modification history--------------------01s,26aug05,dlk  Add section tags.01r,12jul05,kch  Removed _netMalloc() and _netFree() prototypes.01q,07jul05,dlk  Balance parenthesis in wakeup_one().01p,18may05,rp   moved ppsratecheck from icmp6.c to unixLib01o,19apr05,rp   merged from comp_wn_ipv6_mld_interim-dev01n,23aug04,rp   merged from COMP_WN_IPV6_BASE6_ITER5_TO_UNIFIED_PRE_MERGE01m,28may04,niq  Merging from base6 label POST_ITER5_FRZ16_REBASE (ver                 /main/vdt/base6_itn5_networking-int/1)01l,03dec03,asr  Fix compile errors after dinkum libc check-in01k,20nov03,niq  Remove copyright_wrs.h file inclusion01j,05nov03,cdw  Removal of unnecessary _KERNEL guards.01i,04nov03,rlm  Ran batch header path update for header re-org.01h,03nov03,rlm  Removed wrn/coreip/ prefix from #includes for header re-org.01g,10jun03,vvv  include netVersion.h01f,09may03,vvv  included semLib.h and times.h01e,09oct01,hsh  add phashinit routine01d,26sep01,qli  chaning the prototype for "panic"01c,18sep01,ann  adding the prototype of tvToTicks01b,05sep01,ham  corrected microtime's prototype.01a,01sep01,ann  ported to clarinet from AE1.1 version 01f,                 added the prototypes for microtime()*/#ifndef __INCunixLibh#define __INCunixLibh#ifdef __cplusplusextern "C" {#endif#include <netVersion.h>#ifdef _WRS_KERNEL#include <sys/times.h>#else#include <sys/time.h> /* For RTP, it is sys/time.h */#endif#include <semLib.h>#if ((CPU_FAMILY==I960) && (defined __GNUC__))#pragma align 1                 /* tell gcc960 not to optimize alignments */#endif  /* CPU_FAMILY==I960 */#define MALLOC(space, cast, size, type, flags) { \    (space) = (cast) netClusterGet (_pNetSysPool,                 \                                    netClPoolIdGet (_pNetSysPool, \				                    size, TRUE)); \}						 #define FREE(addr, type) { \    netClFree (_pNetSysPool, (unsigned char *) addr); \}			   #define DATA_TO_MBLK(pBuf)	\     (*((struct mbuf **)((char *)(pBuf) - sizeof(struct mbuf **))))            /* Function declarations */#if defined(__STDC__) || defined(__cplusplus)_WRS_FASTTEXTextern int 	splnet (void);_WRS_FASTTEXTextern int 	splimp (void);_WRS_FASTTEXTextern void 	splx (int x);extern void	panic(const char *, ...);extern void 	wakeup (SEM_ID semId);extern void 	ksleep (SEM_ID semId);extern void * 	hashinit (int 	elements, int type, u_long * hashmask);extern void * 	phashinit (int 	elements, int type, u_long * hashmask);extern void     microtime (struct timeval * pTv);extern ULONG    tvToTicks (struct timeval * pTv);extern int      ppsratecheck __P((struct timeval *, int *, int));#else	/* __STDC__ */_WRS_FASTTEXTextern int	splnet ();_WRS_FASTTEXTextern int	splimp ();_WRS_FASTTEXTextern void	splx ();extern void 	panic ();extern void 	wakeup ();extern void 	ksleep();extern void * 	hashinit ();extern void     microtime ();extern ULONG    tvToTicks ();extern int      ppsratecheck ();#endif	/* __STDC__ *//* * BSD defines wakeup() to wake up all tasks sleeping on * the specified channel. wakeup_one() wakes up a single process * (more or less). VxWorks' tsleep() and ksleep() have been modified to * give up splSemId and take the awaited semaphore atomically, which is * necessary whether semFlush() or semGive() is used. * Note, VxWorks has in the past incorrectly made wakeup() equivalent * to semGive() rather than semFlush(). */#define wakeup(semId) ((void)semFlush((semId)))#define wakeup_one(semId) ((void)semGive((semId)))#ifdef __cplusplus}#endif#endif /* __INCunixLibh */

⌨️ 快捷键说明

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