Deleted Added
full compact
if.c (9348) if.c (10358)
1/*
2 * Copyright (c) 1980, 1986, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)if.c 8.3 (Berkeley) 1/4/94
1/*
2 * Copyright (c) 1980, 1986, 1993
3 * The Regents of the University of California. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 17 unchanged lines hidden (view full) ---

26 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
27 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
28 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
29 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
30 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
31 * SUCH DAMAGE.
32 *
33 * @(#)if.c 8.3 (Berkeley) 1/4/94
34 * $Id: if.c,v 1.16 1995/06/15 00:19:56 davidg Exp $
34 * $Id: if.c,v 1.17 1995/06/28 05:31:03 davidg Exp $
35 */
36
37#include <sys/param.h>
38#include <sys/mbuf.h>
39#include <sys/systm.h>
40#include <sys/proc.h>
41#include <sys/socket.h>
42#include <sys/socketvar.h>
43#include <sys/protosw.h>
44#include <sys/kernel.h>
45#include <sys/ioctl.h>
46#include <sys/errno.h>
47
48#include <net/if.h>
49#include <net/if_dl.h>
50#include <net/if_types.h>
51#include <net/radix.h>
52#include <ether.h>
53
35 */
36
37#include <sys/param.h>
38#include <sys/mbuf.h>
39#include <sys/systm.h>
40#include <sys/proc.h>
41#include <sys/socket.h>
42#include <sys/socketvar.h>
43#include <sys/protosw.h>
44#include <sys/kernel.h>
45#include <sys/ioctl.h>
46#include <sys/errno.h>
47
48#include <net/if.h>
49#include <net/if_dl.h>
50#include <net/if_types.h>
51#include <net/radix.h>
52#include <ether.h>
53
54/*
55 * System initialization
56 */
57
58static void ifinit __P((caddr_t));
59SYSINIT(interfaces, SI_SUB_PROTO_IF, SI_ORDER_FIRST, ifinit, NULL)
60
61
54int ifqmaxlen = IFQ_MAXLEN;
55struct ifnet *ifnet;
56
57/*
58 * Network interface utility routines.
59 *
60 * Routines with ifa_ifwith* names take sockaddr *'s as
61 * parameters.
62int ifqmaxlen = IFQ_MAXLEN;
63struct ifnet *ifnet;
64
65/*
66 * Network interface utility routines.
67 *
68 * Routines with ifa_ifwith* names take sockaddr *'s as
69 * parameters.
70 *
71 * This routine assumes that it will be called at splimp() or higher.
62 */
72 */
73/* ARGSUSED*/
63void
74void
64ifinit()
75ifinit( udata)
76caddr_t udata; /* not used*/
65{
66 register struct ifnet *ifp;
67
68 for (ifp = ifnet; ifp; ifp = ifp->if_next)
69 if (ifp->if_snd.ifq_maxlen == 0)
70 ifp->if_snd.ifq_maxlen = ifqmaxlen;
71 if_slowtimo(0);
72}

--- 659 unchanged lines hidden ---
77{
78 register struct ifnet *ifp;
79
80 for (ifp = ifnet; ifp; ifp = ifp->if_next)
81 if (ifp->if_snd.ifq_maxlen == 0)
82 ifp->if_snd.ifq_maxlen = ifqmaxlen;
83 if_slowtimo(0);
84}

--- 659 unchanged lines hidden ---