types.h
来自「Ibmstb02500 miniboot 源码」· C头文件 代码 · 共 88 行
H
88 行
/* openbios/include/sys/types.h, redbios, redbios_iii_1.0 3/23/98 11:41:47 *//*-----------------------------------------------------------------------------+|| This source code has been made available to you by IBM on an AS-IS| basis. Anyone receiving this source is licensed under IBM| copyrights to use it in any way he or she deems fit, including| copying it, modifying it, compiling it, and redistributing it either| with or without modifications. No license under IBM patents or| patent applications is to be implied by the copyright license.|| Any user of this software should understand that IBM cannot provide| technical support for this software and will not be responsible for| any consequences resulting from the use of this software.|| Any person who transfers this source code or any derivative work| must include the IBM copyright notice, this paragraph, and the| preceding two paragraphs in the transferred software.|| COPYRIGHT I B M CORPORATION 1995| LICENSED MATERIAL - PROGRAM PROPERTY OF I B M+-----------------------------------------------------------------------------*//*-----------------------------------------------------------------------------+|| File Name: types.h|| Function: Header file for standard definitions|| Author: A. Booker|| Change Activity-|| Date Description of Change BY| --------- --------------------- ---| 27-Aug-92 Created AJB|+-----------------------------------------------------------------------------*/#ifndef _sys_types_h_#define _sys_types_h_#include <stddef.h>#include <machine/machparm.h>/*-----------------------------------------------------------------------------+| Type definitions.+-----------------------------------------------------------------------------*/typedef int pid_t; /* define process identifier */#ifndef _timer_t#define _timer_ttypedef unsigned long timer_t;#endif#ifndef _time_t#define _time_ttypedef unsigned long time_t;#endiftypedef int dev_t; /* used for device driver numbers */typedef unsigned long gid_t; /* used for group ids */typedef unsigned long ino_t; /* used for file serial numbers */typedef int nlink_t; /* used for link counts */typedef unsigned long uid_t; /* used for user IDs */typedef unsigned long mode_t; /* used for file attributes */typedef long off_t; /* used for file sizes *//*-----------------------------------------------------------------------------+| Popular BSD macros and functions prototypes.+-----------------------------------------------------------------------------*/#define NBBY 8 /* number of bits in a byte */#define FD_ZERO(p) memset((void *)(p), 0, (size_t)sizeof(*(p)))#define bzero(p, n) memset((void *)(p), 0, (size_t)n)#define bcopy(p, d, n) memcpy((void *)(d), (const void *)(p), (size_t)n)#define ovbcopy(p, d, n) memmove((void *)(d), (const void *)(p), (size_t)n)#define bcmp(p, d, n) memcmp((void *)(p), (void *)(d), (size_t)n)#define imin(a, b) (((int)a < (int)b) ? (int)a : (int)b)#define index(p, ch) strchr((const char *)p, (int)ch)#define rindex(p, ch) strrchr((const char *)p, (int)ch)#define ctob(x) ((x)<<PGSHIFT)#define MIN(a,b) (((a)<(b))?(a):(b))#define min(a,b) (((a)<(b))?(a):(b))#define MAX(a,b) (((a)>(b))?(a):(b))#define max(a,b) (((a)>(b))?(a):(b))#define isascii(c) ((unsigned)(c) <= 0177)#endif /* _sys_types_h_ */
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?