Print this page
7127 remove -Wno-missing-braces from Makefile.uts
Split |
Close |
Expand all |
Collapse all |
--- old/usr/src/uts/common/io/ppp/spppcomp/spppcomp_mod.c
+++ new/usr/src/uts/common/io/ppp/spppcomp/spppcomp_mod.c
1 1 /*
2 2 * spppcomp_mod.c - modload support for PPP compression STREAMS module.
3 3 *
4 4 * Copyright (c) 2011 Bayard G. Bell. All rights reserved.
5 5 *
6 6 * CONTRIBUTOR MAKES NO REPRESENTATION OR WARRANTIES ABOUT THE SUITABILITY
7 7 * OF THE SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
8 8 * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
9 9 * PARTICULAR PURPOSE, OR NON-INFRINGEMENT. CONTRIBUTOR SHALL NOT BE LIABLE
10 10 * FOR ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR
11 11 * DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES
12 12 *
13 13 * Copyright (c) 2000 by Sun Microsystems, Inc.
14 14 * All rights reserved.
15 15 *
16 16 * Permission to use, copy, modify, and distribute this software and its
17 17 * documentation is hereby granted, provided that the above copyright
18 18 * notice appears in all copies.
19 19 *
20 20 * SUN MAKES NO REPRESENTATION OR WARRANTIES ABOUT THE SUITABILITY OF
21 21 * THE SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
22 22 * TO THE IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
23 23 * PARTICULAR PURPOSE, OR NON-INFRINGEMENT. SUN SHALL NOT BE LIABLE FOR
24 24 * ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR
25 25 * DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES
26 26 *
27 27 * Copyright (c) 1994 The Australian National University.
28 28 * All rights reserved.
29 29 *
30 30 * Permission to use, copy, modify, and distribute this software and its
31 31 * documentation is hereby granted, provided that the above copyright
32 32 * notice appears in all copies. This software is provided without any
33 33 * warranty, express or implied. The Australian National University
34 34 * makes no representations about the suitability of this software for
35 35 * any purpose.
36 36 *
37 37 * IN NO EVENT SHALL THE AUSTRALIAN NATIONAL UNIVERSITY BE LIABLE TO ANY
38 38 * PARTY FOR DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES
39 39 * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF
40 40 * THE AUSTRALIAN NATIONAL UNIVERSITY HAVE BEEN ADVISED OF THE POSSIBILITY
41 41 * OF SUCH DAMAGE.
42 42 *
43 43 * THE AUSTRALIAN NATIONAL UNIVERSITY SPECIFICALLY DISCLAIMS ANY WARRANTIES,
44 44 * INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
45 45 * AND FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS
46 46 * ON AN "AS IS" BASIS, AND THE AUSTRALIAN NATIONAL UNIVERSITY HAS NO
47 47 * OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS,
48 48 * OR MODIFICATIONS.
49 49 *
50 50 * This module is derived from the original SVR4 STREAMS PPP compression
51 51 * module originally written by Paul Mackerras <paul.mackerras@cs.anu.edu.au>.
52 52 *
53 53 * James Carlson <james.d.carlson@sun.com> and Adi Masputra
54 54 * <adi.masputra@sun.com> rewrote and restructured the code for improved
55 55 * performance and scalability.
56 56 */
57 57
58 58 #include <sys/types.h>
59 59 #include <sys/syslog.h>
60 60 #include <sys/conf.h>
61 61 #include <sys/errno.h>
62 62 #include <sys/ddi.h>
63 63 #include <sys/conf.h>
64 64 #include <sys/modctl.h>
65 65 #include <net/pppio.h>
66 66
67 67 #include "s_common.h"
68 68
69 69 /*
70 70 * Globals for PPP compression loadable module wrapper
71 71 */
72 72 extern struct streamtab spppcomp_tab;
73 73 extern const char spppcomp_module_description[];
74 74
75 75 static struct fmodsw fsw = {
76 76 COMP_MOD_NAME, /* f_name */
77 77 &spppcomp_tab, /* f_str */
78 78 D_NEW | D_MP | D_MTPERQ /* f_flag */
↓ open down ↓ |
78 lines elided |
↑ open up ↑ |
79 79 };
80 80
81 81 static struct modlstrmod modlstrmod = {
82 82 &mod_strmodops, /* strmod_modops */
83 83 (char *)spppcomp_module_description, /* strmod_linkinfo */
84 84 &fsw /* strmod_fmodsw */
85 85 };
86 86
87 87 static struct modlinkage modlinkage = {
88 88 MODREV_1, /* ml_rev, has to be MODREV_1 */
89 - (void *) &modlstrmod, /* ml_linkage, NULL-terminated list */
90 - NULL /* of linkage structures */
89 + { (void *) &modlstrmod, NULL } /* ml_linkage, NULL-terminated list */
91 90 };
92 91
93 92 int
94 93 _init(void)
95 94 {
96 95 return (mod_install(&modlinkage));
97 96 }
98 97
99 98 int
100 99 _fini(void)
101 100 {
102 101 return (mod_remove(&modlinkage));
103 102 }
104 103
105 104 int
106 105 _info(struct modinfo *modinfop)
107 106 {
108 107 return (mod_info(&modlinkage, modinfop));
109 108 }
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX