From 51cb6761c6023fa27ba62aa972d7b1c7b3f887b6 Mon Sep 17 00:00:00 2001 From: Ralf Corsepius Date: Sun, 1 May 2005 04:00:43 +0000 Subject: Update from FreeBSD --- cpukit/libnetworking/kern/kern_mib.c | 15 ++++++---- cpukit/libnetworking/sys/libkern.h | 55 ++++++++++++++++++++---------------- 2 files changed, 39 insertions(+), 31 deletions(-) diff --git a/cpukit/libnetworking/kern/kern_mib.c b/cpukit/libnetworking/kern/kern_mib.c index 8d0185e053..6471208786 100644 --- a/cpukit/libnetworking/kern/kern_mib.c +++ b/cpukit/libnetworking/kern/kern_mib.c @@ -16,10 +16,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. * 4. Neither the name of the University nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. @@ -37,7 +33,11 @@ * SUCH DAMAGE. * * @(#)kern_sysctl.c 8.4 (Berkeley) 4/14/94 - * $FreeBSD: src/sys/kern/kern_mib.c,v 1.62 2002/11/07 23:57:17 tmm Exp $ + * $FreeBSD: src/sys/kern/kern_mib.c,v 1.74 2005/02/28 21:42:56 wes Exp $ + */ + +/* + * $Id$ */ #ifndef __rtems__ @@ -97,7 +97,10 @@ SYSCTL_NODE(, OID_AUTO, security, CTLFLAG_RW, 0, SYSCTL_NODE(, OID_AUTO, regression, CTLFLAG_RW, 0, "Regression test MIB"); #endif -#endif + +SYSCTL_STRING(_kern, OID_AUTO, ident, CTLFLAG_RD, + kern_ident, 0, "Kernel identifier"); +#endif /* __rtems__ */ SYSCTL_STRING(_kern, KERN_OSRELEASE, osrelease, CTLFLAG_RD, osrelease, 0, "Operating system release"); diff --git a/cpukit/libnetworking/sys/libkern.h b/cpukit/libnetworking/sys/libkern.h index c01e35b273..fd09ced07f 100644 --- a/cpukit/libnetworking/sys/libkern.h +++ b/cpukit/libnetworking/sys/libkern.h @@ -10,10 +10,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. All advertising materials mentioning features or use of this software - * must display the following acknowledgement: - * This product includes software developed by the University of - * California, Berkeley and its contributors. * 4. Neither the name of the University nor the names of its contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. @@ -31,9 +27,13 @@ * SUCH DAMAGE. * * @(#)libkern.h 8.1 (Berkeley) 6/10/93 - * $Id$ + * $FreeBSD: src/sys/sys/libkern.h,v 1.48 2005/02/10 20:39:39 glebius Exp $ */ +/* + * $Id$ + */ + #ifndef _SYS_LIBKERN_H_ #define _SYS_LIBKERN_H_ @@ -61,29 +61,34 @@ static __inline u_long ulmax(u_long a, u_long b) { return (a > b ? a : b); } static __inline u_long ulmin(u_long a, u_long b) { return (a < b ? a : b); } /* Prototypes for non-quad routines. */ -int bcmp __P((const void *, const void *, size_t)); +int bcmp(const void *, const void *, size_t); #ifndef HAVE_INLINE_FFS -int ffs __P((int)); +int ffs(int); #endif #ifndef HAVE_INLINE_FLS -int fls __P((int)); +int fls(int); +#endif +int locc(int, char *, u_int); +void qsort(void *base, size_t nmemb, size_t size, + int (*compar)(const void *, const void *)); +#if defined(__rtems__) +u_long rtems_bsdnet_random(void); +#define random() rtems_bsdnet_random() +#else +u_long random(void); #endif -int locc __P((int, char *, u_int)); -void qsort __P((void *base, size_t nmemb, size_t size, - int (*compar)(const void *, const void *))); -u_long random __P((void)); -char *index __P((const char *, int)); -char *rindex __P((const char *, int)); -int scanc __P((u_int, const u_char *, const u_char *, int)); -int skpc __P((int, int, char *)); -void srandom __P((u_long)); -char *strcat __P((char *, const char *)); -int strcmp __P((const char *, const char *)); -char *strdup __P((const char *s)); -char *strcpy __P((char *, const char *)); -size_t strlen __P((const char *)); -int strncmp __P((const char *, const char *, size_t)); -char *strncpy __P((char *, const char *, size_t)); -char *strerror __P((int errnum)); +char *index(const char *, int); +char *rindex(const char *, int); +int scanc(u_int, const u_char *, const u_char *, int); +int skpc(int, int, char *); +void srandom(u_long); +char *strcat(char * __restrict, const char * __restrict); +int strcmp(const char *, const char *); +char *strdup(const char *s); +char *strcpy(char * __restrict, const char * __restrict); +size_t strlen(const char *); +int strncmp(const char *, const char *, size_t); +char *strncpy(char * __restrict, const char * __restrict, size_t); +char *strerror(int errnum); #endif /* !_SYS_LIBKERN_H_ */ -- cgit v1.2.3