Tue Mar 6 23:31:29 2018 UTC ()
Better to add these required headers closer to where they're needed


(pgoyette)
diff -r1.1.2.1 -r1.1.2.2 src/sys/compat/common/if_40.h
diff -r1.258.2.3 -r1.258.2.4 src/sys/net/if.h

cvs diff -r1.1.2.1 -r1.1.2.2 src/sys/compat/common/Attic/if_40.h (expand / switch to unified diff)

--- src/sys/compat/common/Attic/if_40.h 2018/03/06 23:17:42 1.1.2.1
+++ src/sys/compat/common/Attic/if_40.h 2018/03/06 23:31:29 1.1.2.2
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: if_40.h,v 1.1.2.1 2018/03/06 23:17:42 pgoyette Exp $ */ 1/* $NetBSD: if_40.h,v 1.1.2.2 2018/03/06 23:31:29 pgoyette Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 2016 The NetBSD Foundation, Inc. 4 * Copyright (c) 2016 The NetBSD Foundation, Inc.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to The NetBSD Foundation 7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Paul Goyette 8 * by Paul Goyette
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -23,22 +23,26 @@ @@ -23,22 +23,26 @@
23 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 23 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 24 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 25 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 26 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 27 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 28 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29 * POSSIBILITY OF SUCH DAMAGE. 29 * POSSIBILITY OF SUCH DAMAGE.
30 */ 30 */
31 31
32#ifndef _COMPAT_IF_40_H_ 32#ifndef _COMPAT_IF_40_H_
33#define _COMPAT_IF_40_H_ 33#define _COMPAT_IF_40_H_
34 34
35#if defined(COMPAT_40) 35#if defined(COMPAT_40)
 36
 37#include <net/if.h>
 38#include <compat/sys/sockio.h>
 39
36extern u_long (*vec_compat_cvtcmd)(u_long);  40extern u_long (*vec_compat_cvtcmd)(u_long);
37extern int (*vec_compat_ifioctl)(struct socket *, u_long, u_long,  41extern int (*vec_compat_ifioctl)(struct socket *, u_long, u_long,
38 void *, struct lwp *); 42 void *, struct lwp *);
39 43
40void if_40_init(void); 44void if_40_init(void);
41void if_40_fini(void); 45void if_40_fini(void);
42#endif 46#endif
43 47
44#endif /* !_COMPAT_IF_40_H_ */ 48#endif /* !_COMPAT_IF_40_H_ */

cvs diff -r1.258.2.3 -r1.258.2.4 src/sys/net/if.h (expand / switch to unified diff)

--- src/sys/net/if.h 2018/03/06 23:27:52 1.258.2.3
+++ src/sys/net/if.h 2018/03/06 23:31:29 1.258.2.4
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: if.h,v 1.258.2.3 2018/03/06 23:27:52 pgoyette Exp $ */ 1/* $NetBSD: if.h,v 1.258.2.4 2018/03/06 23:31:29 pgoyette Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc. 4 * Copyright (c) 1999, 2000, 2001 The NetBSD Foundation, Inc.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to The NetBSD Foundation 7 * This code is derived from software contributed to The NetBSD Foundation
8 * by William Studenmund and Jason R. Thorpe. 8 * by William Studenmund and Jason R. Thorpe.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -78,31 +78,28 @@ @@ -78,31 +78,28 @@
78#if defined(_NETBSD_SOURCE) 78#if defined(_NETBSD_SOURCE)
79 79
80#include <sys/socket.h> 80#include <sys/socket.h>
81#include <sys/queue.h> 81#include <sys/queue.h>
82#include <sys/mutex.h> 82#include <sys/mutex.h>
83 83
84#include <net/dlt.h> 84#include <net/dlt.h>
85#include <net/pfil.h> 85#include <net/pfil.h>
86#ifdef _KERNEL 86#ifdef _KERNEL
87#include <net/pktqueue.h> 87#include <net/pktqueue.h>
88#include <sys/pslist.h> 88#include <sys/pslist.h>
89#include <sys/pserialize.h> 89#include <sys/pserialize.h>
90#include <sys/psref.h> 90#include <sys/psref.h>
91#include <net/if.h> 
92#endif 91#endif
93 92
94#include <compat/sys/sockio.h> 
95 
96/* 93/*
97 * Always include ALTQ glue here -- we use the ALTQ interface queue 94 * Always include ALTQ glue here -- we use the ALTQ interface queue
98 * structure even when ALTQ is not configured into the kernel so that 95 * structure even when ALTQ is not configured into the kernel so that
99 * the size of struct ifnet does not changed based on the option. The 96 * the size of struct ifnet does not changed based on the option. The
100 * ALTQ queue structure is API-compatible with the legacy ifqueue. 97 * ALTQ queue structure is API-compatible with the legacy ifqueue.
101 */ 98 */
102#include <altq/if_altq.h> 99#include <altq/if_altq.h>
103 100
104/* 101/*
105 * Structures defining a network interface, providing a packet 102 * Structures defining a network interface, providing a packet
106 * transport mechanism (ala level 0 of the PUP protocols). 103 * transport mechanism (ala level 0 of the PUP protocols).
107 * 104 *
108 * Each interface accepts output datagrams of a specified maximum 105 * Each interface accepts output datagrams of a specified maximum