[PATCH 01/29] libnetwork: Remove network headers.

Christian Mauderer christian.mauderer at embedded-brains.de
Mon Apr 25 15:06:35 UTC 2016


From: Christian Mauderer <Christian.Mauderer at embedded-brains.de>

They have been moved to newlib.
---
 cpukit/Makefile.am                 |   2 -
 cpukit/include/sys/_iovec.h        |  58 -----
 cpukit/include/sys/uio.h           | 124 ----------
 cpukit/libnetworking/Makefile.am   |  11 +-
 cpukit/libnetworking/arpa/inet.h   | 142 ------------
 cpukit/libnetworking/net/if.h      | 303 ------------------------
 cpukit/libnetworking/netdb.h       | 242 --------------------
 cpukit/libnetworking/netinet/in.h  | 458 -------------------------------------
 cpukit/libnetworking/netinet/tcp.h | 138 -----------
 cpukit/libnetworking/preinstall.am |  36 ---
 cpukit/libnetworking/sys/socket.h  | 405 --------------------------------
 cpukit/libnetworking/sys/syslog.h  | 191 ----------------
 cpukit/libnetworking/sys/un.h      |  76 ------
 cpukit/libnetworking/syslog.h      |   1 -
 cpukit/preinstall.am               |   8 -
 15 files changed, 1 insertion(+), 2194 deletions(-)
 delete mode 100644 cpukit/include/sys/_iovec.h
 delete mode 100644 cpukit/include/sys/uio.h
 delete mode 100644 cpukit/libnetworking/arpa/inet.h
 delete mode 100644 cpukit/libnetworking/net/if.h
 delete mode 100644 cpukit/libnetworking/netdb.h
 delete mode 100644 cpukit/libnetworking/netinet/in.h
 delete mode 100644 cpukit/libnetworking/netinet/tcp.h
 delete mode 100644 cpukit/libnetworking/sys/socket.h
 delete mode 100644 cpukit/libnetworking/sys/syslog.h
 delete mode 100644 cpukit/libnetworking/sys/un.h
 delete mode 100644 cpukit/libnetworking/syslog.h

diff --git a/cpukit/Makefile.am b/cpukit/Makefile.am
index c84ccc3..bd18317 100644
--- a/cpukit/Makefile.am
+++ b/cpukit/Makefile.am
@@ -67,8 +67,6 @@ include_sys_HEADERS += libcsupport/include/sys/termios.h
 include_sys_HEADERS += libcsupport/include/sys/utsname.h
 
 include_sys_HEADERS += include/sys/endian.h
-include_sys_HEADERS += include/sys/uio.h
-include_sys_HEADERS += include/sys/_iovec.h
 include_sys_HEADERS += include/sys/priority.h
 
 if LIBNETWORKING
diff --git a/cpukit/include/sys/_iovec.h b/cpukit/include/sys/_iovec.h
deleted file mode 100644
index a6ca683..0000000
--- a/cpukit/include/sys/_iovec.h
+++ /dev/null
@@ -1,58 +0,0 @@
-/*-
- * Copyright (c) 1982, 1986, 1993, 1994
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)uio.h	8.5 (Berkeley) 2/22/94
- * $FreeBSD$
- */
-
-#ifndef _SYS__IOVEC_HH_
-#define	_SYS__IOVEC_HH_
-
-#include <sys/_types.h>
-
-#ifndef _SIZE_T_DECLARED
-typedef	__size_t	size_t;
-#define	_SIZE_T_DECLARED
-#endif
-
-#ifdef __rtems__
-#ifndef __IOVEC_DEFINED
-#define __IOVEC_DEFINED
-struct iovec {
-	void	*iov_base;	/* Base address. */
-	size_t	 iov_len;	/* Length. */
-};
-#endif /* __IOVEC_DEFINED */
-#else
-struct iovec {
-	void	*iov_base;	/* Base address. */
-	size_t	 iov_len;	/* Length. */
-};
-#endif /* rtems */
-
-#endif /* !_SYS__IOVEC_HH_ */
diff --git a/cpukit/include/sys/uio.h b/cpukit/include/sys/uio.h
deleted file mode 100644
index 56956f0..0000000
--- a/cpukit/include/sys/uio.h
+++ /dev/null
@@ -1,124 +0,0 @@
-/*-
- * Copyright (c) 1982, 1986, 1993, 1994
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)uio.h	8.5 (Berkeley) 2/22/94
- * $FreeBSD$
- */
-
-#ifndef _SYS_UIO_HH_
-#define	_SYS_UIO_HH_
-
-#include <sys/cdefs.h>
-#ifdef __rtems__
-#include <sys/types.h>
-#endif /* __rtems__ */
-#include <sys/_types.h>
-#include <sys/_iovec.h>
-
-#ifndef __rtems__
-#ifndef _SSIZE_T_DECLARED
-typedef	__ssize_t	ssize_t;
-#define	_SSIZE_T_DECLARED
-#endif
-
-#ifndef _OFF_T_DECLARED
-typedef	__off_t	off_t;
-#define	_OFF_T_DECLARED
-#endif
-#endif /* !__rtems__ */
-
-#if __BSD_VISIBLE
-enum	uio_rw { UIO_READ, UIO_WRITE };
-
-/* Segment flag values. */
-enum uio_seg {
-	UIO_USERSPACE,		/* from user data space */
-	UIO_SYSSPACE,		/* from system space */
-	UIO_NOCOPY		/* don't copy, already in object */
-};
-#endif
-
-#ifdef _KERNEL
-
-struct uio {
-	struct	iovec *uio_iov;		/* scatter/gather list */
-	int	uio_iovcnt;		/* length of scatter/gather list */
-	off_t	uio_offset;		/* offset in target object */
-	ssize_t	uio_resid;		/* remaining bytes to process */
-	enum	uio_seg uio_segflg;	/* address space */
-	enum	uio_rw uio_rw;		/* operation */
-	struct	thread *uio_td;		/* owner */
-};
-
-/*
- * Limits
- *
- * N.B.: UIO_MAXIOV must be no less than IOV_MAX from <sys/syslimits.h>
- * which in turn must be no less than _XOPEN_IOV_MAX from <limits.h>.  If
- * we ever make this tunable (probably pointless), then IOV_MAX should be
- * removed from <sys/syslimits.h> and applications would be expected to use
- * sysconf(3) to find out the correct value, or else assume the worst
- * (_XOPEN_IOV_MAX).  Perhaps UIO_MAXIOV should be simply defined as
- * IOV_MAX.
- */
-#define UIO_MAXIOV	1024		/* max 1K of iov's */
-
-struct vm_object;
-struct vm_page;
-
-struct uio *cloneuio(struct uio *uiop);
-int	copyinfrom(const void * __restrict src, void * __restrict dst,
-	    size_t len, int seg);
-int	copyiniov(struct iovec *iovp, u_int iovcnt, struct iovec **iov,
-	    int error);
-int	copyinstrfrom(const void * __restrict src, void * __restrict dst,
-	    size_t len, size_t * __restrict copied, int seg);
-int	copyinuio(struct iovec *iovp, u_int iovcnt, struct uio **uiop);
-void	uio_yield(void);
-int	uiomove(void *cp, int n, struct uio *uio);
-int	uiomove_frombuf(void *buf, int buflen, struct uio *uio);
-#ifndef __rtems__
-int	uiomove_fromphys(struct vm_page *ma[], vm_offset_t offset, int n,
-	    struct uio *uio);
-#endif /* !__rtems__ */
-int	uiomoveco(void *cp, int n, struct uio *uio, int disposable);
-
-#else /* !_KERNEL */
-
-__BEGIN_DECLS
-ssize_t	readv(int, const struct iovec *, int);
-ssize_t	writev(int, const struct iovec *, int);
-#if __BSD_VISIBLE
-ssize_t	preadv(int, const struct iovec *, int, off_t);
-ssize_t	pwritev(int, const struct iovec *, int, off_t);
-#endif
-__END_DECLS
-
-#endif /* _KERNEL */
-
-#endif /* !_SYS_UIO_HH_ */
diff --git a/cpukit/libnetworking/Makefile.am b/cpukit/libnetworking/Makefile.am
index ba3c233..fa0cec2 100644
--- a/cpukit/libnetworking/Makefile.am
+++ b/cpukit/libnetworking/Makefile.am
@@ -22,9 +22,7 @@ libnetworking_a_CPPFLAGS = $(AM_CPPFLAGS) $(libnetworking_CPPFLAGS)
 
 ## poll.h is not in the list because RTEMS does not have poll()
 ## and installing poll.h confuses autoconf.
-include_HEADERS = netdb.h
-include_HEADERS += resolv.h
-include_HEADERS += syslog.h
+include_HEADERS = resolv.h
 
 libnetworking_a_SOURCES = opt_atalk.h opt_bdg.h opt_compat.h opt_inet6.h \
     opt_inet.h opt_ipfw.h opt_ipx.h opt_mac.h opt_mrouting.h opt_netgraph.h \
@@ -37,7 +35,6 @@ libnetworking_a_SOURCES += bpfilter.h
 include_arpadir = $(includedir)/arpa
 
 include_arpa_HEADERS = arpa/ftp.h
-include_arpa_HEADERS += arpa/inet.h
 include_arpa_HEADERS += arpa/nameser.h
 include_arpa_HEADERS += arpa/nameser_compat.h
 
@@ -64,7 +61,6 @@ include_netdir = $(includedir)/net
 
 include_net_HEADERS = net/bpf.h
 include_net_HEADERS += net/ethernet.h
-include_net_HEADERS += net/if.h
 include_net_HEADERS += net/if_arp.h
 include_net_HEADERS += net/if_dl.h
 include_net_HEADERS += net/if_llc.h
@@ -93,7 +89,6 @@ include_netinet_HEADERS = netinet/icmp_var.h
 include_netinet_HEADERS += netinet/if_ether.h
 include_netinet_HEADERS += netinet/igmp.h
 include_netinet_HEADERS += netinet/igmp_var.h
-include_netinet_HEADERS += netinet/in.h
 include_netinet_HEADERS += netinet/in_pcb.h
 include_netinet_HEADERS += netinet/in_systm.h
 include_netinet_HEADERS += netinet/in_var.h
@@ -102,7 +97,6 @@ include_netinet_HEADERS += netinet/ip_fw.h
 include_netinet_HEADERS += netinet/ip_icmp.h
 include_netinet_HEADERS += netinet/ip_mroute.h
 include_netinet_HEADERS += netinet/ip_var.h
-include_netinet_HEADERS += netinet/tcp.h
 include_netinet_HEADERS += netinet/tcp_debug.h
 include_netinet_HEADERS += netinet/tcp_fsm.h
 include_netinet_HEADERS += netinet/tcp_seq.h
@@ -179,14 +173,11 @@ include_sys_HEADERS += sys/reboot.h
 include_sys_HEADERS += sys/resourcevar.h
 include_sys_HEADERS += sys/selinfo.h
 include_sys_HEADERS += sys/signalvar.h
-include_sys_HEADERS += sys/socket.h
 include_sys_HEADERS += sys/socketvar.h
 include_sys_HEADERS += sys/sysctl.h
-include_sys_HEADERS += sys/syslog.h
 include_sys_HEADERS += sys/systm.h
 include_sys_HEADERS += sys/ttydefaults.h
 include_sys_HEADERS += sys/ucred.h
-include_sys_HEADERS += sys/un.h
 
 # vm
 
diff --git a/cpukit/libnetworking/arpa/inet.h b/cpukit/libnetworking/arpa/inet.h
deleted file mode 100644
index 6ea7e70..0000000
--- a/cpukit/libnetworking/arpa/inet.h
+++ /dev/null
@@ -1,142 +0,0 @@
-/*
- * ++Copyright++ 1983, 1993
- * -
- * Copyright (c) 1983, 1993
- *    The Regents of the University of California.  All rights reserved.
- * 
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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. 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.
- * 
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- * -
- * Portions Copyright (c) 1993 by Digital Equipment Corporation.
- * 
- * Permission to use, copy, modify, and distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies, and that
- * the name of Digital Equipment Corporation not be used in advertising or
- * publicity pertaining to distribution of the document or software without
- * specific, written prior permission.
- * 
- * THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL
- * WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS.   IN NO EVENT SHALL DIGITAL EQUIPMENT
- * CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
- * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
- * SOFTWARE.
- * -
- * --Copyright--
- */
-
-/*%
- *	@(#)inet.h	8.1 (Berkeley) 6/2/93
- * $FreeBSD: src/include/arpa/inet.h,v 1.33 2010/07/06 03:48:46 maxim Exp $
- */
-
-
-#ifndef _ARPA_INET_H_
-#define	_ARPA_INET_H_
-
-/* External definitions for functions in inet(3). */
-
-#include <sys/cdefs.h>
-#include <rtems/bsdnet/_types.h>
-
-/* Required for byteorder(3) functions. */
-#include <rtems/endian.h>
-
-#define	INET_ADDRSTRLEN		16
-#define	INET6_ADDRSTRLEN	46
-
-#ifndef _IN_ADDR_T_DECLARED
-typedef	uint32_t	in_addr_t;
-#define	_IN_ADDR_T_DECLARED
-#endif
-
-#ifndef _IN_PORT_T_DECLARED
-typedef	uint16_t	in_port_t;
-#define	_IN_PORT_T_DECLARED
-#endif
-
-/*
- * XXX socklen_t is used by a POSIX.1-2001 interface, but not required by
- * POSIX.1-2001.
- */
-#ifndef _SOCKLEN_T_DECLARED
-typedef	__socklen_t	socklen_t;
-#define	_SOCKLEN_T_DECLARED
-#endif
-
-#ifndef _STRUCT_IN_ADDR_DECLARED
-struct in_addr {
-	in_addr_t s_addr;
-};
-#define	_STRUCT_IN_ADDR_DECLARED
-#endif
-
-#if !defined(__rtems__)	/* RTEMS -- Why rename these? */
-/* XXX all new diversions!! argh!! */
-#if __BSD_VISIBLE
-#define	inet_addr		__inet_addr
-#define	inet_aton		__inet_aton
-#define	inet_lnaof		__inet_lnaof
-#define	inet_makeaddr		__inet_makeaddr
-#define	inet_neta		__inet_neta
-#define	inet_netof		__inet_netof
-#define	inet_network		__inet_network
-#define	inet_net_ntop		__inet_net_ntop
-#define	inet_net_pton		__inet_net_pton
-#define	inet_cidr_ntop		__inet_cidr_ntop
-#define	inet_cidr_pton		__inet_cidr_pton
-#define	inet_ntoa		__inet_ntoa
-#define	inet_ntoa_r		__inet_ntoa_r
-#define	inet_pton		__inet_pton
-#define	inet_ntop		__inet_ntop
-#define	inet_nsap_addr		__inet_nsap_addr
-#define	inet_nsap_ntoa		__inet_nsap_ntoa
-#endif /* __BSD_VISIBLE */
-#endif /* __rtems__ */
-
-__BEGIN_DECLS
-in_addr_t	 inet_addr(const char *);
-char		*inet_ntoa(struct in_addr);
-const char	*inet_ntop(int, const void * __restrict, char * __restrict,
-		    socklen_t);
-int		 inet_pton(int, const char * __restrict, void * __restrict);
-
-#if __BSD_VISIBLE
-int		 inet_aton(const char *, struct in_addr *);
-in_addr_t	 inet_lnaof(struct in_addr);
-struct in_addr	 inet_makeaddr(in_addr_t, in_addr_t);
-char *		 inet_neta(in_addr_t, char *, size_t);
-in_addr_t	 inet_netof(struct in_addr);
-in_addr_t	 inet_network(const char *);
-char		*inet_net_ntop(int, const void *, int, char *, size_t);
-int		 inet_net_pton(int, const char *, void *, size_t);
-unsigned	 inet_nsap_addr(const char *, unsigned char *, int);
-char		*inet_nsap_ntoa(int, const unsigned char *, char *);
-#endif /* __BSD_VISIBLE */
-__END_DECLS
-
-#endif /* !_ARPA_INET_H_ */
diff --git a/cpukit/libnetworking/net/if.h b/cpukit/libnetworking/net/if.h
deleted file mode 100644
index cfa140b..0000000
--- a/cpukit/libnetworking/net/if.h
+++ /dev/null
@@ -1,303 +0,0 @@
-/*
- * Copyright (c) 1982, 1986, 1989, 1993
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)if.h	8.1 (Berkeley) 6/10/93
- * $FreeBSD: src/sys/net/if.h,v 1.95 2005/02/25 19:46:41 brooks Exp $
- */
-
- 
-#ifndef _NET_IF_H_
-#define	_NET_IF_H_
-
-#include <sys/cdefs.h>
-
-#if defined(__rtems__)
-/*
- * FIXME - HACK: BSD defines __BSD_VISIBLE in sys/cdefs.h
- * RTEMS sys/cdefs.h doesn't, so we enforce it here.
- */
-#ifndef __BSD_VISIBLE
-#define __BSD_VISIBLE 1
-#endif
-#include <inttypes.h>
-#include <sys/socket.h> /* struct sockaddr */
-#endif
-
-#ifdef _KERNEL
-#include <sys/queue.h>
-#endif
-
-#if __BSD_VISIBLE
-/*
- * <net/if.h> does not depend on <sys/time.h> on most other systems.  This
- * helps userland compatibility.  (struct timeval ifi_lastchange)
- */
-#ifndef _KERNEL
-#include <sys/time.h>
-#endif
-
-struct ifnet;
-struct	ether_header;
-#endif
-
-/*
- * Length of interface external name, including terminating '\0'.
- * Note: this is the same size as a generic device's external name.
- */
-#define		IF_NAMESIZE	16
-#if __BSD_VISIBLE
-#define		IFNAMSIZ	IF_NAMESIZE
-#define		IF_MAXUNIT	0x7fff	/* historical value */
-#endif
-#if __BSD_VISIBLE
-
-/*
- * Structure used to query names of interface cloners.
- */
-
-struct if_clonereq {
-	int	ifcr_total;		/* total cloners (out) */
-	int	ifcr_count;		/* room for this many in user buffer */
-	char	*ifcr_buffer;		/* buffer for cloner names */
-};
-
-/*
- * Structure describing information about an interface
- * which may be of interest to management entities.
- */
-struct if_data {
-	/* generic interface information */
-	u_char	ifi_type;		/* ethernet, tokenring, etc */
-	u_char	ifi_physical;		/* e.g., AUI, Thinnet, 10base-T, etc */
-	u_char	ifi_addrlen;		/* media address length */
-	u_char	ifi_hdrlen;		/* media header length */
-	u_char	ifi_recvquota;		/* polling quota for receive intrs */
-	u_char	ifi_xmitquota;		/* polling quota for xmit intrs */
-	u_long	ifi_mtu;		/* maximum transmission unit */
-	u_long	ifi_metric;		/* routing metric (external only) */
-	u_long	ifi_baudrate;		/* linespeed */
-	/* volatile statistics */
-	u_long	ifi_ipackets;		/* packets received on interface */
-	u_long	ifi_ierrors;		/* input errors on interface */
-	u_long	ifi_opackets;		/* packets sent on interface */
-	u_long	ifi_oerrors;		/* output errors on interface */
-	u_long	ifi_collisions;		/* collisions on csma interfaces */
-	u_long	ifi_ibytes;		/* total number of octets received */
-	u_long	ifi_obytes;		/* total number of octets sent */
-	u_long	ifi_imcasts;		/* packets received via multicast */
-	u_long	ifi_omcasts;		/* packets sent via multicast */
-	u_long	ifi_iqdrops;		/* dropped on input, this interface */
-	u_long	ifi_noproto;		/* destined for unsupported protocol */
-	u_long	ifi_recvtiming;		/* usec spent receiving when timing */
-	u_long	ifi_xmittiming;		/* usec spent xmitting when timing */
-	struct	timeval ifi_lastchange;	/* time of last administrative change */
-};
-
-#define	IFF_UP		0x1		/* interface is up */
-#define	IFF_BROADCAST	0x2		/* broadcast address valid */
-#define	IFF_DEBUG	0x4		/* turn on debugging */
-#define	IFF_LOOPBACK	0x8		/* is a loopback net */
-#define	IFF_POINTOPOINT	0x10		/* interface is point-to-point link */
-#define	IFF_SMART	0x20		/* interface manages own routes */
-#define	IFF_RUNNING	0x40		/* resources allocated */
-#define	IFF_NOARP	0x80		/* no address resolution protocol */
-#define	IFF_PROMISC	0x100		/* receive all packets */
-#define	IFF_ALLMULTI	0x200		/* receive all multicast packets */
-#define	IFF_OACTIVE	0x400		/* tx hardware queue is full */
-#define	IFF_SIMPLEX	0x800		/* can't hear own transmissions */
-#define	IFF_LINK0	0x1000		/* per link layer defined bit */
-#define	IFF_LINK1	0x2000		/* per link layer defined bit */
-#define	IFF_LINK2	0x4000		/* per link layer defined bit */
-#define	IFF_ALTPHYS	IFF_LINK2	/* use alternate physical connection */
-#define	IFF_MULTICAST	0x8000		/* supports multicast */
-#define	IFF_POLLING	0x10000		/* Interface is in polling mode. */
-#define	IFF_PPROMISC	0x20000		/* user-requested promisc mode */
-#define	IFF_MONITOR	0x40000		/* user-requested monitor mode */
-#define	IFF_STATICARP	0x80000		/* static ARP */
-#define	IFF_NEEDSGIANT	0x100000	/* hold Giant over if_start calls */
-
-/* flags set internally only: */
-#define	IFF_CANTCHANGE \
-	(IFF_BROADCAST|IFF_POINTOPOINT|IFF_RUNNING|IFF_OACTIVE|\
-	    IFF_SIMPLEX|IFF_MULTICAST|IFF_ALLMULTI|IFF_SMART|IFF_PROMISC|\
-	    IFF_POLLING)
-
-/*
- * Values for if_link_state.
- */
-#define	LINK_STATE_UNKNOWN	0	/* link invalid/unknown */
-#define	LINK_STATE_DOWN		1	/* link is down */
-#define	LINK_STATE_UP		2	/* link is up */
-
-/*
- * Some convenience macros used for setting ifi_baudrate.
- * XXX 1000 vs. 1024? --thorpej at netbsd.org
- */
-#define	IF_Kbps(x)	((x) * 1000)		/* kilobits/sec. */
-#define	IF_Mbps(x)	(IF_Kbps((x) * 1000))	/* megabits/sec. */
-#define	IF_Gbps(x)	(IF_Mbps((x) * 1000))	/* gigabits/sec. */
-
-#define	IFQ_MAXLEN	50
-#define	IFNET_SLOWHZ	1		/* granularity is 1 second */
-
-/*
- * Message format for use in obtaining information about interfaces
- * from getkerninfo and the routing socket
- */
-struct if_msghdr {
-	u_short	ifm_msglen;	/* to skip over non-understood messages */
-	u_char	ifm_version;	/* future binary compatibility */
-	u_char	ifm_type;	/* message type */
-	int	ifm_addrs;	/* like rtm_addrs */
-	int	ifm_flags;	/* value of if_flags */
-	u_short	ifm_index;	/* index for associated ifp */
-	struct	if_data ifm_data;/* statistics and other data about if */
-};
-
-/*
- * Message format for use in obtaining information about interface addresses
- * from getkerninfo and the routing socket
- */
-struct ifa_msghdr {
-	u_short	ifam_msglen;	/* to skip over non-understood messages */
-	u_char	ifam_version;	/* future binary compatibility */
-	u_char	ifam_type;	/* message type */
-	int	ifam_addrs;	/* like rtm_addrs */
-	int	ifam_flags;	/* value of ifa_flags */
-	u_short	ifam_index;	/* index for associated ifp */
-	int	ifam_metric;	/* value of ifa_metric */
-};
-
-/* forward declaration */
-struct mbuf;
-
-/*
- * Interface request structure used for socket
- * ioctl's.  All interface ioctl's must have parameter
- * definitions which begin with ifr_name.  The
- * remainder may be interface specific.
- */
-struct	ifreq {
-	char	ifr_name[IFNAMSIZ];		/* if name, e.g. "en0" */
-	union {
-		struct	sockaddr ifru_addr;
-		struct	sockaddr ifru_dstaddr;
-		struct	sockaddr ifru_broadaddr;
-		short	ifru_flags[2];
-		int32_t	ifru_metric;
-		int32_t	ifru_mtu;
-		int	ifru_phys;
-		int	ifru_media;
-		caddr_t	ifru_data;
-		int	(*ifru_tap)(struct ifnet *, struct ether_header *, struct mbuf *);
-	} ifr_ifru;
-#define	ifr_addr	ifr_ifru.ifru_addr	/* address */
-#define	ifr_dstaddr	ifr_ifru.ifru_dstaddr	/* other end of p-to-p link */
-#define	ifr_broadaddr	ifr_ifru.ifru_broadaddr	/* broadcast address */
-#define	ifr_flags	ifr_ifru.ifru_flags[0]	/* flags (low 16 bits) */
-#define	ifr_flagshigh	ifr_ifru.ifru_flags[1]	/* flags (high 16 bits) */
-#define	ifr_metric	ifr_ifru.ifru_metric	/* metric */
-#define	ifr_mtu		ifr_ifru.ifru_mtu	/* mtu */
-#define ifr_phys	ifr_ifru.ifru_phys	/* physical wire */
-#define ifr_media	ifr_ifru.ifru_media	/* physical media */
-#define	ifr_data	ifr_ifru.ifru_data	/* for use by interface */
-#define ifr_tap		ifr_ifru.ifru_tap	/* tap function */
-};
-
-struct ifaliasreq {
-	char	ifra_name[IFNAMSIZ];		/* if name, e.g. "en0" */
-	struct	sockaddr ifra_addr;
-	struct	sockaddr ifra_broadaddr;
-	struct	sockaddr ifra_mask;
-};
-
-struct ifmediareq {
-	char	ifm_name[IFNAMSIZ];	/* if name, e.g. "en0" */
-	int	ifm_current;		/* current media options */
-	int	ifm_mask;		/* don't care mask */
-	int	ifm_status;		/* media status */
-	int	ifm_active;		/* active options */
-	int	ifm_count;		/* # entries in ifm_ulist array */
-	int	*ifm_ulist;		/* media words */
-};
-
-/* 
- * Structure used to retrieve aux status data from interfaces.
- * Kernel suppliers to this interface should respect the formatting
- * needed by ifconfig(8): each line starts with a TAB and ends with
- * a newline.  The canonical example to copy and paste is in if_tun.c.
- */
-
-#define	IFSTATMAX	800		/* 10 lines of text */
-struct ifstat {
-	char	ifs_name[IFNAMSIZ];	/* if name, e.g. "en0" */
-	char	ascii[IFSTATMAX + 1];
-};
-
-/*
- * Structure used in SIOCGIFCONF request.
- * Used to retrieve interface configuration
- * for machine (useful for programs which
- * must know all networks accessible).
- */
-struct	ifconf {
-	int	ifc_len;		/* size of associated buffer */
-	union {
-		caddr_t	ifcu_buf;
-		struct	ifreq *ifcu_req;
-	} ifc_ifcu;
-#define	ifc_buf	ifc_ifcu.ifcu_buf	/* buffer address */
-#define	ifc_req	ifc_ifcu.ifcu_req	/* array of structures returned */
-};
-#endif /* __BSD_VISIBLE */
-
-#ifndef _KERNEL
-struct if_nameindex {
-    unsigned int    if_index;   /* 1, 2, ... */
-    char        *if_name;   /* null terminated name: "le0", ... */
-};
-
-__BEGIN_DECLS
-void             if_freenameindex(struct if_nameindex *);
-char            *if_indextoname(unsigned int, char *);
-struct if_nameindex *if_nameindex(void);
-__END_DECLS
-#endif
-
-#ifdef _KERNEL
-
-/* XXX - this should go away soon. */
-#include <net/if_var.h>
-
-void	ifafree(struct ifaddr *);
-
-int	looutput(struct ifnet *,
-	   struct mbuf *, struct sockaddr *, struct rtentry *);
-#endif
-
-#endif /* !_NET_IF_H_ */
diff --git a/cpukit/libnetworking/netdb.h b/cpukit/libnetworking/netdb.h
deleted file mode 100644
index 4272902..0000000
--- a/cpukit/libnetworking/netdb.h
+++ /dev/null
@@ -1,242 +0,0 @@
-/*-
- * Copyright (c) 1980, 1983, 1988, 1993
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- * -
- * Portions Copyright (c) 1993 by Digital Equipment Corporation.
- *
- * Permission to use, copy, modify, and distribute this software for any
- * purpose with or without fee is hereby granted, provided that the above
- * copyright notice and this permission notice appear in all copies, and that
- * the name of Digital Equipment Corporation not be used in advertising or
- * publicity pertaining to distribution of the document or software without
- * specific, written prior permission.
- *
- * THE SOFTWARE IS PROVIDED "AS IS" AND DIGITAL EQUIPMENT CORP. DISCLAIMS ALL
- * WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS.   IN NO EVENT SHALL DIGITAL EQUIPMENT
- * CORPORATION BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
- * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
- * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
- * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
- * SOFTWARE.
- * -
- * --Copyright--
- */
-
-/*
- *      @(#)netdb.h	8.1 (Berkeley) 6/2/93
- *      From: Id: netdb.h,v 8.9 1996/11/19 08:39:29 vixie Exp $
- * $FreeBSD: src/include/netdb.h,v 1.34 2005/02/14 11:33:11 phantom Exp $
- */
- 
-
-#ifndef _NETDB_H_
-#define _NETDB_H_
-
-#include <sys/cdefs.h>
-#include <rtems/bsdnet/_types.h>
-
-#ifndef _SOCKLEN_T_DECLARED
-typedef	__socklen_t	socklen_t;
-#define	_SOCKLEN_T_DECLARED
-#endif
-
-#ifndef _PATH_HEQUIV
-# define	_PATH_HEQUIV	"/etc/hosts.equiv"
-#endif
-#define	_PATH_HOSTS	"/etc/hosts"
-#define	_PATH_NETWORKS	"/etc/networks"
-#define	_PATH_PROTOCOLS	"/etc/protocols"
-#define	_PATH_SERVICES	"/etc/services"
-
-extern int h_errno;
-
-/*
- * Structures returned by network data base library.  All addresses are
- * supplied in host order, and returned in network order (suitable for
- * use in system calls).
- */
-struct	hostent {
-	char	*h_name;	/* official name of host */
-	char	**h_aliases;	/* alias list */
-	int	h_addrtype;	/* host address type */
-	int	h_length;	/* length of address */
-	char	**h_addr_list;	/* list of addresses from name server */
-#define	h_addr	h_addr_list[0]	/* address, for backward compatibility */
-};
-
-struct	netent {
-	char		*n_name;	/* official name of net */
-	char		**n_aliases;	/* alias list */
-	int		n_addrtype;	/* net address type */
-	uint32_t	n_net;		/* network # */
-};
-
-struct	servent {
-	char	*s_name;	/* official service name */
-	char	**s_aliases;	/* alias list */
-	int	s_port;		/* port # */
-	char	*s_proto;	/* protocol to use */
-};
-
-struct	protoent {
-	char	*p_name;	/* official protocol name */
-	char	**p_aliases;	/* alias list */
-	int	p_proto;	/* protocol # */
-};
-
-struct sockaddr;
-
-/*
- * Error return codes from gethostbyname() and gethostbyaddr()
- * (left in h_errno).
- */
-
-#define	NETDB_INTERNAL	-1	/* see errno */
-#define	NETDB_SUCCESS	0	/* no problem */
-#define	HOST_NOT_FOUND	1 /* Authoritative Answer Host not found */
-#define	TRY_AGAIN	2 /* Non-Authoritative Host not found, or SERVERFAIL */
-#define	NO_RECOVERY	3 /* Non recoverable errors, FORMERR, REFUSED, NOTIMP */
-#define	NO_DATA		4 /* Valid name, no data record of requested type */
-#define	NO_ADDRESS	NO_DATA		/* no address, look for MX record */
-
-/*
- * Error return codes from getaddrinfo()
- */
-#if 0
-/* obsoleted */
-#define	EAI_ADDRFAMILY	 1	/* address family for hostname not supported */
-#endif
-#define	EAI_AGAIN	 2	/* temporary failure in name resolution */
-#define	EAI_BADFLAGS	 3	/* invalid value for ai_flags */
-#define	EAI_FAIL	 4	/* non-recoverable failure in name resolution */
-#define	EAI_FAMILY	 5	/* ai_family not supported */
-#define	EAI_MEMORY	 6	/* memory allocation failure */
-#if 0
-/* obsoleted */
-#define	EAI_NODATA	 7	/* no address associated with hostname */
-#endif
-#define	EAI_NONAME	 8	/* hostname nor servname provided, or not known */
-#define	EAI_SERVICE	 9	/* servname not supported for ai_socktype */
-#define	EAI_SOCKTYPE	10	/* ai_socktype not supported */
-#define	EAI_SYSTEM	11	/* system error returned in errno */
-#define	EAI_BADHINTS	12	/* invalid value for hints */
-#define	EAI_PROTOCOL	13	/* resolved protocol is unknown */
-#define	EAI_OVERFLOW	14	/* argument buffer overflow */
-#define	EAI_MAX		15
-
-/*
- * Constants for getnameinfo()
- */
-#define	NI_MAXHOST	1025
-#define	NI_MAXSERV	32
-
-/*
- * Flag values for getnameinfo()
- */
-#define	NI_NOFQDN	0x00000001
-#define	NI_NUMERICHOST	0x00000002
-#define	NI_NAMEREQD	0x00000004
-#define	NI_NUMERICSERV	0x00000008
-#define	NI_DGRAM	0x00000010
-#if 0 /* obsolete */
-#define NI_WITHSCOPEID	0x00000020
-#endif
-
-__BEGIN_DECLS
-void		endhostent(void);
-void		endnetent(void);
-void		endprotoent(void);
-void		endservent(void);
-struct hostent	*gethostbyaddr(const void *, socklen_t, int);
-struct hostent	*gethostbyname(const char *);
-struct hostent	*gethostbyname2(const char *, int);
-struct hostent	*gethostent(void);
-struct netent	*getnetbyaddr(uint32_t, int);
-struct netent	*getnetbyname(const char *);
-struct netent	*getnetent(void);
-struct protoent	*getprotobyname(const char *);
-struct protoent	*getprotobynumber(int);
-struct protoent	*getprotoent(void);
-struct servent	*getservbyname(const char *, const char *);
-struct servent	*getservbyport(int, const char *);
-struct servent	*getservent(void);
-void		herror(const char *);
-__const char	*hstrerror(int);
-void		sethostent(int);
-/* void		sethostfile(const char *); */
-void		setnetent(int);
-void		setprotoent(int);
-void		setservent(int);
-int		getnameinfo(const struct sockaddr *, socklen_t, char *,
-			    size_t, char *, size_t, int);
-
-#ifdef _THREAD_SAFE
-struct hostent* gethostent_r(char* buf, int len);
-int gethostbyname_r(const char*      name, 
-                    struct hostent*  result,
-                    char            *buf, 
-                    int              buflen,
-                    struct hostent **RESULT, 
-                    int             *h_errnop) ;
-#endif		    
-
-/*
- * PRIVATE functions specific to the FreeBSD implementation
- */
-
-/* DO NOT USE THESE, THEY ARE SUBJECT TO CHANGE AND ARE NOT PORTABLE!!! */
-void	_sethosthtent(int);
-void	_endhosthtent(void);
-void	_sethostdnsent(int);
-void	_endhostdnsent(void);
-void	_setnethtent(int);
-void	_endnethtent(void);
-void	_setnetdnsent(int);
-void	_endnetdnsent(void);
-struct hostent * _gethostbyhtname(const char *, int);
-struct hostent * _gethostbydnsname(const char *, int);
-struct hostent * _gethostbynisname(const char *, int);
-struct hostent * _gethostbyhtaddr (const char *, int, int);
-struct hostent * _gethostbydnsaddr(const char *, int, int);
-struct hostent * _gethostbynisaddr(const char *, int, int);
-struct netent *  _getnetbyhtname (const char *);
-struct netent *  _getnetbydnsname(const char *);
-struct netent *  _getnetbynisname(const char *);
-struct netent *  _getnetbyhtaddr (unsigned long, int);
-struct netent *  _getnetbydnsaddr(unsigned long, int);
-struct netent *  _getnetbynisaddr(unsigned long, int);
-void _map_v4v6_address(const char *, char *);
-void _map_v4v6_hostent(struct hostent *, char **, int *len);
-__END_DECLS
-
-#endif /* !_NETDB_H_ */
diff --git a/cpukit/libnetworking/netinet/in.h b/cpukit/libnetworking/netinet/in.h
deleted file mode 100644
index 5a264e0..0000000
--- a/cpukit/libnetworking/netinet/in.h
+++ /dev/null
@@ -1,458 +0,0 @@
-/*
- * Copyright (c) 1982, 1986, 1990, 1993
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)in.h	8.3 (Berkeley) 1/3/94
- * $FreeBSD: src/sys/netinet/in.h,v 1.91 2005/08/22 16:13:07 andre Exp $
- */
- 
-
-#ifndef _NETINET_IN_H_
-#define _NETINET_IN_H_
-
-#include <rtems/bsdnet/_types.h>
-#include <rtems/endian.h>
-
-#ifndef _IN_ADDR_T_DECLARED
-typedef uint32_t        	in_addr_t;
-#define _IN_ADDR_T_DECLARED
-#endif
-
-/* Protocols common to RFC 1700, POSIX, and X/Open. */
-#define	IPPROTO_IP		0		/* dummy for IP */
-#define	IPPROTO_ICMP		1		/* control message protocol */
-#define	IPPROTO_TCP		6		/* tcp */
-#define	IPPROTO_UDP		17		/* user datagram protocol */
-
-#define	INADDR_ANY		(u_int32_t)0x00000000
-#define	INADDR_BROADCAST	(u_int32_t)0xffffffff	/* must be masked */
-
-#ifndef _IN_PORT_T_DECLARED
-typedef	uint16_t		in_port_t;
-#define	_IN_PORT_T_DECLARED
-#endif
-
-#ifndef _SA_FAMILY_T_DECLARED
-typedef	__sa_family_t		sa_family_t;
-#define	_SA_FAMILY_T_DECLARED
-#endif
-
-/* Internet address (a structure for historical reasons). */
-#ifndef _STRUCT_IN_ADDR_DECLARED
-struct in_addr {
-	in_addr_t s_addr;
-};
-#define _STRUCT_IN_ADDR_DECLARED
-#endif
-
-/* Socket address, internet style. */
-struct sockaddr_in {
-	uint8_t	sin_len;
-	sa_family_t	sin_family;
-	in_port_t	sin_port;
-	struct	in_addr sin_addr;
-	char	sin_zero[8];
-};
-
-
-/*
- * Constants and structures defined by the internet system,
- * Per RFC 790, September 1981, and numerous additions.
- */
-
-/*
- * Protocols (RFC 1700)
- */
-#define	IPPROTO_HOPOPTS		0		/* IP6 hop-by-hop options */
-#define	IPPROTO_IGMP		2		/* group mgmt protocol */
-#define	IPPROTO_GGP		3		/* gateway^2 (deprecated) */
-#define	IPPROTO_IPV4		4		/* IPv4 encapsulation */
-#define	IPPROTO_IPIP		IPPROTO_IPV4	/* for compatibility */
-#define	IPPROTO_ST		7		/* Stream protocol II */
-#define	IPPROTO_EGP		8		/* exterior gateway protocol */
-#define	IPPROTO_PIGP		9		/* private interior gateway */
-#define	IPPROTO_RCCMON		10		/* BBN RCC Monitoring */
-#define	IPPROTO_NVPII		11		/* network voice protocol*/
-#define	IPPROTO_PUP		12		/* pup */
-#define	IPPROTO_ARGUS		13		/* Argus */
-#define	IPPROTO_EMCON		14		/* EMCON */
-#define	IPPROTO_XNET		15		/* Cross Net Debugger */
-#define	IPPROTO_CHAOS		16		/* Chaos*/
-#define	IPPROTO_MUX		18		/* Multiplexing */
-#define	IPPROTO_MEAS		19		/* DCN Measurement Subsystems */
-#define	IPPROTO_HMP		20		/* Host Monitoring */
-#define	IPPROTO_PRM		21		/* Packet Radio Measurement */
-#define	IPPROTO_IDP		22		/* xns idp */
-#define	IPPROTO_TRUNK1		23		/* Trunk-1 */
-#define	IPPROTO_TRUNK2		24		/* Trunk-2 */
-#define	IPPROTO_LEAF1		25		/* Leaf-1 */
-#define	IPPROTO_LEAF2		26		/* Leaf-2 */
-#define	IPPROTO_RDP		27		/* Reliable Data */
-#define	IPPROTO_IRTP		28		/* Reliable Transaction */
-#define	IPPROTO_TP		29 		/* tp-4 w/ class negotiation */
-#define	IPPROTO_BLT		30		/* Bulk Data Transfer */
-#define	IPPROTO_NSP		31		/* Network Services */
-#define	IPPROTO_INP		32		/* Merit Internodal */
-#define	IPPROTO_SEP		33		/* Sequential Exchange */
-#define	IPPROTO_3PC		34		/* Third Party Connect */
-#define	IPPROTO_IDPR		35		/* InterDomain Policy Routing */
-#define	IPPROTO_XTP		36		/* XTP */
-#define	IPPROTO_DDP		37		/* Datagram Delivery */
-#define	IPPROTO_CMTP		38		/* Control Message Transport */
-#define	IPPROTO_TPXX		39		/* TP++ Transport */
-#define	IPPROTO_IL		40		/* IL transport protocol */
-#define	IPPROTO_IPV6		41		/* IP6 header */
-#define	IPPROTO_SDRP		42		/* Source Demand Routing */
-#define	IPPROTO_ROUTING		43		/* IP6 routing header */
-#define	IPPROTO_FRAGMENT	44		/* IP6 fragmentation header */
-#define	IPPROTO_IDRP		45		/* InterDomain Routing*/
-#define IPPROTO_RSVP		46 		/* resource reservation */
-#define	IPPROTO_GRE		47		/* General Routing Encap. */
-#define	IPPROTO_MHRP		48		/* Mobile Host Routing */
-#define	IPPROTO_BHA		49		/* BHA */
-#define	IPPROTO_ESP		50		/* IP6 Encap Sec. Payload */
-#define	IPPROTO_AH		51		/* IP6 Auth Header */
-#define	IPPROTO_INLSP		52		/* Integ. Net Layer Security */
-#define	IPPROTO_SWIPE		53		/* IP with encryption */
-#define	IPPROTO_NHRP		54		/* Next Hop Resolution */
-#define	IPPROTO_MOBILE		55		/* IP Mobility */
-#define	IPPROTO_TLSP		56		/* Transport Layer Security */
-#define	IPPROTO_SKIP		57		/* SKIP */
-#define	IPPROTO_ICMPV6		58		/* ICMP6 */
-#define	IPPROTO_NONE		59		/* IP6 no next header */
-#define	IPPROTO_DSTOPTS		60		/* IP6 destination option */
-#define	IPPROTO_AHIP		61		/* any host internal protocol */
-#define	IPPROTO_CFTP		62		/* CFTP */
-#define	IPPROTO_HELLO		63		/* "hello" routing protocol */
-#define	IPPROTO_SATEXPAK	64		/* SATNET/Backroom EXPAK */
-#define	IPPROTO_KRYPTOLAN	65		/* Kryptolan */
-#define	IPPROTO_RVD		66		/* Remote Virtual Disk */
-#define	IPPROTO_IPPC		67		/* Pluribus Packet Core */
-#define	IPPROTO_ADFS		68		/* Any distributed FS */
-#define	IPPROTO_SATMON		69		/* Satnet Monitoring */
-#define	IPPROTO_VISA		70		/* VISA Protocol */
-#define	IPPROTO_IPCV		71		/* Packet Core Utility */
-#define	IPPROTO_CPNX		72		/* Comp. Prot. Net. Executive */
-#define	IPPROTO_CPHB		73		/* Comp. Prot. HeartBeat */
-#define	IPPROTO_WSN		74		/* Wang Span Network */
-#define	IPPROTO_PVP		75		/* Packet Video Protocol */
-#define	IPPROTO_BRSATMON	76		/* BackRoom SATNET Monitoring */
-#define	IPPROTO_ND		77		/* Sun net disk proto (temp.) */
-#define	IPPROTO_WBMON		78		/* WIDEBAND Monitoring */
-#define	IPPROTO_WBEXPAK		79		/* WIDEBAND EXPAK */
-#define	IPPROTO_EON		80		/* ISO cnlp */
-#define	IPPROTO_VMTP		81		/* VMTP */
-#define	IPPROTO_SVMTP		82		/* Secure VMTP */
-#define	IPPROTO_VINES		83		/* Banyon VINES */
-#define	IPPROTO_TTP		84		/* TTP */
-#define	IPPROTO_IGP		85		/* NSFNET-IGP */
-#define	IPPROTO_DGP		86		/* dissimilar gateway prot. */
-#define	IPPROTO_TCF		87		/* TCF */
-#define	IPPROTO_IGRP		88		/* Cisco/GXS IGRP */
-#define	IPPROTO_OSPFIGP		89		/* OSPFIGP */
-#define	IPPROTO_SRPC		90		/* Strite RPC protocol */
-#define	IPPROTO_LARP		91		/* Locus Address Resoloution */
-#define	IPPROTO_MTP		92		/* Multicast Transport */
-#define	IPPROTO_AX25		93		/* AX.25 Frames */
-#define	IPPROTO_IPEIP		94		/* IP encapsulated in IP */
-#define	IPPROTO_MICP		95		/* Mobile Int.ing control */
-#define	IPPROTO_SCCSP		96		/* Semaphore Comm. security */
-#define	IPPROTO_ETHERIP		97		/* Ethernet IP encapsulation */
-#define	IPPROTO_ENCAP		98		/* encapsulation header */
-#define	IPPROTO_APES		99		/* any private encr. scheme */
-#define	IPPROTO_GMTP		100		/* GMTP*/
-#define	IPPROTO_IPCOMP		108		/* payload compression (IPComp) */
-/* 101-254: Partly Unassigned */
-#define	IPPROTO_PIM		103		/* Protocol Independent Mcast */
-#define	IPPROTO_CARP		112		/* CARP */
-#define	IPPROTO_PGM		113		/* PGM */
-#define	IPPROTO_PFSYNC		240		/* PFSYNC */
-/* 255: Reserved */
-/* BSD Private, local use, namespace incursion */
-#define	IPPROTO_DIVERT		254		/* divert pseudo-protocol */
-#define	IPPROTO_RAW		255		/* raw IP packet */
-#define	IPPROTO_MAX		256
-
-/*
- * Merged from FreeBSD 1.78 of this file so Python compiles.
- * This is a size value for functions such as inet_ntop().
- */
-#define	INET_ADDRSTRLEN		16
-
-/*
- * Local port number conventions:
- *
- * When a user does a bind(2) or connect(2) with a port number of zero,
- * a non-conflicting local port address is chosen.
- * The default range is IPPORT_HIFIRSTAUTO through
- * IPPORT_HILASTAUTO, although that is settable by sysctl.
- *
- * A user may set the IPPROTO_IP option IP_PORTRANGE to change this
- * default assignment range.
- *
- * The value IP_PORTRANGE_DEFAULT causes the default behavior.
- *
- * The value IP_PORTRANGE_HIGH changes the range of candidate port numbers
- * into the "high" range.  These are reserved for client outbound connections
- * which do not want to be filtered by any firewalls.
- *
- * The value IP_PORTRANGE_LOW changes the range to the "low" are
- * that is (by convention) restricted to privileged processes.  This
- * convention is based on "vouchsafe" principles only.  It is only secure
- * if you trust the remote host to restrict these ports.
- *
- * The default range of ports and the high range can be changed by
- * sysctl(3).  (net.inet.ip.port{hi,low}{first,last}_auto)
- *
- * Changing those values has bad security implications if you are
- * using a stateless firewall that is allowing packets outside of that
- * range in order to allow transparent outgoing connections.
- *
- * Such a firewall configuration will generally depend on the use of these
- * default values.  If you change them, you may find your Security
- * Administrator looking for you with a heavy object.
- */
-
-/*
- * Ports < IPPORT_RESERVED are reserved for
- * privileged processes (e.g. root).         (IP_PORTRANGE_LOW)
- * Ports > IPPORT_USERRESERVED are reserved
- * for servers, not necessarily privileged.  (IP_PORTRANGE_DEFAULT)
- */
-#define	IPPORT_RESERVED		1024
-#define	IPPORT_USERRESERVED	5000
-
-/*
- * Default local port range to use by setting IP_PORTRANGE_HIGH
- */
-#define	IPPORT_HIFIRSTAUTO	40000
-#define	IPPORT_HILASTAUTO	44999
-
-/*
- * Scanning for a free reserved port return a value below IPPORT_RESERVED,
- * but higher than IPPORT_RESERVEDSTART.  Traditionally the start value was
- * 512, but that conflicts with some well-known-services that firewalls may
- * have a fit if we use.
- */
-#define IPPORT_RESERVEDSTART	600
-/*
- * Definitions of bits in internet address integers.
- * On subnets, the decomposition of addresses to host and net parts
- * is done according to subnet mask, not the masks here.
- */
-#define	IN_CLASSA(i)		(((u_int32_t)(i) & 0x80000000) == 0)
-#define	IN_CLASSA_NET		0xff000000
-#define	IN_CLASSA_NSHIFT	24
-#define	IN_CLASSA_HOST		0x00ffffff
-#define	IN_CLASSA_MAX		128
-
-#define	IN_CLASSB(i)		(((u_int32_t)(i) & 0xc0000000) == 0x80000000)
-#define	IN_CLASSB_NET		0xffff0000
-#define	IN_CLASSB_NSHIFT	16
-#define	IN_CLASSB_HOST		0x0000ffff
-#define	IN_CLASSB_MAX		65536
-
-#define	IN_CLASSC(i)		(((u_int32_t)(i) & 0xe0000000) == 0xc0000000)
-#define	IN_CLASSC_NET		0xffffff00
-#define	IN_CLASSC_NSHIFT	8
-#define	IN_CLASSC_HOST		0x000000ff
-
-#define	IN_CLASSD(i)		(((u_int32_t)(i) & 0xf0000000) == 0xe0000000)
-#define	IN_CLASSD_NET		0xf0000000	/* These ones aren't really */
-#define	IN_CLASSD_NSHIFT	28		/* net and host fields, but */
-#define	IN_CLASSD_HOST		0x0fffffff	/* routing needn't know.    */
-#define	IN_MULTICAST(i)		IN_CLASSD(i)
-
-#define	IN_EXPERIMENTAL(i)	(((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
-#define	IN_BADCLASS(i)		(((u_int32_t)(i) & 0xf0000000) == 0xf0000000)
-
-#define	INADDR_LOOPBACK		(u_int32_t)0x7f000001
-#ifndef _KERNEL
-#define	INADDR_NONE		0xffffffff		/* -1 return */
-#endif
-
-#define	INADDR_UNSPEC_GROUP	(u_int32_t)0xe0000000	/* 224.0.0.0 */
-#define	INADDR_ALLHOSTS_GROUP	(u_int32_t)0xe0000001	/* 224.0.0.1 */
-#define	INADDR_ALLRTRS_GROUP	(u_int32_t)0xe0000002	/* 224.0.0.2 */
-#define	INADDR_MAX_LOCAL_GROUP	(u_int32_t)0xe00000ff	/* 224.0.0.255 */
-
-#define	IN_LOOPBACKNET		(u_int32_t)127			/* official! */
-
-/*
- * Options for use with [gs]etsockopt at the IP level.
- * First word of comment is data type; bool is stored in int.
- */
-#define	IP_OPTIONS		1    /* buf/ip_opts; set/get IP options */
-#define	IP_HDRINCL		2    /* int; header is included with data */
-#define	IP_TOS			3    /* int; IP type of service and preced. */
-#define	IP_TTL			4    /* int; IP time to live */
-#define	IP_RECVOPTS		5    /* bool; receive all IP opts w/dgram */
-#define	IP_RECVRETOPTS		6    /* bool; receive IP opts for response */
-#define	IP_RECVDSTADDR		7    /* bool; receive IP dst addr w/dgram */
-#define	IP_SENDSRCADDR		IP_RECVDSTADDR /* cmsg_type to set src addr */
-#define	IP_RETOPTS		8    /* ip_opts; set/get IP options */
-#define	IP_MULTICAST_IF		9    /* u_char; set/get IP multicast i/f  */
-#define	IP_MULTICAST_TTL	10   /* u_char; set/get IP multicast ttl */
-#define	IP_MULTICAST_LOOP	11   /* u_char; set/get IP multicast loopback */
-#define	IP_ADD_MEMBERSHIP	12   /* ip_mreq; add an IP group membership */
-#define	IP_DROP_MEMBERSHIP	13   /* ip_mreq; drop an IP group membership */
-#define IP_MULTICAST_VIF	14   /* set/get IP mcast virt. iface */
-#define IP_RSVP_ON		15   /* enable RSVP in kernel */
-#define IP_RSVP_OFF		16   /* disable RSVP in kernel */
-#define IP_RSVP_VIF_ON		17   /* set RSVP per-vif socket */
-#define IP_RSVP_VIF_OFF		18   /* unset RSVP per-vif socket */
-#define IP_PORTRANGE		19   /* int; range to choose for unspec port */
-#define	IP_RECVIF		20   /* bool; receive reception if w/dgram */
-
-#define IP_FW_ADD     		50   /* add a firewall rule to chain */
-#define IP_FW_DEL    		51   /* delete a firewall rule from chain */
-#define IP_FW_FLUSH   		52   /* flush firewall rule chain */
-#define IP_FW_ZERO    		53   /* clear single/all firewall counter(s) */
-#define IP_FW_GET     		54   /* get entire firewall rule chain */
-#define IP_NAT			55   /* set/get NAT opts */
-
-/*
- * Defaults and limits for options
- */
-#define	IP_DEFAULT_MULTICAST_TTL  1	/* normally limit m'casts to 1 hop  */
-#define	IP_DEFAULT_MULTICAST_LOOP 1	/* normally hear sends if a member  */
-#define	IP_MAX_MEMBERSHIPS	20	/* per socket */
-
-/*
- * Argument structure for IP_ADD_MEMBERSHIP and IP_DROP_MEMBERSHIP.
- */
-struct ip_mreq {
-	struct	in_addr imr_multiaddr;	/* IP multicast address of group */
-	struct	in_addr imr_interface;	/* local IP address of interface */
-};
-
-/*
- * Argument for IP_PORTRANGE:
- * - which range to search when port is unspecified at bind() or connect()
- */
-#define	IP_PORTRANGE_DEFAULT	0	/* default range */
-#define	IP_PORTRANGE_HIGH	1	/* "high" - request firewall bypass */
-#define	IP_PORTRANGE_LOW	2	/* "low" - vouchsafe security */
-
-/*
- * Definitions for inet sysctl operations.
- *
- * Third level is protocol number.
- * Fourth level is desired variable within that protocol.
- */
-#define	IPPROTO_MAXID	(IPPROTO_IDP + 1)	/* don't list to IPPROTO_MAX */
-
-#define	CTL_IPPROTO_NAMES { \
-	{ "ip", CTLTYPE_NODE }, \
-	{ "icmp", CTLTYPE_NODE }, \
-	{ "igmp", CTLTYPE_NODE }, \
-	{ "ggp", CTLTYPE_NODE }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ "tcp", CTLTYPE_NODE }, \
-	{ 0, 0 }, \
-	{ "egp", CTLTYPE_NODE }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ "pup", CTLTYPE_NODE }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ "udp", CTLTYPE_NODE }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ 0, 0 }, \
-	{ "idp", CTLTYPE_NODE }, \
-}
-
-/*
- * Names for IP sysctl objects
- */
-#define	IPCTL_FORWARDING	1	/* act as router */
-#define	IPCTL_SENDREDIRECTS	2	/* may send redirects when forwarding */
-#define	IPCTL_DEFTTL		3	/* default TTL */
-#ifdef notyet
-#define	IPCTL_DEFMTU		4	/* default MTU */
-#endif
-#define IPCTL_RTEXPIRE		5	/* cloned route expiration time */
-#define IPCTL_RTMINEXPIRE	6	/* min value for expiration time */
-#define IPCTL_RTMAXCACHE	7	/* trigger level for dynamic expire */
-#define	IPCTL_SOURCEROUTE	8	/* may perform source routes */
-#define	IPCTL_DIRECTEDBROADCAST	9	/* may re-broadcast received packets */
-#define IPCTL_INTRQMAXLEN	10	/* max length of netisr queue */
-#define IPCTL_INTRQDROPS	11	/* number of netisr q drops */
-#define	IPCTL_ACCEPTSOURCEROUTE	13	/* may accept source routed packets */
-#define	IPCTL_MAXID		13
-
-#define	IPCTL_NAMES { \
-	{ 0, 0 }, \
-	{ "forwarding", CTLTYPE_INT }, \
-	{ "redirect", CTLTYPE_INT }, \
-	{ "ttl", CTLTYPE_INT }, \
-	{ "mtu", CTLTYPE_INT }, \
-	{ "rtexpire", CTLTYPE_INT }, \
-	{ "rtminexpire", CTLTYPE_INT }, \
-	{ "rtmaxcache", CTLTYPE_INT }, \
-	{ "sourceroute", CTLTYPE_INT }, \
- 	{ "directed-broadcast", CTLTYPE_INT }, \
-	{ "intr-queue-maxlen", CTLTYPE_INT }, \
-	{ "intr-queue-drops", CTLTYPE_INT }, \
-	{ "accept_sourceroute", CTLTYPE_INT }, \
-}
-
-
-#ifdef _KERNEL
-
-struct ifnet; struct mbuf;	/* forward declarations for Standard C */
-
-int	 in_broadcast(struct in_addr, struct ifnet *);
-int	 in_canforward(struct in_addr);
-int	 in_cksum(struct mbuf *, int);
-int	 in_localaddr(struct in_addr);
-char 	*inet_ntoa(struct in_addr); /* in libkern */
-
-/* Firewall hooks */
-struct ip;
-typedef	int ip_fw_chk_t(struct ip**, int, struct ifnet*, int, struct mbuf**);
-typedef	int ip_fw_ctl_t(int, struct mbuf**);
-extern	ip_fw_chk_t *ip_fw_chk_ptr;
-extern	ip_fw_ctl_t *ip_fw_ctl_ptr;
-
-/* IP NAT hooks */
-typedef	int ip_nat_t(struct ip**, struct mbuf**, struct ifnet*, int);
-typedef	int ip_nat_ctl_t(int, struct mbuf**);
-extern	ip_nat_t *ip_nat_ptr;
-extern	ip_nat_ctl_t *ip_nat_ctl_ptr;
-#define	IP_NAT_IN	0x00000001
-#define	IP_NAT_OUT	0x00000002
-
-#endif /* _KERNEL */
-
-#endif /* !_NETINET_IN_H_*/
diff --git a/cpukit/libnetworking/netinet/tcp.h b/cpukit/libnetworking/netinet/tcp.h
deleted file mode 100644
index 2262803..0000000
--- a/cpukit/libnetworking/netinet/tcp.h
+++ /dev/null
@@ -1,138 +0,0 @@
-/*
- * Copyright (c) 1982, 1986, 1993
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)tcp.h	8.1 (Berkeley) 6/10/93
- * $FreeBSD: src/sys/netinet/tcp.h,v 1.30 2005/01/07 01:45:45 imp Exp $
- */
- 
-
-#ifndef _NETINET_TCP_H_
-#define _NETINET_TCP_H_
-
-#include <sys/cdefs.h>
-
-#if __BSD_VISIBLE
-#include <machine/endian.h> /* BYTE_ORDER */
-
-typedef	u_int32_t tcp_seq;
-
-#define tcp6_seq	tcp_seq	/* for KAME src sync over BSD*'s */
-#define tcp6hdr		tcphdr	/* for KAME src sync over BSD*'s */
-
-typedef u_long	tcp_cc;			/* connection count per rfc1644 */
-
-/*
- * TCP header.
- * Per RFC 793, September, 1981.
- */
-struct tcphdr {
-	u_short	th_sport;		/* source port */
-	u_short	th_dport;		/* destination port */
-	tcp_seq	th_seq;			/* sequence number */
-	tcp_seq	th_ack;			/* acknowledgement number */
-#if BYTE_ORDER == LITTLE_ENDIAN
-	u_int	th_x2:4,		/* (unused) */
-		th_off:4;		/* data offset */
-#endif
-#if BYTE_ORDER == BIG_ENDIAN
-	u_int	th_off:4,		/* data offset */
-		th_x2:4;		/* (unused) */
-#endif
-	u_char	th_flags;
-#define	TH_FIN	0x01
-#define	TH_SYN	0x02
-#define	TH_RST	0x04
-#define	TH_PUSH	0x08
-#define	TH_ACK	0x10
-#define	TH_URG	0x20
-#define	TH_ECE	0x40
-#define	TH_CWR	0x80
-#define	TH_FLAGS	(TH_FIN|TH_SYN|TH_RST|TH_ACK|TH_URG|TH_ECE|TH_CWR)
-
-	u_short	th_win;			/* window */
-	u_short	th_sum;			/* checksum */
-	u_short	th_urp;			/* urgent pointer */
-};
-
-#define	TCPOPT_EOL		0L
-#define	TCPOPT_NOP		1L
-#define	TCPOPT_MAXSEG		2L
-#define    TCPOLEN_MAXSEG		4L
-#define TCPOPT_WINDOW		3L
-#define    TCPOLEN_WINDOW		3L
-#define TCPOPT_SACK_PERMITTED	4L		/* Experimental */
-#define    TCPOLEN_SACK_PERMITTED	2L
-#define TCPOPT_SACK		5L		/* Experimental */
-#define TCPOPT_TIMESTAMP	8L
-#define    TCPOLEN_TIMESTAMP		10L
-#define    TCPOLEN_TSTAMP_APPA		(uint32_t)(TCPOLEN_TIMESTAMP+2) /* appendix A */
-#define    TCPOPT_TSTAMP_HDR		\
-    (uint32_t)(((uint32_t)TCPOPT_NOP<<24)| \
-               ((uint32_t)TCPOPT_NOP<<16)| \
-               ((uint32_t)TCPOPT_TIMESTAMP<<8)| \
-               ((uint32_t)TCPOLEN_TIMESTAMP))
-
-#define	TCPOPT_CC		11		/* CC options: RFC-1644 */
-#define TCPOPT_CCNEW		12
-#define TCPOPT_CCECHO		13
-#define	   TCPOLEN_CC			6
-#define	   TCPOLEN_CC_APPA		(TCPOLEN_CC+2)
-#define	   TCPOPT_CC_HDR(ccopt)		\
-    (TCPOPT_NOP<<24|TCPOPT_NOP<<16|(ccopt)<<8|TCPOLEN_CC)
-
-/*
- * Default maximum segment size for TCP.
- * With an IP MTU of 576, this is 536,
- * but 512 is probably more convenient.
- * This should be defined as MIN(512, IP_MSS - sizeof (struct tcpiphdr)).
- */
-#define	TCP_MSS	512
-
-#define	TCP_MAXWIN	65535	/* largest value for (unscaled) window */
-#define	TTCP_CLIENT_SND_WND	4096	/* dflt send window for T/TCP client */
-
-#define TCP_MAX_WINSHIFT	14	/* maximum window shift */
-
-#define TCP_MAXHLEN	(0xf<<2)	/* max length of header in bytes */
-#define TCP_MAXOLEN	(TCP_MAXHLEN - sizeof(struct tcphdr))
-					/* max space left for options */
-#endif /* __BSD_VISIBLE */
-
-/*
- * User-settable options (used with setsockopt).
- */
-#define	TCP_NODELAY	0x01	/* don't delay send to coalesce packets */
-#if __BSD_VISIBLE
-#define	TCP_MAXSEG	0x02	/* set maximum segment size */
-#define TCP_NOPUSH	0x04	/* don't push last block of write */
-#define TCP_NOOPT	0x08	/* don't use TCP options */
-#define TCP_MD5SIG	0x10	/* use MD5 digests (RFC2385) */
-#define	TCP_INFO	0x20	/* retrieve tcp_info structure */
-#endif
-
-#endif /* !_NETINET_TCP_H_ */
diff --git a/cpukit/libnetworking/preinstall.am b/cpukit/libnetworking/preinstall.am
index 477b19a..18e4586 100644
--- a/cpukit/libnetworking/preinstall.am
+++ b/cpukit/libnetworking/preinstall.am
@@ -19,18 +19,10 @@ $(PROJECT_INCLUDE)/$(dirstamp):
 PREINSTALL_DIRS += $(PROJECT_INCLUDE)/$(dirstamp)
 
 if LIBNETWORKING
-$(PROJECT_INCLUDE)/netdb.h: netdb.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netdb.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/netdb.h
-
 $(PROJECT_INCLUDE)/resolv.h: resolv.h $(PROJECT_INCLUDE)/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/resolv.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/resolv.h
 
-$(PROJECT_INCLUDE)/syslog.h: syslog.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/syslog.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/syslog.h
-
 $(PROJECT_INCLUDE)/arpa/$(dirstamp):
 	@$(MKDIR_P) $(PROJECT_INCLUDE)/arpa
 	@: > $(PROJECT_INCLUDE)/arpa/$(dirstamp)
@@ -40,10 +32,6 @@ $(PROJECT_INCLUDE)/arpa/ftp.h: arpa/ftp.h $(PROJECT_INCLUDE)/arpa/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/arpa/ftp.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/arpa/ftp.h
 
-$(PROJECT_INCLUDE)/arpa/inet.h: arpa/inet.h $(PROJECT_INCLUDE)/arpa/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/arpa/inet.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/arpa/inet.h
-
 $(PROJECT_INCLUDE)/arpa/nameser.h: arpa/nameser.h $(PROJECT_INCLUDE)/arpa/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/arpa/nameser.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/arpa/nameser.h
@@ -86,10 +74,6 @@ $(PROJECT_INCLUDE)/net/ethernet.h: net/ethernet.h $(PROJECT_INCLUDE)/net/$(dirst
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/net/ethernet.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/net/ethernet.h
 
-$(PROJECT_INCLUDE)/net/if.h: net/if.h $(PROJECT_INCLUDE)/net/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/net/if.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/net/if.h
-
 $(PROJECT_INCLUDE)/net/if_arp.h: net/if_arp.h $(PROJECT_INCLUDE)/net/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/net/if_arp.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/net/if_arp.h
@@ -171,10 +155,6 @@ $(PROJECT_INCLUDE)/netinet/igmp_var.h: netinet/igmp_var.h $(PROJECT_INCLUDE)/net
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netinet/igmp_var.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/netinet/igmp_var.h
 
-$(PROJECT_INCLUDE)/netinet/in.h: netinet/in.h $(PROJECT_INCLUDE)/netinet/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netinet/in.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/netinet/in.h
-
 $(PROJECT_INCLUDE)/netinet/in_pcb.h: netinet/in_pcb.h $(PROJECT_INCLUDE)/netinet/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netinet/in_pcb.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/netinet/in_pcb.h
@@ -207,10 +187,6 @@ $(PROJECT_INCLUDE)/netinet/ip_var.h: netinet/ip_var.h $(PROJECT_INCLUDE)/netinet
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netinet/ip_var.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/netinet/ip_var.h
 
-$(PROJECT_INCLUDE)/netinet/tcp.h: netinet/tcp.h $(PROJECT_INCLUDE)/netinet/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netinet/tcp.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/netinet/tcp.h
-
 $(PROJECT_INCLUDE)/netinet/tcp_debug.h: netinet/tcp_debug.h $(PROJECT_INCLUDE)/netinet/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/netinet/tcp_debug.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/netinet/tcp_debug.h
@@ -375,10 +351,6 @@ $(PROJECT_INCLUDE)/sys/signalvar.h: sys/signalvar.h $(PROJECT_INCLUDE)/sys/$(dir
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/signalvar.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/signalvar.h
 
-$(PROJECT_INCLUDE)/sys/socket.h: sys/socket.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/socket.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/socket.h
-
 $(PROJECT_INCLUDE)/sys/socketvar.h: sys/socketvar.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/socketvar.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/socketvar.h
@@ -387,10 +359,6 @@ $(PROJECT_INCLUDE)/sys/sysctl.h: sys/sysctl.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/sysctl.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/sysctl.h
 
-$(PROJECT_INCLUDE)/sys/syslog.h: sys/syslog.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/syslog.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/syslog.h
-
 $(PROJECT_INCLUDE)/sys/systm.h: sys/systm.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/systm.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/systm.h
@@ -403,10 +371,6 @@ $(PROJECT_INCLUDE)/sys/ucred.h: sys/ucred.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/ucred.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/ucred.h
 
-$(PROJECT_INCLUDE)/sys/un.h: sys/un.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/un.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/un.h
-
 $(PROJECT_INCLUDE)/vm/$(dirstamp):
 	@$(MKDIR_P) $(PROJECT_INCLUDE)/vm
 	@: > $(PROJECT_INCLUDE)/vm/$(dirstamp)
diff --git a/cpukit/libnetworking/sys/socket.h b/cpukit/libnetworking/sys/socket.h
deleted file mode 100644
index 3821d8b..0000000
--- a/cpukit/libnetworking/sys/socket.h
+++ /dev/null
@@ -1,405 +0,0 @@
-/*
- * Copyright (c) 1982, 1985, 1986, 1988, 1993, 1994
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)socket.h	8.4 (Berkeley) 2/21/94
- * $FreeBSD: src/sys/sys/socket.h,v 1.88 2005/04/13 00:01:46 mdodd Exp $
- */
-
-
-#ifndef _SYS_SOCKET_H_
-#define	_SYS_SOCKET_H_
-
-#include <sys/cdefs.h>
-#include <rtems/bsdnet/_types.h>
-#include <sys/types.h>
-
-/*
- * Definitions related to sockets: types, address families, options.
- */
-
-/*
- * Data types.
- */
-
-#ifndef _SA_FAMILY_T_DECLARED
-typedef	__sa_family_t	sa_family_t;
-#define	_SA_FAMILY_T_DECLARED
-#endif
-
-#ifndef _SOCKLEN_T_DECLARED
-typedef	__socklen_t	socklen_t;
-#define	_SOCKLEN_T_DECLARED
-#endif
-
-/*
- * Types
- */
-#define	SOCK_STREAM	1		/* stream socket */
-#define	SOCK_DGRAM	2		/* datagram socket */
-#define	SOCK_RAW	3		/* raw-protocol interface */
-#if __BSD_VISIBLE
-#define	SOCK_RDM	4		/* reliably-delivered message */
-#endif
-#define	SOCK_SEQPACKET	5		/* sequenced packet stream */
-
-/*
- * Option flags per-socket.
- */
-#define	SO_DEBUG	0x0001		/* turn on debugging info recording */
-#define	SO_ACCEPTCONN	0x0002		/* socket has had listen() */
-#define	SO_REUSEADDR	0x0004		/* allow local address reuse */
-#define	SO_KEEPALIVE	0x0008		/* keep connections alive */
-#define	SO_DONTROUTE	0x0010		/* just use interface addresses */
-#define	SO_BROADCAST	0x0020		/* permit sending of broadcast msgs */
-#if __BSD_VISIBLE
-#define	SO_USELOOPBACK	0x0040		/* bypass hardware when possible */
-#endif
-#define	SO_LINGER	0x0080		/* linger on close if data present */
-#define	SO_OOBINLINE	0x0100		/* leave received OOB data in line */
-#if __BSD_VISIBLE
-#define	SO_REUSEPORT	0x0200		/* allow local address & port reuse */
-#define	SO_TIMESTAMP	0x0400		/* timestamp received dgram traffic */
-#define	SO_NOSIGPIPE	0x0800		/* no SIGPIPE from EPIPE */
-#define	SO_ACCEPTFILTER	0x1000		/* there is an accept filter */
-#define	SO_BINTIME	0x2000		/* timestamp received dgram traffic */
-#endif
-
-/*
- * Additional options, not kept in so_options.
- */
-#define SO_SNDBUF	0x1001		/* send buffer size */
-#define SO_RCVBUF	0x1002		/* receive buffer size */
-#define SO_SNDLOWAT	0x1003		/* send low-water mark */
-#define SO_RCVLOWAT	0x1004		/* receive low-water mark */
-#define SO_SNDTIMEO	0x1005		/* send timeout */
-#define SO_RCVTIMEO	0x1006		/* receive timeout */
-#define	SO_ERROR	0x1007		/* get error status and clear */
-#define	SO_TYPE		0x1008		/* get socket type */
-#define	SO_PRIVSTATE	0x1009		/* get/deny privileged state */
-
-/*
- * RTEMS addition: get and set wakeup functions.
- */
-#define SO_SNDWAKEUP	0x1020		/* wakeup when ready to send */
-#define SO_RCVWAKEUP	0x1021		/* wakeup when ready to receive */
-
-/*
- * Structure used for manipulating linger option.
- */
-struct	linger {
-	int	l_onoff;		/* option on/off */
-	int	l_linger;		/* linger time */
-};
-
-/*
- * RTEMS addition: structure used to get and set wakeup function.
- */
-struct socket;
-struct	sockwakeup {
-	void	(*sw_pfn)(struct socket *, void *);
-	void	*sw_arg;
-};
-
-/*
- * Level number for (get/set)sockopt() to apply to socket itself.
- */
-#define	SOL_SOCKET	0xffff		/* options for socket level */
-
-/*
- * Address families.
- */
-#define	AF_UNSPEC	0		/* unspecified */
-#if __BSD_VISIBLE
-#define	AF_LOCAL	AF_UNIX		/* local to host (pipes, portals) */
-#endif
-#define	AF_UNIX		1		/* standardized name for AF_LOCAL */
-#define	AF_INET		2		/* internetwork: UDP, TCP, etc. */
-#if __BSD_VISIBLE
-#define	AF_IMPLINK	3		/* arpanet imp addresses */
-#define	AF_PUP		4		/* pup protocols: e.g. BSP */
-#define	AF_CHAOS	5		/* mit CHAOS protocols */
-#define	AF_NETBIOS	6		/* SMB protocols */
-#define	AF_ISO		7		/* ISO protocols */
-#define	AF_OSI		AF_ISO
-#define	AF_ECMA		8		/* European computer manufacturers */
-#define	AF_DATAKIT	9		/* datakit protocols */
-#define	AF_CCITT	10		/* CCITT protocols, X.25 etc */
-#define	AF_SNA		11		/* IBM SNA */
-#define AF_DECnet	12		/* DECnet */
-#define AF_DLI		13		/* DEC Direct data link interface */
-#define AF_LAT		14		/* LAT */
-#define	AF_HYLINK	15		/* NSC Hyperchannel */
-#define	AF_APPLETALK	16		/* Apple Talk */
-#define	AF_ROUTE	17		/* Internal Routing Protocol */
-#define	AF_LINK		18		/* Link layer interface */
-#define	pseudo_AF_XTP	19		/* eXpress Transfer Protocol (no AF) */
-#define	AF_COIP		20		/* connection-oriented IP, aka ST II */
-#define	AF_CNT		21		/* Computer Network Technology */
-#define pseudo_AF_RTIP	22		/* Help Identify RTIP packets */
-#define	AF_IPX		23		/* Novell Internet Protocol */
-#define	AF_SIP		24		/* Simple Internet Protocol */
-#define	pseudo_AF_PIP	25		/* Help Identify PIP packets */
-#define	AF_ISDN		26		/* Integrated Services Digital Network*/
-#define	AF_E164		AF_ISDN		/* CCITT E.164 recommendation */
-#define	pseudo_AF_KEY	27		/* Internal key-management function */
-#endif
-#define	AF_INET6	28		/* IPv6 */
-
-#define	AF_MAX		29
-
-/*
- * Structure used by kernel to store most
- * addresses.
- */
-struct sockaddr {
-	unsigned char	sa_len;			/* total length */
-	sa_family_t	sa_family;		/* address family */
-	char	sa_data[14];		/* actually longer; address value */
-};
-
-/*
- * Structure used by kernel to pass protocol
- * information in raw sockets.
- */
-struct sockproto {
-	unsigned short	sp_family;		/* address family */
-	unsigned short	sp_protocol;		/* protocol */
-};
-
-/*
- * Protocol families, same as address families for now.
- */
-#define	PF_UNSPEC	AF_UNSPEC
-#define	PF_LOCAL	AF_LOCAL
-#define	PF_UNIX		PF_LOCAL	/* backward compatibility */
-#define	PF_INET		AF_INET
-#define	PF_IMPLINK	AF_IMPLINK
-#define	PF_PUP		AF_PUP
-#define	PF_CHAOS	AF_CHAOS
-#define	PF_NETBIOS	AF_NETBIOS
-#define	PF_ISO		AF_ISO
-#define	PF_OSI		AF_ISO
-#define	PF_ECMA		AF_ECMA
-#define	PF_DATAKIT	AF_DATAKIT
-#define	PF_CCITT	AF_CCITT
-#define	PF_SNA		AF_SNA
-#define PF_DECnet	AF_DECnet
-#define PF_DLI		AF_DLI
-#define PF_LAT		AF_LAT
-#define	PF_HYLINK	AF_HYLINK
-#define	PF_APPLETALK	AF_APPLETALK
-#define	PF_ROUTE	AF_ROUTE
-#define	PF_LINK		AF_LINK
-#define	PF_XTP		pseudo_AF_XTP	/* really just proto family, no AF */
-#define	PF_COIP		AF_COIP
-#define	PF_CNT		AF_CNT
-#define	PF_SIP		AF_SIP
-#define	PF_IPX		AF_IPX
-#define PF_RTIP		pseudo_AF_RTIP	/* same format as AF_INET */
-#define PF_PIP		pseudo_AF_PIP
-#define	PF_ISDN		AF_ISDN
-#define	PF_KEY		pseudo_AF_KEY
-#define	PF_INET6	AF_INET6
-
-#define	PF_MAX		AF_MAX
-
-/*
- * Definitions for network related sysctl, CTL_NET.
- *
- * Second level is protocol family.
- * Third level is protocol number.
- *
- * Further levels are defined by the individual families below.
- */
-#define NET_MAXID	AF_MAX
-
-#define CTL_NET_NAMES { \
-	{ 0, 0 }, \
-	{ "unix", CTLTYPE_NODE }, \
-	{ "inet", CTLTYPE_NODE }, \
-	{ "implink", CTLTYPE_NODE }, \
-	{ "pup", CTLTYPE_NODE }, \
-	{ "chaos", CTLTYPE_NODE }, \
-	{ "xerox_ns", CTLTYPE_NODE }, \
-	{ "iso", CTLTYPE_NODE }, \
-	{ "emca", CTLTYPE_NODE }, \
-	{ "datakit", CTLTYPE_NODE }, \
-	{ "ccitt", CTLTYPE_NODE }, \
-	{ "ibm_sna", CTLTYPE_NODE }, \
-	{ "decnet", CTLTYPE_NODE }, \
-	{ "dec_dli", CTLTYPE_NODE }, \
-	{ "lat", CTLTYPE_NODE }, \
-	{ "hylink", CTLTYPE_NODE }, \
-	{ "appletalk", CTLTYPE_NODE }, \
-	{ "route", CTLTYPE_NODE }, \
-	{ "link_layer", CTLTYPE_NODE }, \
-	{ "xtp", CTLTYPE_NODE }, \
-	{ "coip", CTLTYPE_NODE }, \
-	{ "cnt", CTLTYPE_NODE }, \
-	{ "rtip", CTLTYPE_NODE }, \
-	{ "ipx", CTLTYPE_NODE }, \
-	{ "sip", CTLTYPE_NODE }, \
-	{ "pip", CTLTYPE_NODE }, \
-	{ "isdn", CTLTYPE_NODE }, \
-	{ "key", CTLTYPE_NODE }, \
-}
-
-/*
- * PF_ROUTE - Routing table
- *
- * Three additional levels are defined:
- *	Fourth: address family, 0 is wildcard
- *	Fifth: type of info, defined below
- *	Sixth: flag(s) to mask with for NET_RT_FLAGS
- */
-#define NET_RT_DUMP	1		/* dump; may limit to a.f. */
-#define NET_RT_FLAGS	2		/* by flags, e.g. RESOLVING */
-#define NET_RT_IFLIST	3		/* survey interface list */
-#define	NET_RT_MAXID	4
-
-#define CTL_NET_RT_NAMES { \
-	{ 0, 0 }, \
-	{ "dump", CTLTYPE_STRUCT }, \
-	{ "flags", CTLTYPE_STRUCT }, \
-	{ "iflist", CTLTYPE_STRUCT }, \
-}
-
-/*
- * Maximum queue length specifiable by listen.
- */
-#define	SOMAXCONN	128
-
-/*
- * Message header for recvmsg and sendmsg calls.
- * Used value-result for recvmsg, value only for sendmsg.
- */
-struct msghdr {
-	void		*msg_name;		/* optional address */
-	socklen_t	msg_namelen;		/* size of address */
-	struct	iovec *msg_iov;		/* scatter/gather array */
-	int	msg_iovlen;		/* # elements in msg_iov */
-	void		*msg_control;		/* ancillary data, see below */
-	socklen_t	msg_controllen;		/* ancillary data buffer len */
-	int	msg_flags;		/* flags on received message */
-};
-
-#define	MSG_OOB		0x1		/* process out-of-band data */
-#define	MSG_PEEK	0x2		/* peek at incoming message */
-#define	MSG_DONTROUTE	0x4		/* send without using routing tables */
-#define	MSG_EOR		0x8		/* data completes record */
-#define	MSG_TRUNC	0x10		/* data discarded before delivery */
-#define	MSG_CTRUNC	0x20		/* control data lost before delivery */
-#define	MSG_WAITALL	0x40		/* wait for full request or error */
-#if __BSD_VISIBLE
-#define	MSG_DONTWAIT	0x80		/* this message should be nonblocking */
-#define	MSG_EOF		0x100		/* data completes connection */
-#define MSG_COMPAT      0x8000		/* used in sendit() */
-#endif
-
-/*
- * Header for ancillary data objects in msg_control buffer.
- * Used for additional information with/about a datagram
- * not expressible by flags.  The format is a sequence
- * of message elements headed by cmsghdr structures.
- */
-struct cmsghdr {
-	socklen_t	cmsg_len;		/* data byte count, including hdr */
-	int	cmsg_level;		/* originating protocol */
-	int	cmsg_type;		/* protocol-specific type */
-/* followed by	u_char  cmsg_data[]; */
-};
-
-/* given pointer to struct cmsghdr, return pointer to data */
-#define	CMSG_DATA(cmsg)		((u_char *)((cmsg) + 1))
-
-/* given pointer to struct cmsghdr, return pointer to next cmsghdr */
-#define	CMSG_NXTHDR(mhdr, cmsg)	\
-	(((caddr_t)(cmsg) + (cmsg)->cmsg_len + sizeof(struct cmsghdr) > \
-	    (mhdr)->msg_control + (mhdr)->msg_controllen) ? \
-	    (struct cmsghdr *)NULL : \
-	    (struct cmsghdr *)((caddr_t)(cmsg) + ALIGN((cmsg)->cmsg_len)))
-
-#define	CMSG_FIRSTHDR(mhdr)	((struct cmsghdr *)(mhdr)->msg_control)
-
-/* "Socket"-level control message types: */
-#define	SCM_RIGHTS	0x01		/* access rights (array of int) */
-#define	SCM_TIMESTAMP	0x02		/* timestamp (struct timeval) */
-
-/*
- * 4.3 compat sockaddr, move to compat file later
- */
-struct osockaddr {
-	unsigned short	sa_family;		/* address family */
-	char	sa_data[14];		/* up to 14 bytes of direct address */
-};
-
-/*
- * 4.3-compat message header (move to compat file later).
- */
-struct omsghdr {
-	char	*msg_name;		/* optional address */
-	int	msg_namelen;		/* size of address */
-	struct	iovec *msg_iov;		/* scatter/gather array */
-	int	msg_iovlen;		/* # elements in msg_iov */
-	char	*msg_accrights;		/* access rights sent/received */
-	int	msg_accrightslen;
-};
-
-/*
- * howto arguments for shutdown(2), specified by Posix.1g.
- */
-#define	SHUT_RD		0		/* shut down the reading side */
-#define	SHUT_WR		1		/* shut down the writing side */
-#define	SHUT_RDWR	2		/* shut down both sides */
-
-#ifndef	_KERNEL
-
-__BEGIN_DECLS
-int	accept(int, struct sockaddr * __restrict, socklen_t * __restrict);
-int	bind(int, const struct sockaddr *, socklen_t);
-int	connect(int, const struct sockaddr *, socklen_t);
-int	getpeername(int, struct sockaddr * __restrict, socklen_t * __restrict);
-int	getsockname(int, struct sockaddr * __restrict, socklen_t * __restrict);
-int	getsockopt(int, int, int, void * __restrict, socklen_t * __restrict);
-int	listen(int, int);
-ssize_t	recv(int, void *, size_t, int);
-ssize_t	recvfrom(int, void *, size_t, int, struct sockaddr * __restrict, socklen_t * __restrict);
-ssize_t	recvmsg(int, struct msghdr *, int);
-ssize_t	send(int, const void *, size_t, int);
-ssize_t	sendto(int, const void *,
-	    size_t, int, const struct sockaddr *, socklen_t);
-ssize_t	sendmsg(int, const struct msghdr *, int);
-int	setsockopt(int, int, int, const void *, socklen_t);
-int	shutdown(int, int);
-int	socket(int, int, int);
-int	socketpair(int, int, int, int *);
-__END_DECLS
-
-#endif /* !_KERNEL */
-
-#endif /* !_SYS_SOCKET_H_ */
diff --git a/cpukit/libnetworking/sys/syslog.h b/cpukit/libnetworking/sys/syslog.h
deleted file mode 100644
index d6eadd4..0000000
--- a/cpukit/libnetworking/sys/syslog.h
+++ /dev/null
@@ -1,191 +0,0 @@
-/*
- * Copyright (c) 1982, 1986, 1988, 1993
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)syslog.h	8.1 (Berkeley) 6/2/93
- * $FreeBSD: src/sys/sys/syslog.h,v 1.26 2005/01/07 02:29:24 imp Exp $
- */
-
-
-#ifndef _SYS_SYSLOG_H_
-#define _SYS_SYSLOG_H_
-
-#define	_PATH_LOG	"/var/run/log"
-#define	_PATH_OLDLOG	"/dev/log"	/* backward compatibility */
-
-/*
- * priorities/facilities are encoded into a single 32-bit quantity, where the
- * bottom 3 bits are the priority (0-7) and the top 28 bits are the facility
- * (0-big number).  Both the priorities and the facilities map roughly
- * one-to-one to strings in the syslogd(8) source code.  This mapping is
- * included in this file.
- *
- * priorities (these are ordered)
- */
-#define	LOG_EMERG	0	/* system is unusable */
-#define	LOG_ALERT	1	/* action must be taken immediately */
-#define	LOG_CRIT	2	/* critical conditions */
-#define	LOG_ERR		3	/* error conditions */
-#define	LOG_WARNING	4	/* warning conditions */
-#define	LOG_NOTICE	5	/* normal but significant condition */
-#define	LOG_INFO	6	/* informational */
-#define	LOG_DEBUG	7	/* debug-level messages */
-
-#define	LOG_PRIMASK	0x07	/* mask to extract priority part (internal) */
-				/* extract priority */
-#define	LOG_PRI(p)	((p) & LOG_PRIMASK)
-#define	LOG_MAKEPRI(fac, pri)	((fac) | (pri))
-
-#ifdef SYSLOG_NAMES
-#define	INTERNAL_NOPRI	0x10	/* the "no priority" priority */
-				/* mark "facility" */
-#define	INTERNAL_MARK	LOG_MAKEPRI((LOG_NFACILITIES<<3), 0)
-typedef struct _code {
-	const char	*c_name;
-	int		c_val;
-} CODE;
-
-CODE prioritynames[] = {
-	{ "alert",	LOG_ALERT,	},
-	{ "crit",	LOG_CRIT,	},
-	{ "debug",	LOG_DEBUG,	},
-	{ "emerg",	LOG_EMERG,	},
-	{ "err",	LOG_ERR,	},
-	{ "error",	LOG_ERR,	},	/* DEPRECATED */
-	{ "info",	LOG_INFO,	},
-	{ "none",	INTERNAL_NOPRI,	},	/* INTERNAL */
-	{ "notice",	LOG_NOTICE,	},
-	{ "panic", 	LOG_EMERG,	},	/* DEPRECATED */
-	{ "warn",	LOG_WARNING,	},	/* DEPRECATED */
-	{ "warning",	LOG_WARNING,	},
-	{ NULL,		-1,		}
-};
-#endif
-
-/* facility codes */
-#define	LOG_KERN	(0<<3)	/* kernel messages */
-#define	LOG_USER	(1<<3)	/* random user-level messages */
-#define	LOG_MAIL	(2<<3)	/* mail system */
-#define	LOG_DAEMON	(3<<3)	/* system daemons */
-#define	LOG_AUTH	(4<<3)	/* authorization messages */
-#define	LOG_SYSLOG	(5<<3)	/* messages generated internally by syslogd */
-#define	LOG_LPR		(6<<3)	/* line printer subsystem */
-#define	LOG_NEWS	(7<<3)	/* network news subsystem */
-#define	LOG_UUCP	(8<<3)	/* UUCP subsystem */
-#define	LOG_CRON	(9<<3)	/* clock daemon */
-#define	LOG_AUTHPRIV	(10<<3)	/* authorization messages (private) */
-				/* Facility #10 clashes in DEC UNIX, where */
-				/* it's defined as LOG_MEGASAFE for AdvFS  */
-				/* event logging.                          */
-#define	LOG_FTP		(11<<3)	/* ftp daemon */
-#define	LOG_NTP		(12<<3)	/* NTP subsystem */
-
-	/* other codes through 15 reserved for system use */
-#define	LOG_LOCAL0	(16<<3)	/* reserved for local use */
-#define	LOG_LOCAL1	(17<<3)	/* reserved for local use */
-#define	LOG_LOCAL2	(18<<3)	/* reserved for local use */
-#define	LOG_LOCAL3	(19<<3)	/* reserved for local use */
-#define	LOG_LOCAL4	(20<<3)	/* reserved for local use */
-#define	LOG_LOCAL5	(21<<3)	/* reserved for local use */
-#define	LOG_LOCAL6	(22<<3)	/* reserved for local use */
-#define	LOG_LOCAL7	(23<<3)	/* reserved for local use */
-
-#define	LOG_NFACILITIES	24	/* current number of facilities */
-#define	LOG_FACMASK	0x03f8	/* mask to extract facility part */
-				/* facility of pri */
-#define	LOG_FAC(p)	(((p) & LOG_FACMASK) >> 3)
-
-#ifdef SYSLOG_NAMES
-CODE facilitynames[] = {
-	{ "auth",	LOG_AUTH,	},
-	{ "authpriv",	LOG_AUTHPRIV,	},
-	{ "cron", 	LOG_CRON,	},
-	{ "daemon",	LOG_DAEMON,	},
-	{ "ftp",	LOG_FTP,	},
-	{ "kern",	LOG_KERN,	},
-	{ "lpr",	LOG_LPR,	},
-	{ "mail",	LOG_MAIL,	},
-	{ "mark", 	INTERNAL_MARK,	},	/* INTERNAL */
-	{ "news",	LOG_NEWS,	},
-	{ "ntp",	LOG_NTP,	},
-	{ "security",	LOG_AUTH,	},	/* DEPRECATED */
-	{ "syslog",	LOG_SYSLOG,	},
-	{ "user",	LOG_USER,	},
-	{ "uucp",	LOG_UUCP,	},
-	{ "local0",	LOG_LOCAL0,	},
-	{ "local1",	LOG_LOCAL1,	},
-	{ "local2",	LOG_LOCAL2,	},
-	{ "local3",	LOG_LOCAL3,	},
-	{ "local4",	LOG_LOCAL4,	},
-	{ "local5",	LOG_LOCAL5,	},
-	{ "local6",	LOG_LOCAL6,	},
-	{ "local7",	LOG_LOCAL7,	},
-	{ NULL,		-1,		}
-};
-#endif
-
-#ifdef _KERNEL
-#define	LOG_PRINTF	-1	/* pseudo-priority to indicate use of printf */
-#endif
-
-/*
- * arguments to setlogmask.
- */
-#define	LOG_MASK(pri)	(1 << (pri))		/* mask for one priority */
-#define	LOG_UPTO(pri)	((1 << ((pri)+1)) - 1)	/* all priorities through pri */
-
-/*
- * Option flags for openlog.
- *
- * LOG_ODELAY no longer does anything.
- * LOG_NDELAY is the inverse of what it used to be.
- */
-#define	LOG_PID		0x01	/* log the pid with each message */
-#define	LOG_CONS	0x02	/* log on the console if errors in sending */
-#define	LOG_ODELAY	0x04	/* delay open until first syslog() (default) */
-#define	LOG_NDELAY	0x08	/* don't delay open */
-#define	LOG_NOWAIT	0x10	/* don't wait for console forks: DEPRECATED */
-#define	LOG_PERROR	0x20	/* log to stderr as well */
-
-#ifdef _KERNEL
-
-#else /* not _KERNEL */
-
-#include <sys/cdefs.h>
-#include <stdarg.h>
-
-__BEGIN_DECLS
-void	closelog(void);
-void	openlog(const char *, int, int);
-int	setlogmask(int);
-void	syslog(int, const char *, ...);
-void	vsyslog(int, const char *, va_list);
-__END_DECLS
-
-#endif /* !_KERNEL */
-
-#endif
diff --git a/cpukit/libnetworking/sys/un.h b/cpukit/libnetworking/sys/un.h
deleted file mode 100644
index 2b8e3f5..0000000
--- a/cpukit/libnetworking/sys/un.h
+++ /dev/null
@@ -1,76 +0,0 @@
-/*
- * Copyright (c) 1982, 1986, 1993
- *	The Regents of the University of California.  All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 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.
- * 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.
- *
- * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
- * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
- * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
- * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
- * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
- * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
- * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- *
- *	@(#)un.h	8.3 (Berkeley) 2/19/95
- * $FreeBSD: src/sys/sys/un.h,v 1.29 2005/04/13 00:01:46 mdodd Exp $
- */
-
-
-#ifndef _SYS_UN_H_
-#define _SYS_UN_H_
-
-#include <sys/cdefs.h>
-#include <rtems/bsdnet/_types.h>
-
-#ifndef _SA_FAMILY_T_DECLARED
-typedef	__sa_family_t	sa_family_t;
-#define	_SA_FAMILY_T_DECLARED
-#endif
-
-/*
- * Definitions for UNIX IPC domain.
- */
-struct	sockaddr_un {
-	unsigned char	sun_len;		/* sockaddr len including null */
-	sa_family_t	sun_family;		/* AF_UNIX */
-	char	sun_path[104];		/* path name (gag) */
-};
-
-#if __BSD_VISIBLE
-
-/* Socket options. */
-#define	LOCAL_PEERCRED		0x001	/* retrieve peer credentials */
-#define	LOCAL_CREDS		0x002	/* pass credentials to receiver */
-#define	LOCAL_CONNWAIT		0x004	/* connects block until accepted */
-
-#ifdef _KERNEL
-struct mbuf;
-struct socket;
-struct sockopt;
-
-#else /* !_KERNEL */
-
-/* actual length of an initialized sockaddr_un */
-#define SUN_LEN(su) \
-	(sizeof(*(su)) - sizeof((su)->sun_path) + strlen((su)->sun_path))
-
-#endif /* _KERNEL */
-
-#endif /* __BSD_VISIBLE */
-
-#endif /* !_SYS_UN_H_ */
diff --git a/cpukit/libnetworking/syslog.h b/cpukit/libnetworking/syslog.h
deleted file mode 100644
index 830b492..0000000
--- a/cpukit/libnetworking/syslog.h
+++ /dev/null
@@ -1 +0,0 @@
-#include <sys/syslog.h>
diff --git a/cpukit/preinstall.am b/cpukit/preinstall.am
index c8f2cd3..23b31bb 100644
--- a/cpukit/preinstall.am
+++ b/cpukit/preinstall.am
@@ -107,14 +107,6 @@ $(PROJECT_INCLUDE)/sys/endian.h: include/sys/endian.h $(PROJECT_INCLUDE)/sys/$(d
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/endian.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/endian.h
 
-$(PROJECT_INCLUDE)/sys/uio.h: include/sys/uio.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/uio.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/uio.h
-
-$(PROJECT_INCLUDE)/sys/_iovec.h: include/sys/_iovec.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/_iovec.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/_iovec.h
-
 $(PROJECT_INCLUDE)/sys/priority.h: include/sys/priority.h $(PROJECT_INCLUDE)/sys/$(dirstamp)
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/sys/priority.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/sys/priority.h
-- 
1.8.4.5






More information about the devel mailing list