Completed function declarations and/or added prototypes.

This commit is contained in:
Bruce Evans 1995-12-02 19:38:06 +00:00
parent af32e59f16
commit ce7609a49c
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=12579
10 changed files with 87 additions and 15 deletions

View File

@ -37,7 +37,7 @@
*
* @(#)bpf.c 8.2 (Berkeley) 3/28/94
*
* $Id: bpf.c,v 1.15 1995/11/29 10:48:44 julian Exp $
* $Id: bpf.c,v 1.16 1995/11/29 14:40:45 julian Exp $
*/
#include "bpfilter.h"
@ -52,6 +52,7 @@
#include <sys/param.h>
#include <sys/systm.h>
#include <sys/conf.h>
#include <machine/cpu.h> /* for bootverbose */
#include <sys/mbuf.h>
#include <sys/buf.h>
@ -130,6 +131,8 @@ bpfilterattach(n)
#endif
static int bpf_allocbufs __P((struct bpf_d *));
static void bpf_attachd __P((struct bpf_d *d, struct bpf_if *bp));
static void bpf_detachd __P((struct bpf_d *d));
static void bpf_freed __P((struct bpf_d *));
static void bpf_ifname __P((struct ifnet *, struct ifreq *));
static void bpf_mcopy __P((const void *, void *, u_int));

View File

@ -37,7 +37,7 @@
*
* @(#)bpf_filter.c 8.1 (Berkeley) 6/10/93
*
* $Id: bpf_filter.c,v 1.4 1995/04/01 01:46:27 davidg Exp $
* $Id: bpf_filter.c,v 1.5 1995/05/30 08:07:56 rgrimes Exp $
*/
#include <sys/param.h>
@ -82,6 +82,9 @@
} \
}
static int m_xhalf __P((struct mbuf *m, int k, int *err));
static int m_xword __P((struct mbuf *m, int k, int *err));
static int
m_xword(m, k, err)
register struct mbuf *m;

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)radix.c 8.4 (Berkeley) 11/2/94
* $Id: radix.c,v 1.8 1995/04/28 23:01:34 pst Exp $
* $Id: radix.c,v 1.9 1995/05/30 08:08:20 rgrimes Exp $
*/
/*
@ -51,6 +51,12 @@
#include <net/radix.h>
#endif
extern struct radix_node *
rn_lookup __P((void *v_arg, void *m_arg,
struct radix_node_head *head));
extern int rn_walktree_from __P((struct radix_node_head *h, void *a,
void *m, walktree_f_t *f, void *w));
int max_keylen;
struct radix_mask *rn_mkfreelist;
struct radix_node_head *mask_rnhead;
@ -61,6 +67,14 @@ static char *rn_zeros, *rn_ones;
#define rn_masktop (mask_rnhead->rnh_treetop)
#undef Bcmp
#define Bcmp(a, b, l) (l == 0 ? 0 : bcmp((caddr_t)(a), (caddr_t)(b), (u_long)l))
static int rn_lexobetter __P((void *m_arg, void *n_arg));
static struct radix_mask *
rn_new_radix_mask __P((struct radix_node *tt,
struct radix_mask *next));
static int rn_satsifies_leaf __P((char *trial, struct radix_node *leaf,
int skip));
/*
* The data structure for the keys is a radix tree with one way
* branching removed. The index rn_b at an internal node n represents a bit
@ -819,7 +833,7 @@ int
rn_walktree_from(h, a, m, f, w)
struct radix_node_head *h;
void *a, *m;
register int (*f)();
walktree_f_t *f;
void *w;
{
int error;
@ -908,7 +922,7 @@ rn_walktree_from(h, a, m, f, w)
int
rn_walktree(h, f, w)
struct radix_node_head *h;
register int (*f)();
walktree_f_t *f;
void *w;
{
int error;

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)if_ether.c 8.1 (Berkeley) 6/10/93
* $Id: if_ether.c,v 1.19 1995/10/05 20:08:39 wollman Exp $
* $Id: if_ether.c,v 1.20 1995/10/22 19:07:58 phk Exp $
*/
/*
@ -63,6 +63,8 @@
#include <netinet/ip.h>
#include <netinet/if_ether.h>
extern int arpioctl __P((int cmd, caddr_t data));
#define SIN(s) ((struct sockaddr_in *)s)
#define SDL(s) ((struct sockaddr_dl *)s)
#define SRP(s) ((struct sockaddr_inarp *)s)
@ -91,6 +93,7 @@ static LIST_HEAD(, llinfo_arp) llinfo_arp;
static void arprequest __P((struct arpcom *, u_long *, u_long *, u_char *));
static void arptfree __P((struct llinfo_arp *));
static void arp_rtrequest __P((int, struct rtentry *, struct sockaddr *));
static void arptimer __P((void *));
static struct llinfo_arp *arplookup __P((u_long, int, int));
static void in_arpinput __P((struct mbuf *));

View File

@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)igmp.c 8.1 (Berkeley) 7/19/93
* $Id: igmp.c,v 1.12 1995/06/13 17:51:05 wollman Exp $
* $Id: igmp.c,v 1.13 1995/11/14 20:33:52 phk Exp $
*/
/*
@ -67,6 +67,10 @@
#include <netinet/igmp.h>
#include <netinet/igmp_var.h>
extern int fill_rti __P((struct in_multi *inm));
extern struct router_info *
find_rti __P((struct ifnet *ifp));
struct igmpstat igmpstat;
SYSCTL_STRUCT(_net_inet_igmp, IGMPCTL_STATS, stats, CTLFLAG_RD,

View File

@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)in_proto.c 8.2 (Berkeley) 2/9/95
* $Id: in_proto.c,v 1.21 1995/11/14 20:34:05 phk Exp $
* $Id: in_proto.c,v 1.22 1995/11/20 12:28:16 phk Exp $
*/
#include <sys/param.h>
@ -71,11 +71,13 @@
*/
#ifdef IPXIP
void ipxip_input(), ipxip_ctlinput();
#include <netipx/ipx.h>
#include <netipx/ipx_ip.h>
#endif
#ifdef NSIP
void idpip_input(), nsip_ctlinput();
#include <netns/ns.h>
#include <netns/ns_if.h>
#endif
#ifdef TPIP

View File

@ -26,7 +26,7 @@
* OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: in_rmx.c,v 1.18 1995/11/09 20:22:59 phk Exp $
* $Id: in_rmx.c,v 1.19 1995/11/14 20:34:06 phk Exp $
*/
/*
@ -69,6 +69,9 @@
#include <netinet/tcpip.h>
#endif /* not MTUDISC */
extern int in_inithead __P((void **head, int off));
extern void in_rtqdrain __P((void));
#define RTPRF_OURS RTF_PROTO3 /* set on routes we manage */
/*

View File

@ -11,7 +11,7 @@
*
* This software is provided ``AS IS'' without any warranties of any kind.
*
* $Id: ip_fw.c,v 1.25 1995/10/29 15:32:31 phk Exp $
* $Id: ip_fw.c,v 1.26 1995/11/14 20:34:10 phk Exp $
*/
/*
@ -71,6 +71,17 @@
#define dprint_ip(a)
#endif
static int add_entry __P((struct ip_fw **chainptr, struct ip_fw *frwl));
static int del_entry __P((struct ip_fw **chainptr, struct ip_fw *frwl));
static struct ip_fw *
check_ipfw_struct __P(( struct mbuf *m));
static int clr_entry __P((struct ip_fw **chainptr, struct ip_fw *frwl));
static void free_fw_chain __P((struct ip_fw **chainptr));
static int ipopts_match __P((struct ip *ip, struct ip_fw *f));
static int port_match __P((u_short *portptr, int nports, u_short port,
int range_flag));
static int tcpflg_match __P((struct tcphdr *tcp, struct ip_fw *f));
static void zero_fw_chain __P((struct ip_fw *chainptr));
/*
* Returns TRUE if the port is matched by the vector, FALSE otherwise

View File

@ -9,7 +9,7 @@
* Modified by Bill Fenner, PARC, April 1995
*
* MROUTING Revision: 3.5
* $Id: ip_mroute.c,v 1.24 1995/10/29 15:32:35 phk Exp $
* $Id: ip_mroute.c,v 1.25 1995/11/14 20:34:16 phk Exp $
*/
@ -38,6 +38,8 @@
#include <netinet/ip_mroute.h>
#include <netinet/udp.h>
extern void rsvp_input __P((struct mbuf *m, int iphlen));
#ifndef NTOHL
#if BYTE_ORDER != BIG_ENDIAN
#define NTOHL(d) ((d) = ntohl((d)))
@ -53,6 +55,17 @@
#endif
#ifndef MROUTING
extern void ipip_input __P((struct mbuf *m));
extern u_long _ip_mcast_src __P((int vifi));
extern int _ip_mforward __P((struct ip *ip, struct ifnet *ifp,
struct mbuf *m, struct ip_moptions *imo));
extern int _ip_mrouter_done __P((void));
extern int _ip_mrouter_get __P((int cmd, struct socket *so,
struct mbuf **m));
extern int _ip_mrouter_set __P((int cmd, struct socket *so,
struct mbuf *m));
extern int _mrt_ioctl __P((int req, caddr_t data, struct proc *p));
/*
* Dummy routines and globals used when multicast routing is not compiled in.
*/
@ -191,11 +204,14 @@ ip_rsvp_force_done(so)
* except for netstat or debugging purposes.
*/
#ifndef MROUTE_LKM
extern void ipip_input __P((struct mbuf *m, int iphlen));
struct socket *ip_mrouter = NULL;
struct mrtstat mrtstat;
int ip_mrtproto = IGMP_DVMRP; /* for netstat only */
#else /* MROUTE_LKM */
#error /* the function definition will have a syntax error */
extern void X_ipip_input __P((struct mbuf *m));
extern struct mrtstat mrtstat;
static int ip_mrtproto;
#endif
@ -266,6 +282,14 @@ static int have_encap_tunnel = 0;
static u_long last_encap_src;
static struct vif *last_encap_vif;
static u_long X_ip_mcast_src __P((int vifi));
static int X_ip_mforward __P((struct ip *ip, struct ifnet *ifp, struct mbuf *m, struct ip_moptions *imo));
static int X_ip_mrouter_done __P((void));
static int X_ip_mrouter_get __P((int cmd, struct socket *so, struct mbuf **m));
static int X_ip_mrouter_set __P((int cmd, struct socket *so, struct mbuf *m));
static int X_legal_vif_num __P((int vif));
static int X_mrt_ioctl __P((int cmd, caddr_t data));
static int get_sg_cnt(struct sioc_sg_req *);
static int get_vif_cnt(struct sioc_vif_req *);
static int ip_mrouter_init(struct socket *, struct mbuf *);
@ -273,6 +297,7 @@ static int add_vif(struct vifctl *);
static int del_vif(vifi_t *);
static int add_mfc(struct mfcctl *);
static int del_mfc(struct mfcctl *);
static int socket_send(struct socket *, struct mbuf *, struct sockaddr_in *);
static int get_version(struct mbuf *);
static int get_assert(struct mbuf *);
static int set_assert(int *);
@ -441,7 +466,7 @@ X_mrt_ioctl(cmd, data)
}
#ifndef MROUTE_LKM
int (*mrt_ioctl)(int, caddr_t, struct proc *) = X_mrt_ioctl;
int (*mrt_ioctl)(int, caddr_t) = X_mrt_ioctl;
#endif
/*

View File

@ -35,7 +35,7 @@
* SUCH DAMAGE.
*
* @(#)ip_mroute.h 8.1 (Berkeley) 6/10/93
* $Id: ip_mroute.h,v 1.8 1995/06/13 17:51:13 wollman Exp $
* $Id: ip_mroute.h,v 1.9 1995/08/23 18:20:17 wollman Exp $
*/
#ifndef _NETINET_IP_MROUTE_H_
@ -251,7 +251,11 @@ struct tbf
extern int (*ip_mrouter_set) __P((int, struct socket *, struct mbuf *));
extern int (*ip_mrouter_get) __P((int, struct socket *, struct mbuf **));
extern int (*ip_mrouter_done) __P((void));
#ifdef MROUTING
extern int (*mrt_ioctl) __P((int, caddr_t));
#else
extern int (*mrt_ioctl) __P((int, caddr_t, struct proc *));
#endif
#endif /* KERNEL */